My codeļ¼ $di = new \Phalcon\DI\FactoryDefault(); $di->set('router', function() { $router = new \Phalcon\Mvc\Router\Annotations(false); $router->setDefaultModule("frontend"); $router->addResource('Products', '/api/products'); return $router; }); $application = new \Phalcon\Mvc\Application();
$application->setDI($di);
$application->registerModules(array(
'frontend' => array(
'className' => 'Frontend\Module',
'path' => '../apps/frontend/Module.php'
)
));
echo $application->handle()->getContent();
Fatal error: Phalcon\Mvc\Router\Annotations::handle(): The argument is not iterable() in /var/www/html/public/index.php on line 47