Dom Object
var Pname=document.getelementbyid ("id");
Pname.innerhtml= ""; Enter content into the page
jquery Object
Objects produced after wrapping Dom objects with jquery
For example:
$ ("#foo"). HTML () is equivalent to document.getElementById ("foo"). InnerHTML
However, the methods of the two objects are different from each other.
Dom object converted to jquery object
var My=document.getelementbyid ("foo");
var $my =$ (my);
jquery objects converted to DOM objects
(1), jquery object is an array-like object, you can get the corresponding Dom object by means of [index]
var $my =$ ("#my"); jquery Object
var my= $my [0]; Dom Object
Alert (my.checked)//Check if the checkbox is selected
(2), get the corresponding DOM object by the Get (index) method
var $my =$ ("my"); jquery Object
var my = $my. Get (0); Dom Object
alert (my.checked); Check if this checkbox is selected
The difference between a sharp jquery--dom object and a jquery object