Hi..

<?php
				$today = mktime(date('g')+5,date('i')+30,date('s'));                 
				$today=date("M j Y g:i a",$today);
				echo $today;
		?>

When i am refreshing page only that time i got the correct value of time...
so i want to show time i.e. continuously updated time on page without refresh page..

How to do that???

Live client side streaming with php... I wish.

Since this sort of question keeps appearing, I shall explain.
Php is only able to compile SERVER side code and can only send to the browser or user html, javascript, or css code. Other than that you would need to switch to a client side language like Flash, Ajax or Java which have nothing to do with php.

So when using php, since your final result is expected to be html, Javascript or Css script, it means you need to choose one of those 3 languages to display or continue processing after page has fully loaded. So in your case, you would need to use Javascript unless you want to switch to a non-php related client side script (Ajax, Java or Flash) then Ajax, Java and Flash can do the same thing as Ajax, Java and Flash are design to have simular abilities to php.

If you choose Javascript, there is a free clock provided at the below link which you can fiddle with.
http://www.javascriptkit.com/script/script2/digitalclock.shtml

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.