Parse error: syntax error, unexpected ';', expecting '{'
Résolu
Zakarya93
Messages postés
1026
Statut
Membre
-
Zakarya93 Messages postés 1026 Statut Membre -
Zakarya93 Messages postés 1026 Statut Membre -
Bonjour,
J'ai cette erreur : Parse error: syntax error, unexpected ';', expecting '{' in C:\wamp\www\rs\functions\update.func.php on line 4
update.func.php :
J'ai cette erreur : Parse error: syntax error, unexpected ';', expecting '{' in C:\wamp\www\rs\functions\update.func.php on line 4
update.func.php :
<?php
//la function qui va changer les informations du membre
function changer_informations_membre($email,$apropos);
{
$request = $bdd->prepare('UPDATE utilisateurs SET email = :email, apropos = :apropos');
$request->execute(array(
'email' => $email,
'apropos' => $apropos
));
}
?>
A voir également:
- Php parse error: syntax error, unexpected token "use"
- Eespt technical error ✓ - Forum TNT / Satellite / Réception
- Pointage antenne ✓ - Forum TNT / Satellite / Réception
- Fan error lenovo - Forum PC portable
- A disk read error occurred ✓ - Forum Windows
- Error 1962 ✓ - Forum PC fixe
-Notice: Undefined variable: bdd in C:\wamp\www\rs\functions\update.func.php on line 6
-Fatal error: Call to a member function prepare() on a non-object in C:\wamp\www\rs\functions\update.func.php on line 6
au début de ta fonction !
<?php //la function qui va changer les informations du membre function changer_informations_membre($email,$apropos) global $bdd; // déclaration globale de BDD { $request = $bdd->prepare('UPDATE utilisateurs SET email = :email, apropos = :apropos'); $request->execute(array( 'email' => $email, 'apropos' => $apropos )); } ?><?php //la function qui va changer les informations du membre function changer_informations_membre($email,$apropos) { global $bdd; // déclaration globale de BDD $request = $bdd->prepare('UPDATE utilisateurs SET email = :email, apropos = :apropos'); $request->execute(array( 'email' => $email, 'apropos' => $apropos )); } ?>RESOLU MERCI :)