Go Back   Forum Care Forums > Development Reference Area > MySQL Discussion

Reply
 
LinkBack Thread Tools Display Modes
mysql_fetch_array
Old
  (#1)
Guest
Guest
 
Posts: n/a
Default mysql_fetch_array - 06-04-2007, 07:58 AM

HI

<?php
include('conn.php');
mysql_query("insert into reg values ('".$_POST['fname']."','".
$_POST['lname']."')");
$result1=mysql_query("select * from reg");
while($row1=mysql_fetch_array($result1)) {
echo $row1['firstname'];
echo $row1['lastname'];
}
?>
<?php // 2 statement...............
$result=mysql_query("SELECT * FROM reg order by id desc limit 0,1");
while($row=mysql_fetch_array($result)) {
?>
<a href="three.php?view=<? echo $row['id']; ?>">View</a>
<? } ?>

in this above code previously values are inserted after adding 2nd
statement the values are not inserted what is problem in my code plz
respond...............

   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




Contact Us - Forum Care Forums - Archive - Top