1
我有一个由母版页引用的网页内容表单。我需要将div的内容加载到另一个div中。由于jquery抛出错误,我无法调用内容。任何帮助将得到真正的赞赏。如何使用jquery在另一个div中加载div内容?
在此先感谢 šš侯赛因
我有一个由母版页引用的网页内容表单。我需要将div的内容加载到另一个div中。由于jquery抛出错误,我无法调用内容。任何帮助将得到真正的赞赏。如何使用jquery在另一个div中加载div内容?
在此先感谢 šš侯赛因
尝试这些
//Copies the inner HTML of source
$("#id_of_target_div").html($("#id_of_source_div").html());
//moves the source div into target
$("#id_of_target_div").append($("#id_of_source_div"));
//Moves children of source into target
$("#id_of_target_div").append($("#id_of_source_div").children());
一个尝试使用以下。
// you can copy the html and put it in the target div.
$('#target_div').html($('#source_div').html());
// You can clone the div and put it in target.
$('#source_div').clone().appendTo($('#target_div'));
看不到你的代码,不知道你的错误是什么,没办法帮助。 – 2011-04-27 11:59:12