<?php /** * BakedCarrot application initialization file * * @package BakedCarrot * * * * */ // turning on error reporting error_reporting(E_ALL | E_STRICT); // loading main library file require SYSPATH . 'App.php'; // init App::create(array('config' => APPPATH . 'config.php', 'mode' => App::MODE_DEVELOPMENT)); // default route Router::add('default', '/', array('controller' => 'index')); // run the application App::run();
<?php /* * Created on 30/06/2010 * core.App.test.php */ include_once './basic/core.basic.String.class.php'; include_once './config/core.config.YuppConventions.class.php'; include_once './support/core.support.YuppContext.class.php'; include_once './mvc/core.mvc.ViewCommand.class.php'; include_once './mvc/core.mvc.YuppController.class.php'; include_once 'core.YuppSession.class.php'; include_once 'core.App.class.php'; chdir('../'); include_once 'core.YuppLoader.class.php'; /* $app = new App('georef_stub'); print_r( $app->getModel() ); $comm = $app->execAction('geoRef','filtroCalles', new ArrayObject(array('dpto'=>'Artigas','calle'=>'Rivera'))); print_r($comm); */ $app = new App('blog'); print_r($app->getModel()); print_r($app->getDescriptor()); echo '<h1>Intento crear app carlox</h1>'; App::create('carlox');
<?php /* * Parser and Getter for Mopidy */ if (!defined('BASE_PATH')) { define('BASE_PATH', dirname(dirname(__FILE__))); } require BASE_PATH . '/vendor/autoload.php'; require BASE_PATH . '/lib/App.php'; $app = App::create(); $getter = new Pimusic\Getter(); $gmworker = new \GearmanWorker(); # Add default server (localhost). $gmworker->addServer(); $gmworker->addFunction("getter", [$getter, 'work']); print "Waiting for job...\n"; while ($gmworker->work()) { if ($gmworker->returnCode() != GEARMAN_SUCCESS) { echo "return_code: " . $gmworker->returnCode() . "\n"; break; } }
public function error404() { App::create()->template->setData(['title' => '404 Not Found'])->render('errors/404'); }
/** * in: name 1..1 * in: description * in: langs * in: controller */ public function createAppAction() { if (isset($this->params['doit'])) { if (!isset($this->params['name'])) { $this->flash['message'] = 'El nombre de la aplicacion es obligatorio'; return; } App::create($this->params['name'], (array) $this->params); return $this->redirect(array('action' => 'index')); } }
public function create() { $app = new App(); $result = $app->create(); header("Location: show"); }
<?php if (!defined('BASE_PATH')) { define('BASE_PATH', dirname(dirname(__FILE__))); } define('BOT_PREFIX', 'PiMusic'); require BASE_PATH . '/vendor/autoload.php'; require BASE_PATH . '/lib/App.php'; App::create();