PageRenderTime 82ms CodeModel.GetById 40ms app.highlight 2ms RepoModel.GetById 38ms app.codeStats 0ms

/public/zf-demos/Zend/Wildfire/public/index.php

https://bitbucket.org/hieronim1981/tunethemusic
PHP | 66 lines | 21 code | 17 blank | 28 comment | 0 complexity | 5c368292f1c2ab91b6d3d3b02f49d752 MD5 | raw file
 1<?php
 2/**
 3 * Zend Framework
 4 *
 5 * LICENSE
 6 *
 7 * This source file is subject to the new BSD license that is bundled
 8 * with this package in the file LICENSE.txt.
 9 * It is also available through the world-wide-web at this URL:
10 * http://framework.zend.com/license/new-bsd
11 * If you did not receive a copy of the license and are unable to
12 * obtain it through the world-wide-web, please send an email
13 * to license@zend.com so we can send you a copy immediately.
14 *
15 * @category   Zend
16 * @package    Zend_Wildfire
17 * @copyright  Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
18 * @license    http://framework.zend.com/license/new-bsd     New BSD License
19 */
20
21/* NOTE: You must have Zend Framework in your include path! */
22
23/*
24 * Add our Firebug Log Writer to the registry
25 */
26
27require_once 'Zend/Registry.php';
28require_once 'Zend/Log.php';
29require_once 'Zend/Log/Writer/Firebug.php';
30
31$writer = new Zend_Log_Writer_Firebug();
32$writer->setPriorityStyle(8, 'TABLE');
33$writer->setPriorityStyle(9, 'TRACE');
34
35$logger = new Zend_Log($writer);
36$logger->addPriority('TABLE', 8);
37$logger->addPriority('TRACE', 9);
38
39Zend_Registry::set('logger',$logger);
40
41
42/*
43 * Add our Firebug DB Profiler to the registry
44 */
45
46require_once 'Zend/Db.php';
47require_once 'Zend/Db/Profiler/Firebug.php';
48
49$profiler = new Zend_Db_Profiler_Firebug('All DB Queries');
50
51$db = Zend_Db::factory('PDO_SQLITE',
52                       array('dbname' => ':memory:',
53                             'profiler' => $profiler));
54
55$db->getProfiler()->setEnabled(true);
56
57Zend_Registry::set('db',$db);
58
59
60/*
61 * Run the front controller
62 */
63
64require_once 'Zend/Controller/Front.php';
65
66Zend_Controller_Front::run(dirname(dirname(__FILE__)).'/application/controllers');