Bonjour
je tourne en rond depuis un bon moment.
voici l'erreur afficher:
The autoloader expected class "La\LingerieBundle\Entity\Commentaire" to be defined in file "C:\wamp\www\Symfony2/src\La\LingerieBundle\Entity\Commentaire.php". The file was found but the class was not in it, the class name or namespace probably has a typo.
500 Internal Server Error - RuntimeException
il y a ces code
routing.yml

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
 
LaLingerieBundle:
    resource: "@LaLingerieBundle/Resources/config/routing.yml"
    prefix:   /
et Resources/config/routing.yml
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
 
LaLingeriehomepage:
    path:  /
    defaults: { _controller: LaLingerieBundle:Default:index }
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
 
<?php
 
namespace La\LingerieBundle\Controller;
 
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use La\LingerieBundle\Entity\Commentaire;
class DefaultController extends Controller
{
 
 
    public function indexAction()
    {
        $c = new Commentaire();
        $form = $this->createForm(new CommentaireType(), $c);
 
        $request = $this->get('request');
 
 
        if ($request->getMethod() == 'POST') {
            $form->bind($request);
            if ($form->isValid()) {
                $em = $this->getDoctrine()->getManager();
                $em->persist($c);
                $em->flush();
                return $this->redirect($this->generateUrl('LaLingeriehomepage'));
 
            }
        }
        return $this->render('LaLingerieBundle:Default:index.html.twig',array(
                'form' => $form->createView())
        );
    }
}