LOADER CODE
<?php
$loader = new \Phalcon\Loader();
$loader->registerNamespaces(
array(
'Site\Front\Controller' => __DIR__ . '/../../app/controllers/',
'Site\Model' => __DIR__ . '/../../app/models/',
)
)->register();
CONTROLLER CODE
namespace Site\Front\Controller;
Use Site\Library\Form\Resource;
class resourceController extends ControllerBase {
public function indexAction()
{
echo 'in';
// New Form
//$objForm = new Resource\NewForm();
//$this->view->setVar('newForm', $objForm->createForm());
}
// Add New Resource
public function addAction()
{
$strResource = $this->request->getPost('url', 'string');
// Creating Form
$objForm = new Resource\SubmitForm();
$this->Tag->setDefault('urlName', $strResource);
$this->view->setVar('addForm', $objForm->createForm());
}
}
Why is the controller not loading?