SYSPATH/classes/Kohana/URL.php [ 107 ]
102 }
103
104 // Validate $host, see if it matches trusted hosts
105 if ( ! static::is_trusted_host($host))
106 {
107 throw new Kohana_Exception(
108 'Untrusted host :host. If you trust :host, add it to the trusted hosts in the `url` config file.',
109 array(':host' => $host)
110 );
111 }
112 }
-
SYSPATH/classes/Kohana/URL.php [ 144 ] » Kohana_URL::base(arguments)
0bool TRUE
1bool TRUE
139 // Encode all non-ASCII characters, as per RFC 1738 140 $path = preg_replace_callback('~([^/]+)~', 'URL::_rawurlencode_callback', $path); 141 } 142 143 // Concat the URL 144 return URL::base($protocol, $index).$path; 145 } 146 147 /** 148 * Callback used for encoding all non-ASCII characters, as per RFC 1738 149 * Used by URL::site() -
SYSPATH/classes/Kohana/Route.php [ 221 ] » Kohana_URL::site(arguments)
0string(2) "es"1bool TRUE
216 217 // Create a URI with the route and convert it to a URL 218 if ($route->is_external()) 219 return $route->uri($params); 220 else 221 return URL::site($route->uri($params), $protocol); 222 } 223 224 /** 225 * Returns the compiled regular expression for the route. This translates 226 * keys and optional groups to a proper PCRE regular expression. -
APPPATH/views/main.php [ 25 ] » Kohana_Route::url(arguments)
0string(5) "index"1array(1) ( "lan" => string(2) "es" )
2bool TRUE
20 <div class="myooget"> 21 <div class="myoogetin"> 22 23 <div class="myoob"> 24 <div> 25 <a href="<?= Route::url('index', array('lan' => 'es'), TRUE ); ?>">EspaƱol</a> 26 <a href="<?= Route::url('index', array('lan' => 'pl'), TRUE ); ?>">Polski</a> 27 <a href="<?= Route::url('index', array('lan' => 'de'), TRUE ); ?>">Deutsch</a> 28 <a href="<?= Route::url('index', array('lan' => 'en'), TRUE ); ?>">English</a> 29 </div> 30 </div> -
SYSPATH/classes/Kohana/View.php [ 62 ] » include(arguments)
0string(41) "/home/foow.org/application/views/main.php"57 ob_start(); 58 59 try 60 { 61 // Load the view within the current scope 62 include $kohana_view_filename; 63 } 64 catch (Exception $e) 65 { 66 // Delete the output buffer 67 ob_end_clean(); -
SYSPATH/classes/Kohana/View.php [ 359 ] » Kohana_View::capture(arguments)
0string(41) "/home/foow.org/application/views/main.php"1array(4) ( "input" => string(0) "" "invalid" => bool FALSE "background" => integer 2 "language" => string(0) "" )
354 { 355 throw new View_Exception('You must set the file to use within your view before rendering'); 356 } 357 358 // Combine local and global data and capture the output 359 return View::capture($this->_file, $this->_data); 360 } 361 362 } -
SYSPATH/classes/Kohana/View.php [ 236 ] » Kohana_View->render()
231 */ 232 public function __toString() 233 { 234 try 235 { 236 return $this->render(); 237 } 238 catch (Exception $e) 239 { 240 /** 241 * Display the exception message. -
SYSPATH/classes/Kohana/Response.php [ 160 ] » Kohana_View->__toString()
155 public function body($content = NULL) 156 { 157 if ($content === NULL) 158 return $this->_body; 159 160 $this->_body = (string) $content; 161 return $this; 162 } 163 164 /** 165 * Gets or sets the HTTP protocol. The standard protocol to use -
APPPATH/classes/Controller/Main.php [ 270 ] » Kohana_Response->body(arguments)
0object View(2)
{ protected _file => string(41) "/home/foow.org/application/views/main.php" protected _data => array(4) ( "input" => string(0) "" "invalid" => bool FALSE "background" => integer 2 "language" => string(0) "" ) }265 266 }else $view->invalid = true; 267 }else $view->invalid = true; 268 } 269 270 $this->response->body($view); 271 } 272 273 public function action_lock(){ 274 $this->response->status('503'); 275 $this->response->headers('Retry-After', '300'); -
SYSPATH/classes/Kohana/Controller.php [ 84 ] » Controller_Main->action_index()
79 array(':uri' => $this->request->uri()) 80 )->request($this->request); 81 } 82 83 // Execute the action itself 84 $this->{$action}(); 85 86 // Execute the "after action" method 87 $this->after(); 88 89 // Return the response -
{PHP internal call} » Kohana_Controller->execute()
-
SYSPATH/classes/Kohana/Request/Client/Internal.php [ 97 ] » ReflectionMethod->invoke(arguments)
0object Controller_Main(6)
{ public download => object Model_Download(7){ private db_name_resource => string(8) "download" private db_name_resource_additional => string(19) "download_additional" private dir_work => string(8) "/srv/shm" private dir_ready => string(14) "/srv/shm/ready" private dir_remove => string(11) "/srv/remove" private prefered_country => array(5) ( "us" => string(13) "United States" "pl" => string(6) "Poland" "de" => string(7) "Germany" "ca" => string(6) "Canada" "se" => string(6) "Sweden" ) protected db => object Database_MySQLi(6)public resource => object Model_Resource(3){ protected _connection_id => string(40) "a177dea894a4d7b74f068632b25a467b4687766d" protected _identifier => string(1) "`" public last_query => string(94) "SELECT country FROM ip2nation WHERE ip < INET_ATON("194.210.235.5") ORDER BY ip DESC LIMIT 0,1" protected _instance => string(7) "default" protected _connection => object mysqli(19)}{ public affected_rows => NULL public client_info => NULL public client_version => NULL public connect_errno => NULL public connect_error => NULL public errno => NULL public error => NULL public error_list => NULL public field_count => NULL public host_info => NULL public info => NULL public insert_id => NULL public server_info => NULL public server_version => NULL public stat => NULL public sqlstate => NULL public protocol_version => NULL public thread_id => NULL public warning_count => NULL }protected _config => array(5) ( "type" => string(6) "MySQLi" "connection" => array(3) ( "hostname" => string(9) "localhost" "database" => string(10) "downloader" "persistent" => bool FALSE ) "table_prefix" => string(0) "" "charset" => string(4) "utf8" "caching" => bool FALSE ) }{ private path_resource => string(10) "/srv/files" private db_name_resource => string(8) "resource" protected db => object Database_MySQLi(6)public language => string(0) "" public list => object Model_List(2){ protected _connection_id => string(40) "a177dea894a4d7b74f068632b25a467b4687766d" protected _identifier => string(1) "`" public last_query => string(94) "SELECT country FROM ip2nation WHERE ip < INET_ATON("194.210.235.5") ORDER BY ip DESC LIMIT 0,1" protected _instance => string(7) "default" protected _connection => object mysqli(19)}{ public affected_rows => NULL public client_info => NULL public client_version => NULL public connect_errno => NULL public connect_error => NULL public errno => NULL public error => NULL public error_list => NULL public field_count => NULL public host_info => NULL public info => NULL public insert_id => NULL public server_info => NULL public server_version => NULL public stat => NULL public sqlstate => NULL public protocol_version => NULL public thread_id => NULL public warning_count => NULL }protected _config => array(5) ( "type" => string(6) "MySQLi" "connection" => array(3) ( "hostname" => string(9) "localhost" "database" => string(10) "downloader" "persistent" => bool FALSE ) "table_prefix" => string(0) "" "charset" => string(4) "utf8" "caching" => bool FALSE ) }{ private db_name => string(4) "list" protected db => object Database_MySQLi(6)public request => object Request(19){ protected _connection_id => string(40) "a177dea894a4d7b74f068632b25a467b4687766d" protected _identifier => string(1) "`" public last_query => string(94) "SELECT country FROM ip2nation WHERE ip < INET_ATON("194.210.235.5") ORDER BY ip DESC LIMIT 0,1" protected _instance => string(7) "default" protected _connection => object mysqli(19)}{ public affected_rows => NULL public client_info => NULL public client_version => NULL public connect_errno => NULL public connect_error => NULL public errno => NULL public error => NULL public error_list => NULL public field_count => NULL public host_info => NULL public info => NULL public insert_id => NULL public server_info => NULL public server_version => NULL public stat => NULL public sqlstate => NULL public protocol_version => NULL public thread_id => NULL public warning_count => NULL }protected _config => array(5) ( "type" => string(6) "MySQLi" "connection" => array(3) ( "hostname" => string(9) "localhost" "database" => string(10) "downloader" "persistent" => bool FALSE ) "table_prefix" => string(0) "" "charset" => string(4) "utf8" "caching" => bool FALSE ) }{ protected _requested_with => NULL protected _method => string(3) "GET" protected _protocol => string(8) "HTTP/1.0" protected _secure => bool FALSE protected _referrer => string(20) "http://www.foow.org/" protected _route => object Route(5)public response => object Response(5){ protected _filters => array(0) protected _uri => string(7) "(<lan>)" protected _regex => array(1) ( "lan" => string(11) "en|de|pl|es" ) protected _defaults => array(2) ( "controller" => string(4) "main" "action" => string(5) "index" ) protected _route_regex => string(31) "#^(?:(?P<lan>en|de|pl|es))?$#uD" }protected _routes => array(0) protected _header => object HTTP_Header(0){ }protected _body => NULL protected _directory => string(0) "" protected _controller => string(4) "Main" protected _action => string(5) "index" protected _uri => string(0) "" protected _external => bool FALSE protected _params => array(0) protected _get => array(0) protected _post => array(0) protected _cookies => array(0) protected _client => object Request_Client_Internal(9){ protected _previous_environment => NULL protected _cache => NULL protected _follow => bool FALSE protected _follow_headers => array(1) ( 0 => string(13) "authorization" ) protected _strict_redirect => bool TRUE protected _header_callbacks => array(1) ( "Location" => string(34) "Request_Client::on_header_location" ) protected _max_callback_depth => integer 5 protected _callback_depth => integer 1 protected _callback_params => array(0) }}{ protected _status => integer 200 protected _header => object HTTP_Header(0)}{ }protected _body => string(0) "" protected _cookies => array(0) protected _protocol => string(8) "HTTP/1.0" }92 93 // Create a new instance of the controller 94 $controller = $class->newInstance($request, $response); 95 96 // Run the controller's execute() method 97 $response = $class->getMethod('execute')->invoke($controller); 98 99 if ( ! $response instanceof Response) 100 { 101 // Controller failed to return a Response. 102 throw new Kohana_Exception('Controller failed to return a Response'); -
SYSPATH/classes/Kohana/Request/Client.php [ 114 ] » Kohana_Request_Client_Internal->execute_request(arguments)
0object Request(19)
{ protected _requested_with => NULL protected _method => string(3) "GET" protected _protocol => string(8) "HTTP/1.0" protected _secure => bool FALSE protected _referrer => string(20) "http://www.foow.org/" protected _route => object Route(5){ protected _filters => array(0) protected _uri => string(7) "(<lan>)" protected _regex => array(1) ( "lan" => string(11) "en|de|pl|es" ) protected _defaults => array(2) ( "controller" => string(4) "main" "action" => string(5) "index" ) protected _route_regex => string(31) "#^(?:(?P<lan>en|de|pl|es))?$#uD" }protected _routes => array(0) protected _header => object HTTP_Header(0){ }protected _body => NULL protected _directory => string(0) "" protected _controller => string(4) "Main" protected _action => string(5) "index" protected _uri => string(0) "" protected _external => bool FALSE protected _params => array(0) protected _get => array(0) protected _post => array(0) protected _cookies => array(0) protected _client => object Request_Client_Internal(9){ protected _previous_environment => NULL protected _cache => NULL protected _follow => bool FALSE protected _follow_headers => array(1) ( 0 => string(13) "authorization" ) protected _strict_redirect => bool TRUE protected _header_callbacks => array(1) ( "Location" => string(34) "Request_Client::on_header_location" ) protected _max_callback_depth => integer 5 protected _callback_depth => integer 1 protected _callback_params => array(0) }}1object Response(5)
{ protected _status => integer 200 protected _header => object HTTP_Header(0){ }protected _body => string(0) "" protected _cookies => array(0) protected _protocol => string(8) "HTTP/1.0" }109 $orig_response = $response = Response::factory(array('_protocol' => $request->protocol())); 110 111 if (($cache = $this->cache()) instanceof HTTP_Cache) 112 return $cache->execute($this, $request, $response); 113 114 $response = $this->execute_request($request, $response); 115 116 // Execute response callbacks 117 foreach ($this->header_callbacks() as $header => $callback) 118 { 119 if ($response->headers($header)) -
SYSPATH/classes/Kohana/Request.php [ 997 ] » Kohana_Request_Client->execute(arguments)
0object Request(19)
{ protected _requested_with => NULL protected _method => string(3) "GET" protected _protocol => string(8) "HTTP/1.0" protected _secure => bool FALSE protected _referrer => string(20) "http://www.foow.org/" protected _route => object Route(5){ protected _filters => array(0) protected _uri => string(7) "(<lan>)" protected _regex => array(1) ( "lan" => string(11) "en|de|pl|es" ) protected _defaults => array(2) ( "controller" => string(4) "main" "action" => string(5) "index" ) protected _route_regex => string(31) "#^(?:(?P<lan>en|de|pl|es))?$#uD" }protected _routes => array(0) protected _header => object HTTP_Header(0){ }protected _body => NULL protected _directory => string(0) "" protected _controller => string(4) "Main" protected _action => string(5) "index" protected _uri => string(0) "" protected _external => bool FALSE protected _params => array(0) protected _get => array(0) protected _post => array(0) protected _cookies => array(0) protected _client => object Request_Client_Internal(9){ protected _previous_environment => NULL protected _cache => NULL protected _follow => bool FALSE protected _follow_headers => array(1) ( 0 => string(13) "authorization" ) protected _strict_redirect => bool TRUE protected _header_callbacks => array(1) ( "Location" => string(34) "Request_Client::on_header_location" ) protected _max_callback_depth => integer 5 protected _callback_depth => integer 1 protected _callback_params => array(0) }}992 throw new Request_Exception('Unable to execute :uri without a Kohana_Request_Client', array( 993 ':uri' => $this->_uri, 994 )); 995 } 996 997 return $this->_client->execute($this); 998 } 999 1000 /** 1001 * Returns whether this request is the initial request Kohana received. 1002 * Can be used to test for sub requests. -
DOCROOT/index.php [ 119 ] » Kohana_Request->execute()
114 /** 115 * Execute the main request. A source of the URI can be passed, eg: $_SERVER['PATH_INFO']. 116 * If no source is specified, the URI will be automatically detected. 117 */ 118 echo Request::factory(TRUE, array(), FALSE) 119 ->execute() 120 ->send_headers(TRUE) 121 ->body(); 122 }