adzie Posted May 24, 2007 Author Share Posted May 24, 2007 thorpe thankyou for all your help. I still have a blank screen hmmm Quote Link to comment https://forums.phpfreaks.com/topic/52670-php-and-sql-script-windowslinux/page/2/#findComment-260887 Share on other sites More sharing options...
adzie Posted May 24, 2007 Author Share Posted May 24, 2007 any other suggestions?? Quote Link to comment https://forums.phpfreaks.com/topic/52670-php-and-sql-script-windowslinux/page/2/#findComment-261066 Share on other sites More sharing options...
adzie Posted May 25, 2007 Author Share Posted May 25, 2007 ok I've tried editing my insert script with the similar variables, but still no joy Quote Link to comment https://forums.phpfreaks.com/topic/52670-php-and-sql-script-windowslinux/page/2/#findComment-261584 Share on other sites More sharing options...
adzie Posted May 25, 2007 Author Share Posted May 25, 2007 joy I have the form displaying the user data <? $vid=$_GET['VID']; include("db.php"); $query="SELECT * FROM members WHERE vid='$vid'"; $result=mysql_query($query); $num=mysql_num_rows($result); $i=0; while ($i < $num) { $vid=mysql_result($result,$i,"vid"); $name=mysql_result($result,$i,"name"); $password=mysql_result($result,$i,"password"); ?> <b><font color="#000080" face="Verdana">Update Script Form</font></b> <form action="updated.php"> <p>VID: <input type="text" name="VID" value="<? echo "$vid"?>"?><br> Name: <input type="text" name="NAME" value="<? echo "$name"?>"?><br> PASSWORD: <input type="text" name="PASSWORD" value="<? echo "$password"?>"?><br> <input type="Submit" value="Update"> </p> </form> <? ++$i; } mysql_close(); ?> using the url up.php?VID=<user vid) i now get the details to appear on the screen as it did on the linux/unix but it wont update the db with this script i was using before, any ideas? <? $username=""; $password=""; $database=""; mysql_connect(localhost,$username,$password); $query="UPDATE members SET vid='$vid', name='$name', password='$password' WHERE vid='$vid'"; @mysql_select_db($database) or die( "Unable to select database"); mysql_query($query); echo "Record Updated"; mysql_close(); ?> Quote Link to comment https://forums.phpfreaks.com/topic/52670-php-and-sql-script-windowslinux/page/2/#findComment-261619 Share on other sites More sharing options...
adzie Posted May 25, 2007 Author Share Posted May 25, 2007 would anyone have any suggestions? thanks for all the help so far Quote Link to comment https://forums.phpfreaks.com/topic/52670-php-and-sql-script-windowslinux/page/2/#findComment-261718 Share on other sites More sharing options...
adzie Posted May 26, 2007 Author Share Posted May 26, 2007 does anyone have any suggestions? Quote Link to comment https://forums.phpfreaks.com/topic/52670-php-and-sql-script-windowslinux/page/2/#findComment-262084 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.