madspof Posted October 26, 2006 Share Posted October 26, 2006 I have created this script and i cannot not get it to work anyone that could fix it and point out were i went wrong I would be very gratefull.<html><head><title></title><META HTTP-EQUIV="refresh" content="60;URL=status1.php"> <style type="text/css"><!--body { background-image: url(navi.jpg);}--></style><!-- The closing HEAD tag is right below this --></head><body bgcolor="white"><?php$hour = date('i/s');$time = 10/00if ($hour <= $time) { echo "It's before ten minutes";} else { echo "Its past ten minutes"; }?> </body></html> Quote Link to comment Share on other sites More sharing options...
Psycho Posted October 26, 2006 Share Posted October 26, 2006 [code]<?php$minutes = date('i') + date('s')/60;if ($minutes <= 10) { echo "It's before ten minutes" . $minutes;} else { echo "Its past ten minutes" . $minutes;}?> [/code] Quote Link to comment Share on other sites More sharing options...
madspof Posted October 26, 2006 Author Share Posted October 26, 2006 what is the need for the /60 Quote Link to comment Share on other sites More sharing options...
Psycho Posted October 26, 2006 Share Posted October 26, 2006 I was calculating minutes. So, if you have 9 minutes and 30 seconds you can't just add them together - you would have 39.9 minutes + 30 seconds/60 = 9.5 minutes. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.