IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Symfony PHP Discussion :

Erreur en suivant le tutoriel "Créer sa première application web en PHP avec Symfony2" [2.x]


Sujet :

Symfony PHP

  1. #1
    Candidat au Club
    Homme Profil pro
    Développeur Web
    Inscrit en
    Février 2012
    Messages
    7
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Paris (Île de France)

    Informations professionnelles :
    Activité : Développeur Web
    Secteur : Service public

    Informations forums :
    Inscription : Février 2012
    Messages : 7
    Points : 4
    Points
    4
    Par défaut Erreur en suivant le tutoriel "Créer sa première application web en PHP avec Symfony2"
    Bonjour
    j'ai un problème lorsque je suis entrent de suivre le tutoriel
    http://j-place.developpez.com/tutori...avec-symfony2/
    et lorsque j'essaye de ouvrir la page
    http://localhost:8888/Symfony/web/ap...acteur/ajouter
    jai un message d'erreur
    Fatal error: Declaration of MyApp\FilmothequeBundle\Form\ActeurForm::buildForm() must be compatible with Symfony\Component\Form\FormTypeInterface::buildForm(Symfony\Component\Form\FormBuilderInterface $builder, array $options) in /Applications/MAMP/htdocs/Symfony/src/MyApp/FilmothequeBundle/Form/ActeurForm.php on line 7
    j'ai besoin d'aide.SVPL

  2. #2
    Membre actif Avatar de John Blobsmith
    Profil pro
    Inscrit en
    Avril 2004
    Messages
    198
    Détails du profil
    Informations personnelles :
    Localisation : France

    Informations forums :
    Inscription : Avril 2004
    Messages : 198
    Points : 223
    Points
    223
    Par défaut
    Je pense que c'est normal, le tutoriel fonctionne pour symfony 2.0, la dernière version de symfony est la 2.1.6 et ne semble pas être compatible au niveau des formulaires avec la version 2.0.

    Quelle version a-tu installé ?

  3. #3
    Nouveau Candidat au Club
    Profil pro
    Inscrit en
    Décembre 2012
    Messages
    1
    Détails du profil
    Informations personnelles :
    Localisation : France

    Informations forums :
    Inscription : Décembre 2012
    Messages : 1
    Points : 1
    Points
    1
    Par défaut
    MyApp\FilmothequeBundle\Form\ActeurForm::buildForm() must be compatible with Symfony\Component\Form\FormTypeInterface::buildForm(Symfony\Component\Form\FormBuilderInterface $builder, array $options) in /Applications/MAMP/htdocs/Symfony/src/MyApp/FilmothequeBundle/Form/ActeurForm.php on line 7
    L'erreur parle d'elle même
    remplace la déclaration de buildForm(...) par
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    buildForm(FormBuilderInterface $builder, array $options)
    N'oublie pas d'ajouter l'use suivant si ce n'est pas déjà fait :
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    use Symfony\Component\Form\FormBuilderInterface;
    Benjamin

  4. #4
    Candidat au Club
    Homme Profil pro
    Développeur Web
    Inscrit en
    Février 2012
    Messages
    7
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Paris (Île de France)

    Informations professionnelles :
    Activité : Développeur Web
    Secteur : Service public

    Informations forums :
    Inscription : Février 2012
    Messages : 7
    Points : 4
    Points
    4
    Par défaut
    Merci bq bq

+ Répondre à la discussion
Cette discussion est résolue.

Discussions similaires

  1. Créer sa première application Web
    Par zoom61 dans le forum Langage
    Réponses: 13
    Dernier message: 02/06/2017, 07h54
  2. [2.x] Créer sa première application Web en PHP avec Symfony2
    Par thierry0901 dans le forum Symfony
    Réponses: 10
    Dernier message: 13/10/2013, 18h47
  3. [2.x] Créer sa première application Web en PHP avec Symfony2
    Par baderahmed dans le forum Symfony
    Réponses: 0
    Dernier message: 02/06/2011, 13h55

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo