Rockwood
-
Posts
1 -
Joined
-
Last visited
We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.
Help me Please to Fix this error
in Third Party Scripts
Posted · Edited by Rockwood
$getDelTimesQue = $this->query("SELECT * FROM deltimes WHERE state=1 AND ( value=CURDATE() ) ");
if (mysql_num_rows( $getDelTimesQue )) {
while ($row = mysql_fetch_assoc( $getDelTimesQue )) {
if ($row['type'] == 'single') {
global $message;
$message = $row['text'];
return false;
}
}
}
}
This is happening because your $subject = mysql_query("SELECT * FROM deltimes WHERE state=1 AND ( value=CURDATE() ) "); returned FALSE due to the query failing, use mysql_error() to find out the error.
Usually do mysql_query() or die (mysql_error()) to ensure the code doesn't continue after an error.