אחי תראה עכשיו עשיתי את הקוד ככה:
PHP קוד:
<?php
error_reporting(E_ALL);
@include 'connect.php';
@$id=$_GET['id'];
@$en = $_POST['en'];
@$he = $_POST['he'];
@$art = $_POST['art'];
@$year = $_POST['year'];
@$size = $_POST['size'];
@$up = $_POST['up'];
@$cat = $_POST['cat'];
@$list = $_POST['list'];
@$note = $_POST['note'];
@$link = $_POST['link'];
@$pic = $_POST['pic'];
mysql_query("update `ds` set en='$en', he='$he' , art='$art' , year='$year' , size='$size' , up='$up' , cat='$cat' , list='$list' , note='$note' , link='$link' , pic='$pic' where id=$id") or die(mysql_error());
echo "<script>window.location=\'index.php\'</script>";
?>
שים לב ששמתי
PHP קוד:
@$id=$_GET['id'];
במקום
PHP קוד:
$id = $_POST["id"];
זה יכול להיות קשור?
עריכה:
עכשיו זה עושה לי את השגיאה הזאת:
PHP קוד:
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1