Entering Data Problem


Posted on 16th Feb 2014 07:03 pm by admin

Code: $result = mysql_query("SELECT * FROM flights");
while ($row = mysql_fetch_array($result))
{

Did you know?Explore Trending and Topic pages for more stories like this.
if ($flight_num == $row['flight_num']){
echo "<center>Flight Number Used!</center>";
}else{

$sql=mysql_query("INSERT INTO flights (`flight_num`, `dep_icao`, `dep_time`, `dep_name`, `arr_icao`, `arr_time`, `arr_name`, `route`, `aircraft`, `days`, `duration`, `status`)
VALUES ('$flight_num','$dep','$dep_time','$dep_name','$arr','$arr_time','$arr_name','$route','$aircraft','$days','$duration','$status')");
header ('Location: ?page=flt_ctr');

}}
No comments posted yet

Your Answer:

Login to answer
196 Like 47 Dislike
Previous forums Next forums
Other forums

that old Malformed Headers problem again!!!!! HELP!!!!!!
I've read the http://www.phpfreaks.com/forums/index.php/topic,37442.0.html

I don't think my c

Baffled by Undefined Index in Simple Array: Please Help!
Hello. I have a form which posts an array to this script. However, I can't seem to access the values

How do I send data using an html link
Hi

If I have
<a href="main_file.php">

How do I send data t

Change snippet to use CURDATE
I am using time() in the snippet below, I would like to use CURDATE() and have the database setup fo

user administration
Dear @all,

what I have to do to set the user defaults for new users. At the moment I woul

What are causes of a connection-timeout with fopen()?
Hello! Here is the situation: The server I host my website on just upgraded it's PHP build from 4.4.

Rounding a number queried from a database
I know that to display a rounded number you just do echo "round($number)";. But how would

Is there a quick way to do this?
Hi all,

I need to create a mysql table from php that goes a little something like this

Looking for help reading a .txt or .ini file and outputting the info.
I have a file called Info.ini and It has the following info:
Code: [General]
Online=0
I wou

Modal Popup Help
Hi guys, I have a modal popup with an iframe. How can i send data from a label or textbox to the ifr

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash