Ask a Question related to PHP Development, Design and Development.
-
The Voigts #1
creating rows in mysql with data
Hi i have two files
<HTML>
<BODY>
<form method="post" action="datain.php">
First name:<input type="Text" name="first"><br>
Last name:<input type="Text" name="last"><br>
Nick Name:<input type="Text" name="nickname"><br>
E-mail:<input type="Text" name="email"><br>
Salary:<input type="Text" name="salary"><br>
<input type="Submit" name="submit" value="Enter information">
</form>
</HTML>
and
<HTML>
<?php
$db = mysql_connect("localhost", "root","");
mysql_select_db("learndb",$db);
$sql = "INSERT INTO personnel (firstname, lastname, nick, email, salary)
VALUES ('$first','$last','$nickname','$email','$salary')" ;
$result = mysql_query($sql);
echo "Thank you! Information entered.\n";
?>
</HTML>
this creates empty rows and nothing else. the data i enter in the form isnt
being used. can someone help? Im running phpdev v423.
Thanks
The Voigts Guest
-
extension for creating professional charts based on mysql data?
Hi all, is there an extension for dreamweaver 8 to make professional Charts (line)? I'm using Dymanic Flash Chart but it lach an important... -
creating unique rows
Hi. I know how to do this in a script, but i'm trying to use DB commands to do my data aquisition and creation. Here's what i'm trying to do. I... -
working RSS code - creating using mysql data ??
I already have my news page pulled from mysql I am hoping to have a dynamically generated rss scrtipt, I've tried downloaing a few and modifying... -
are there any guides to creating a dynamic menu from mysql data?
I'd like to create a menu system thats dynamic in nature and pulls the page id ,name, title etc from a mysql table so that when a page is added it... -
Help in creating data entry forms with MySQL
Hi, I was wondering if any of you experts has some example of MySQL data entry form either using PHP or any public domain software for my photo... -
Jedi121 #2
Re: creating rows in mysql with data
The Voigts a écrit le 29/01/2004 :
[...][...]> $sql = "INSERT INTO personnel (firstname, lastname, nick, email, salary)
> VALUES ('$first','$last','$nickname','$email','$salary')" ;Try using $_POST['var'] instead of $var :> this creates empty rows and nothing else. the data i enter in the form isnt
> being used. can someone help? Im running phpdev v423.
$sql = "INSERT INTO personnel (firstname, lastname, nick, email,
salary) "
."VALUES
('".$_POST['first']."','".$_POST['last']."','".$_POST['nickname']."','".$_POST['email']."','".$_POST['salary']."')";
Jedi121 Guest



Reply With Quote

