jquery 查看div中href引入页面中的元素
<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>问卷设置</title> <script type="text/javascript"> $(function() { $("#dd").dialog({ modal:true, title:'访问许可', resizable:false, width:600, height:400, closed:true, href:'NewFile.jsp' }); }); function add() { $("#dd").dialog('open'); console.info($('input')); } </script> </head> <body> <input type="button" value = "确定" onclick = "add();"/> <div id = "dd"> </div> </body> </html>
<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>NewFile</title> </head> <body> asadfadasfsad <input id = "tt" value = "123"/> </body> </html>
在onload时候调用$('#dd').dialog('refresh', 'new_content.php'); 中的“refresh”帮你预加载。