[ Поиск ] - [ Пользователи ] - [ Календарь ]
Полная Версия: Ошибка Warning: mysql_num_rows
fortuna
Не понять , ругаеться на 104 строку .
на эту if (mysql_num_rows($result) > 0){
function insert_model_spec($model_id,$text,$iuserfile){ 
db_connect();

if ($model_id){
$text = mysql_real_escape_string ($text);
$result = mysql_query("SELECT * FROM model_spec WHERE mod_id = '$model_id' ");
if (!$result){echo ('Невозможно выполнить запрос к БД');}

if (mysql_num_rows($result) > 0){
echo ('Возможно это имя или е-майл уже заняты ! ');
}else{
$result = mysql_query("INSERT INTO model_spec (spec_id,mod_id,spec_text,spec_image) VALUES ('', '$model_id','$text','$iuserfile')") or die (mysql_error()) ;
echo "Данные занесены в базу успешно .";
return $result;
}
}
else{echo "ERRORS - BSD !"; }
}



Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in Z:\home\localhost\www\text\insert_model_x.php on line 104
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 '2' class='b-properties__title'>Основные хар�' at line 1
Быстрый ответ:

 Графические смайлики |  Показывать подпись
Здесь расположена полная версия этой страницы.
Invision Power Board © 2001-2024 Invision Power Services, Inc.