Packages

  • Nette
    • Application
      • Diagnostics
      • Responses
      • Routers
      • UI
    • Caching
      • Storages
    • ComponentModel
    • Config
      • Adapters
      • Extensions
    • Database
      • Diagnostics
      • Drivers
      • Reflection
      • Table
    • DI
      • Diagnostics
    • Diagnostics
    • Forms
      • Controls
      • Rendering
    • Http
    • Iterators
    • Latte
      • Macros
    • Loaders
    • Localization
    • Mail
    • Reflection
    • Security
      • Diagnostics
    • Templating
    • Utils
      • PhpGenerator
  • NetteModule
  • None
  • PHP

Functions

  • callback
  • dump
  • Overview
  • Package
  • Function
  • Tree
  • Deprecated
 1: <?php
 2: 
 3: /**
 4:  * Nette Framework (version 2.0.10 released on 2013-03-08, http://nette.org)
 5:  *
 6:  * Copyright (c) 2004, 2013 David Grudl (http://davidgrudl.com)
 7:  *
 8:  * For the full copyright and license information, please view
 9:  * the file license.txt that was distributed with this source code.
10:  */
11: 
12: 
13: 
14: /**
15:  * Check and reset PHP configuration.
16:  */
17: if (!defined('PHP_VERSION_ID')) {
18:     $tmp = explode('.', PHP_VERSION);
19:     define('PHP_VERSION_ID', ($tmp[0] * 10000 + $tmp[1] * 100 + $tmp[2]));
20: }
21: 
22: if (PHP_VERSION_ID < 50200) {
23:     throw new Exception('Nette Framework requires PHP 5.2.0 or newer.');
24: }
25: 
26: error_reporting(E_ALL | E_STRICT);
27: @set_magic_quotes_runtime(FALSE); // @ - deprecated since PHP 5.3.0
28: iconv_set_encoding('internal_encoding', 'UTF-8');
29: extension_loaded('mbstring') && mb_internal_encoding('UTF-8');
30: umask(0);
31: @header('X-Powered-By: Nette Framework'); // @ - headers may be sent
32: @header('Content-Type: text/html; charset=utf-8'); // @ - headers may be sent
33: 
34: 
35: 
36: /**
37:  * Load and configure Nette Framework.
38:  */
39: 
40: empty($GLOBALS[0]) && $GLOBALS[0] = array();
41: define('NETTE', TRUE);
42: define('NETTE_DIR', dirname(__FILE__));
43: define('NETTE_VERSION_ID', 20010); // v2.0.10
44: define('NETTE_PACKAGE', 'PHP 5.2 prefixed');
45: 
46: 
47: 
48: require_once dirname(__FILE__) . '/common/exceptions.php';
49: require_once dirname(__FILE__) . '/common/Object.php';
50: require_once dirname(__FILE__) . '/Utils/LimitedScope.php';
51: require_once dirname(__FILE__) . '/Loaders/AutoLoader.php';
52: require_once dirname(__FILE__) . '/Loaders/NetteLoader.php';
53: 
54: 
55: NNetteLoader::getInstance()->register();
56: 
57: require_once dirname(__FILE__) . '/Diagnostics/Helpers.php';
58: require_once dirname(__FILE__) . '/Diagnostics/shortcuts.php';
59: require_once dirname(__FILE__) . '/Utils/Html.php';
60: NDebugger::_init();
61: 
62: NSafeStream::register();
63: 
64: 
65: 
66: /**
67:  * NCallback factory.
68:  * @param  mixed   class, object, callable
69:  * @param  string  method
70:  * @return NCallback
71:  */
72: function callback($callback, $m = NULL)
73: {
74:     return new NCallback($callback, $m);
75: }
76: 
Nette Framework 2.0.10 (for PHP 5.2, prefixed) API API documentation generated by ApiGen 2.8.0