Jump to content



Recommended Posts

I whas wondering can u change the title of a document with java script:Like if it is in the morning the title would be Good morning.And if it whas in the afternoon it woudld be like Good day.I whas thinking of a way with javascript and html DOM .?like

<html><title> </title><head></head><body><script type="text/javascript">function lol(){if (getHours()<=12){document.getElementByTagName("title").write="Good morning";}else{document.getElementByTagName("title").write="Good day";}document.write (document.title)}</script></body></html>

But this script ain't working pls help

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...