HTML & CSS Snippets

Name:Website Title
Description: Get the information on your title tag using javascript.

Code below...
<html>
<head>
<title>My Site Title</title>
</head>
<body>

<script type="text/javascript">

//Get the the information on the title tag and put on a variable
var title = document.getElementsByTagName("title")[0].innerHTML;

//Print out the variable value (the site title)
document.write(title)


</script>

</body>
</html>

« Back to HTML & CSS Snippets

Home | Site Map | Privacy Policy | Advertising | Contact Us
Copyright © 2006-2014 r2xDesign.net - All Rights Reserved.
eXTReMe Tracker