【发布时间】:2012-09-01 18:29:42
【问题描述】:
这里的第一个问题:)
我正在处理一些拖放 div,我想在拖放到特定 div 时显示隐藏的内容。
这是我的拖放功能:
function drop(ev) {
ev.preventDefault();
var data=ev.dataTransfer.getData("Text");
ev.target.appendChild(document.getElementById(data));
if($(ev.target).hasClass("items")){
$(ev.target).children('div').children('.post').hide();
}
else if($(ev.target).hasClass("dropzone")) {
$(ev.target).children('div').children('.post').show();
}
}
【问题讨论】:
-
$(ev.target).children('div').children('.post').hide();有效,但演出无效
-
您的问题是什么?什么不工作?
-
一切正常,直到 "$(ev.target).children('div').children('.post').show();"
-
你想放弃什么?很抱歉你的问题不太清楚。
标签: javascript jquery drop-down-menu show-hide