Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/382.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/88.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
jQuery与这些JavaScriptDOM对象/方法的等价物是什么?_Javascript_Jquery_Dom - Fatal编程技术网

jQuery与这些JavaScriptDOM对象/方法的等价物是什么?

jQuery与这些JavaScriptDOM对象/方法的等价物是什么?,javascript,jquery,dom,Javascript,Jquery,Dom,我试图找出jQuery与以下代码的等价性: var temp = $('#logoutFrame2').contents().find('html').html(); try { var temp1 = document .getElementById('logoutFrame2') .contentWindow .document

我试图找出jQuery与以下代码的等价性:

 var temp = $('#logoutFrame2').contents().find('html').html();

 try {
     var temp1 = document
                   .getElementById('logoutFrame2')
                   .contentWindow
                   .document
                   .getElementById('theCBOBox').innerHTML;
 }
 catch(err){}

 var newdiv = document.createElement("div");
 newdiv.innerHTML = temp;
 var container = document.getElementById("theContacts");
 container.appendChild(newdiv);
任何帮助都会很好o)

大卫

转化为

 var temp = $('#logoutFrame2').contents().find('html').html();

    try
    {
        var temp1 = $('#logoutFrame2')[0].contentWindow.document.getElementById('theCBOBox').innerHTML;
    }
    catch(err){}

    $('#theContacts').append('<div>'+temp+'</div>');
var temp=$('#logoutFrame2').contents().find('html').html();
尝试
{
var temp1=$('logoutFrame2')[0].contentWindow.document.getElementById('theCBOBox').innerHTML;
}
捕获(错误){}
$(“#联系人”)。附加(“”+temp+“”);
享受吧

转化为

 var temp = $('#logoutFrame2').contents().find('html').html();

    try
    {
        var temp1 = $('#logoutFrame2')[0].contentWindow.document.getElementById('theCBOBox').innerHTML;
    }
    catch(err){}

    $('#theContacts').append('<div>'+temp+'</div>');
var temp=$('#logoutFrame2').contents().find('html').html();
尝试
{
var temp1=$('logoutFrame2')[0].contentWindow.document.getElementById('theCBOBox').innerHTML;
}
捕获(错误){}
$(“#联系人”)。附加(“”+temp+“”);

享受吧

您希望将这段代码的哪一部分更改为jquery?所有代码都需要临时变量,因为我已经做了那一部分。您希望将这段代码的哪一部分更改为jquery?所有代码都需要临时变量,因为我已经做了那一部分。