crop_rotate
Run
<!DOCTYPE html> <html> <body> <p>Click the button to check if the ul element with id="myList" is the same as the document's first ul element.</p> <button onclick="myFunction()">Try it</button> <ul id="myList"><li>Coffee</li><li>Tea</li></ul> <p><strong>Note:</strong> Firefox stopped supported this method as of version 10, Instead, use === to compare if two nodes are the same.</p> <p><strong>Note:</strong> Internet Explorer 8 and earlier does not support the isSameNode() method.</p> <p id="demo"></p> <script> function myFunction() { var item1 = document.getElementById("myList"); var item2 = document.getElementsByTagName("UL")[0]; var x = item1.isSameNode(item2); document.getElementById("demo").innerHTML = x; } </script> </body> </html>
PCFET0NUWVBFIGh0bWw+DQo8aHRtbD4NCjxib2R5Pg0KDQo8cD5DbGljayB0aGUgYnV0dG9uIHRvIGNoZWNrIGlmIHRoZSB1bCBlbGVtZW50IHdpdGggaWQ9Im15TGlzdCIgaXMgdGhlIHNhbWUgYXMgdGhlIGRvY3VtZW50J3MgZmlyc3QgdWwgZWxlbWVudC48L3A+DQoNCjxidXR0b24gb25jbGljaz0ibXlGdW5jdGlvbigpIj5UcnkgaXQ8L2J1dHRvbj4NCg0KPHVsIGlkPSJteUxpc3QiPjxsaT5Db2ZmZWU8L2xpPjxsaT5UZWE8L2xpPjwvdWw+DQoNCjxwPjxzdHJvbmc+Tm90ZTo8L3N0cm9uZz4gRmlyZWZveCBzdG9wcGVkIHN1cHBvcnRlZCB0aGlzIG1ldGhvZCBhcyBvZiB2ZXJzaW9uIDEwLCBJbnN0ZWFkLCB1c2UgPT09IHRvIGNvbXBhcmUgaWYgdHdvIG5vZGVzIGFyZSB0aGUgc2FtZS48L3A+DQoNCjxwPjxzdHJvbmc+Tm90ZTo8L3N0cm9uZz4gSW50ZXJuZXQgRXhwbG9yZXIgOCBhbmQgZWFybGllciBkb2VzIG5vdCBzdXBwb3J0IHRoZSBpc1NhbWVOb2RlKCkgbWV0aG9kLjwvcD4NCg0KPHAgaWQ9ImRlbW8iPjwvcD4NCg0KPHNjcmlwdD4NCmZ1bmN0aW9uIG15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