Php 致命错误:类';LoginForm';在Zend framework 2中找不到

Php 致命错误:类';LoginForm';在Zend framework 2中找不到,php,zend-framework,Php,Zend Framework,我被困在zend framework中,当我尝试登录时,我收到以下错误消息:致命错误:在第28行的C:\Program Files(x86)\zend\ZendServer\data\apps\http\Uuuu default\Uuu0\AplicacaoMediador1\1.0.0\u86\module\Anuncios\src\Anuncios\Controller\AnunciosController.php中找不到类'AnunciosController' 在这一行,我实例化了Log

我被困在zend framework中,当我尝试登录时,我收到以下错误消息:致命错误:在第28行的C:\Program Files(x86)\zend\ZendServer\data\apps\http\Uuuu default\Uuu0\AplicacaoMediador1\1.0.0\u86\module\Anuncios\src\Anuncios\Controller\AnunciosController.php中找不到类'AnunciosController' 在这一行,我实例化了LoginForm类的一个对象,它位于“Form”文件夹中

以下是控制器代码:

use Zend\Http\Request;
use Zend\Mvc\Controller\AbstractActionController;

use Anuncios\DTO\Credenciais;
use Anuncios\Infrastucture\Services\ImoServices;
use Anuncios\Form\LoginForm;

class AnunciosController extends AbstractActionController
{
public function indexAction()
{
    return array();
}

public function loginAction()
{
    $form = new LoginForm();
    $form->get('submit')->setValue('Login');

    $request = $this->getRequest();
    if ($request->isPost()) {

        session_start();
        ImoServices::Logout();

        $credenciais = new Credenciais();
        $form->setInputFilter($credenciais->getInputFilter());
        $form->setData($request->getPost());

        if ($form->isValid()) {
            $credenciais->exchangeArray($form->getData());

            if( ImoServices::Login($credenciais) )

                // Redirect to values
                return $this->redirect()->toRoute('anuncios', array('controller'=>'anuncios', 'action' => 'values'));
        }
    }
    return array('form' => $form);
}
下面是LoginForm类:

namespace Anuncios\Form;

use Zend\Form\Form;

class LoginForm extends Form
{
public function __construct($name = null)
{
    // we want to ignore the name passed
    parent::__construct('credenciais');

    $this->add(array(
        'name' => 'username',
        'type' => 'Text',
        'options' => array(
            'label' => 'Username',
        ),
    ));
    $this->add(array(
        'name' => 'password',
        'type' => 'Password',
        'options' => array(
            'label' => 'Password',
        ),
    ));

    $this->add(array(
        'name' => 'submit',
        'type' => 'Submit',
        'attributes' => array(
            'value' => 'Go',
            'id' => 'submitbutton',
        ),
    ));
}
}

AnunciosController
类的完整名称空间是什么?
Anuncios\Form\LoginForm
类的完整路径和文件名是什么?名称空间是
Anuncios\Controller
。“完整名称空间”是指所有内容吗?然后是
module\Anuncios\src\Anuncios\Controller\AnunciosController
Anuncios\Form\LoginForm
类的完整路径是
module\Anuncios\src\Anuncios\Form\LoginForm
。文件名是
LoginForm
。所有这些看起来都不错。为了帮助缩小问题范围,请查看
Credenciais
类是否可以通过复制
$Credenciais=new Credenciais()由
AnunciosController
类访问直接在
$form=new LoginForm()上方的行。然后尝试登录。如果您收到相同的错误消息,那么您就知道问题出在
LoginForm
类上。如果您收到另一条错误消息,提示无法加载
Credenciais
类,则此处存在更广泛的自动加载问题。您能否提供Anuncios模块的module.config.php代码?AnunciosController
类的完整命名空间是什么?
Anuncios\Form\LoginForm
类的完整路径和文件名是什么?名称空间是
Anuncios\Controller
。“完整名称空间”是指所有内容吗?然后是
module\Anuncios\src\Anuncios\Controller\AnunciosController
Anuncios\Form\LoginForm
类的完整路径是
module\Anuncios\src\Anuncios\Form\LoginForm
。文件名是
LoginForm
。所有这些看起来都不错。为了帮助缩小问题范围,请查看
Credenciais
类是否可以通过复制
$Credenciais=new Credenciais()由
AnunciosController
类访问直接在
$form=new LoginForm()上方的行。然后尝试登录。如果您收到相同的错误消息,那么您就知道问题出在
LoginForm
类上。如果您收到另一条错误消息,提示无法加载
Credenciais
类,则此处存在更广泛的自动加载问题。您能否提供Anuncios模块的module.config.php代码??