שאלה, מה הבעיה בקוד?
בדף הזה אני רוצה לקלוט מידע כמו שם ולינקים, ולהוסיף אותם לטבלה קיימת במסד נתונים ששמה works. <html> <body link="yellow" vlink="yellow" bgcolor=32CD32> <center> <form name="form1"> <table border="1"> <tr> <td><input type="text" name="text1" size="25" value="<?=$_POST["text1"]; ?>"></td> <td>הכנס מספר תמונה</td> </tr> <tr> <td><input type="text" name="text2" size="25" value="<?=$_POST["text2"]; ?>"></td> <td>הכנס שם תמונה</td> </tr> <tr> <td><input type="text" name="text3" size="25" value="<?=$_POST["text3"]; ?>"></td> <td>הכנס קישור לתמונה</td> </tr> <tr> <td><input type="text" name="text4" size="25" value="<?=$_POST["text4"]; ?>"></td> <td>הכנס תמונה מוגדלת</td> </tr> <tr> <td><input type="text" name="text5" size="25" value="<?=$_POST["text5"]; ?>"></td> <td>הכנס מחיר</td> </tr> <TD align="right"><INPUT type="SUBMIT" name="insert_button" value=" הכנס נתונים "></TD> <TD align="left"><INPUT type="RESET" value="נקה טופס"></TD> </table></center> <?php if (isset($_POST["insert_button"])) { $id_work=$_POST["text1"]; $name=$_POST["text2"]; $picture=$_POST["text3"]; $big_picture=$_POST["text4"]; $price=$_POST["text5"]; $host="localhost"; $user="******"; $password="******"; $db="******"; $con=@mysql_connect($host,$user,$password); @mysql_select_db($db); $sqlquery="INSERT INTO works (id_work,name,picture,big_picture,price) VALUES ( '$id_work','$name','$picture','$big_picture','$price')"; $theresult=@mysql_query($sqlquery,$con); } ?> בבקשה עזרה?
בדף הזה אני רוצה לקלוט מידע כמו שם ולינקים, ולהוסיף אותם לטבלה קיימת במסד נתונים ששמה works. <html> <body link="yellow" vlink="yellow" bgcolor=32CD32> <center> <form name="form1"> <table border="1"> <tr> <td><input type="text" name="text1" size="25" value="<?=$_POST["text1"]; ?>"></td> <td>הכנס מספר תמונה</td> </tr> <tr> <td><input type="text" name="text2" size="25" value="<?=$_POST["text2"]; ?>"></td> <td>הכנס שם תמונה</td> </tr> <tr> <td><input type="text" name="text3" size="25" value="<?=$_POST["text3"]; ?>"></td> <td>הכנס קישור לתמונה</td> </tr> <tr> <td><input type="text" name="text4" size="25" value="<?=$_POST["text4"]; ?>"></td> <td>הכנס תמונה מוגדלת</td> </tr> <tr> <td><input type="text" name="text5" size="25" value="<?=$_POST["text5"]; ?>"></td> <td>הכנס מחיר</td> </tr> <TD align="right"><INPUT type="SUBMIT" name="insert_button" value=" הכנס נתונים "></TD> <TD align="left"><INPUT type="RESET" value="נקה טופס"></TD> </table></center> <?php if (isset($_POST["insert_button"])) { $id_work=$_POST["text1"]; $name=$_POST["text2"]; $picture=$_POST["text3"]; $big_picture=$_POST["text4"]; $price=$_POST["text5"]; $host="localhost"; $user="******"; $password="******"; $db="******"; $con=@mysql_connect($host,$user,$password); @mysql_select_db($db); $sqlquery="INSERT INTO works (id_work,name,picture,big_picture,price) VALUES ( '$id_work','$name','$picture','$big_picture','$price')"; $theresult=@mysql_query($sqlquery,$con); } ?> בבקשה עזרה?