Bonjour chers amis,
je trouve cette erreur
Warning: PDOStatement::execute() [pdostatement.execute]: SQLSTATE[HY093]: Invalid parameter number: number of bound variables does not match number of tokens in D:\wamp\www\ivoirehub\forum\voirforum.php on line 117
sur ma page après la modification de ce bout de code
Code php : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
<?php $query=$db->prepare('SELECT forum_topic.topic_id, topic_titre, topic_createur, topic_vu, topic_post, topic_time, topic_last_post, topic_locked,
	Mb.membre_pseudo AS membre_pseudo_createur, post_id, post_createur, post_time, Ma.membre_pseudo AS membre_pseudo_last_posteur; '.$add1.'  FROM forum_topic
						LEFT JOIN forum_membres Mb ON Mb.membre_id = forum_topic.topic_createur
						LEFT JOIN forum_post ON forum_topic.topic_last_post = forum_post.post_id
						LEFT JOIN forum_membres Ma ON Ma.membre_id = forum_post.post_createur '.$add2.'  
						WHERE topic_genre <> "Annonce" AND forum_topic.forum_id = :forum
						ORDER BY topic_last_post DESC LIMIT :premier ,:nombre');
	$query->bindValue(':forum',$forum,PDO::PARAM_INT);
	if($id!=0) $query->bindValue(':forum',$forum,PDO::PARAM_INT);
	$query->bindValue(':premier',(int) $premierMessageAafficher,PDO::PARAM_INT);
	if($id!=0) $query->bindValue(':premier',(int) $premierMessageAafficher,PDO::PARAM_INT);
	$query->bindValue(':nombre',(int) $nombreDeMessagesParPage,PDO::PARAM_INT);
	if($id!=0) $query->bindValue(':nombre',(int) $nombreDeMessagesParPage,PDO::PARAM_INT);
	$query->execute();?>
La ligne 117 est la dernière ligne leMerci de m'apporter votre soutien.