Answer the question
In order to leave comments, you need to log in
Mystic. Why is it displaying the wrong ID?
$res = $mysqli->query("SELECT n.*, c.id, c.name AS cat_name FROM news AS n LEFT JOIN categories AS c ON n.catid = c.id WHERE n.lang_id = '1'") or sqlerr(__FILE__, __LINE__, $mysqli->error);
while ($row = $res->fetch_array()) {
echo $row['id'];
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question