I am using sort field in order to sort records. My code is this
$query = "SELECT max(sort) FROM $this->table LIMIT 1;";
$result = mysql_query($query);
$row = mysql_fetch_row($result);
$sort = $row[0]+1;
$query = "INSERT INTO "$this->table." VALUES ( '', '$ini', '$time', '$ip', '0', '$type', '$sort', '$title', '$image', '0' );";
$result = mysql_query($query) or die(mysql_error());
What is the error here?