अवलोकन
document.head प्रॉपर्टी दस्तावेज़ के <head> तत्व को संदर्भित करती है। आप इसकी आईडी या अन्य प्रॉपर्टीज़ प्राप्त कर सकते हैं।
उदाहरण
<!DOCTYPE html> <html> <head id = "myid"> <title>JavaScript Example</title> </head> <body> <h1>Employee Information</h1> <form> Name: <input type = "text" name = "name" value = "Amit"><br> Subject: <input type = "text" name = "sub" value = "Java"> </form> <script> var a = document.head.id; document.write("<br>Head element id? "+a); </script> </body> </html>