JavaScript DHTML/Document/all — различия между версиями
Admin (обсуждение | вклад) м (1 версия) |
|
(нет различий)
|
Версия 12:59, 26 мая 2010
Check if a tag exists
<source lang="html4strict">
<html> <head> <title>A Simple Page</title> <script language="JavaScript"> function findhead1() {
var detectElement = document.all("head1"); if (detectElement == head1) { alert("Element \"head1\" exists"); }
} </script> </head> <body onload="findhead1()">
Heading One
</body> </html>
</source>