But for the added security you can store the time span in a cookie or a session variable using PHP or anyother web scripting language.
this is the function display you can paste the above piece of code in the head section of your HTML page. The HTML page may contain the following lines of code.
This is a simple, code and you can change it to make it more powerful and attractive,
Note: This is an old post from my another blog, if you face any problem running the code, please report !!