Recently installed Phalcon 1.3.2 on RHEL 6.5 on PPC64, PHP 5.3.3. The installation went w/o a hitch and we can verify using php_info() and get_loaded_extensions(), but the framework isn't working as expected. In running a simple "Hello world" type of application the exception below is thrown.
Fatal error: Uncaught exception 'Phalcon\Mvc\Dispatcher\Exception' with message 'Parameters must be an Array' in /phalcon/public/index.php:35
Stack trace:
#0 [internal function]: Phalcon\Mvc\Dispatcher->_throwDispatchException('Parameters must...')
#1 [internal function]: Phalcon\Dispatcher->setParams(NULL)
#2 /phalcon/public/index.php(35): Phalcon\Mvc\Application->handle()
#3 {main}
thrown in /phalcon/public/index.php on line 35
Directory structure to my application:
phalcon/
app/
controllers/
IndexController.php
public/
.htaccess
index.php
.htaccess
Index.php, I used Tutorial 1's bootstrap w/o the exception catch:
<?php
error_reporting(E_ALL);
ini_set('display_errors', 1);
//Register an autoloader
$loader = new \Phalcon\Loader();
$loader->registerDirs(array(
'../app/controllers/',
'../app/models/'
))->register();
//Create a DI
$di = new Phalcon\DI\FactoryDefault();
//Setup the view component
$di->set('view', function(){
$view = new \Phalcon\Mvc\View();
$view->setViewsDir('../app/views/');
return $view;
});
//Setup a base URI so that all generated URIs include the "tutorial" folder
$di->set('url', function(){
$url = new \Phalcon\Mvc\Url();
$url->setBaseUri('/phalcon/');
return $url;
});
//Handle the request
$application = new \Phalcon\Mvc\Application($di);
echo $application->handle()->getContent();
IndexController.php:
<?php
class IndexController extends \Phalcon\Mvc\Controller
{
public function indexAction()
{
echo "<h1>Hello!</h1>";
}
}
Any ideas? I've attempted to research what might be causing the issue, but haven't had any luck so far.
I also attempted running the unit tests in phalcon/cphalcon/unit-tests and multiple tests fail (can provide specifics).
Thanks in advance for any insight.