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
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.