PHP beginner |
|
Hallo,
ik heb een probleempje met de volgende code:
$q = "SELECT
*
FROM
video
WHERE
tags LIKE ".$rel_q."
";
$r = mysqli_query($this->dbc,$q);
$related = mysqli_fetch_array($r,MYSQLI_ASSOC);
do {
if($related['viewkey'] == $this->viewkey) {
} else {
echo $related['title'].'<br />';
}
} while ($related = mysqli_fetch_array($r,MYSQLI_ASSOC));
$q = "SELECT * FROM video WHERE tags LIKE ".$rel_q." "; $r = mysqli_query($this->dbc,$q); $related = mysqli_fetch_array($r,MYSQLI_ASSOC); do { if($related['viewkey'] == $this->viewkey) { } else { echo $related['title'].'<br />'; } } while ($related = mysqli_fetch_array($r,MYSQLI_ASSOC));
En dit is de foutmelding:
Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, boolean given in C:\xampp\htdocs\ffmpeg\playvideo.class.php on line 255
Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, boolean given in C:\xampp\htdocs\ffmpeg\playvideo.class.php on line 262
Warning: mysqli_fetch_array() expects parameter 1 TO be mysqli_result, BOOLEAN given IN C:\xampp\htdocs\ffmpeg\playvideo.class.php ON line 255 Warning: mysqli_fetch_array() expects parameter 1 TO be mysqli_result, BOOLEAN given IN C:\xampp\htdocs\ffmpeg\playvideo.class.php ON line 262
hij verwijst telkens naar de lijnen waarop $related = mysqli_fetch_array... in voorkomt.
Ik heb al op internet gezocht, krijg dan vooral topics waarin staat dat je mysqli_error() moet toevoegen, maar wanneer ik dat doe, krijg ik exact dezelfde error, maar dan i.v.m. mysqli_error().
|