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

do while...woes
I'm sure this is childsplay but it is stumping me, everytime i try what I think would make this work

Multiple forms on the same page (safari)
Hello everyone,

I have 3 forms on the same page, that opens in a new window and submits to a

need help to creat database
Hello Team, please guys i am stuck from three days with paypal issue for IPN but no luck yet now i w

ALV grid with 2 headers
Hi Gurus,

I need to display ALV GRID as below.

Header1

how to transport the Query and insfoset
Hi

I have created the query using SQ01........
How to created T-code for query..

Object Interfaces
EDIT: Never mind, I just updated to php 5.

Hey all,

I'm currently experimenting with p

tell csv import script to ignore blank rows?
Hi i have the below script but i get an error if a row is blank ie a return in the csv file at the e

Sessions Value Not Saved
Hi,

Im making a login form and im using this code:
Code: if($login=="true"){

Extracting Long text from message class with parameters
Hi,

I would like to extract the long text from a message class. However, the long text ha

Help with PHP Email Script
Hi guys,

I'm a newbie to php and need help with the script below:

At the moment when I

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