Jump to content

Help with time


kiml

Recommended Posts

Hey folks.

 

I need help making a function to print up the nearest route comparing to current time.

I have 3 values in my SQL that may be of your interest -> ID, deparure_time and departure_minuttes.

They are saved like -> 236, 12, 21

 

I have allredy maked the basic in the code

$Route = "SELECT * FROM Ruter WHERE DepartureID = '$Neste_flyvning_dep' 
                                                     AND     ArrivalID = '$Neste_flyvning_arr' 
                                                     AND FlyType = '$Flytype_pilot' 
                                                     LIMIT 1";
$Rtr = mysql_query($Route) or die ("Cant run logg". mysql_error());
	while ($FlightnrQ = mysql_fetch_array($Rtr))
		{	
Print "<b>$FlightnrQ[RuteNr]</b> - Departure $FlightnrQ[departure_time]:$FlightnrQ[departure_minutt]<br>";
				}

But I need some help to view only the next route.

 

Somebody who know how to do this stuff?

Link to comment
https://forums.phpfreaks.com/topic/37890-help-with-time/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.