MODPATH/database/classes/Kohana/Database/MySQL.php [ 67 ]
62 catch (Exception $e)
63 {
64 // No connection exists
65 $this->_connection = NULL;
66
67 throw new Database_Exception(':error',
68 array(':error' => $e->getMessage()),
69 $e->getCode());
70 }
71
72 // \xFF is a better delimiter, but the PHP driver uses underscore
-
MODPATH/database/classes/Kohana/Database/MySQL.php [ 430 ] » Kohana_Database_MySQL->connect()
425 } 426 427 public function escape($value) 428 { 429 // Make sure the database is connected 430 $this->_connection or $this->connect(); 431 432 if (($value = mysql_real_escape_string( (string) $value, $this->_connection)) === FALSE) 433 { 434 throw new Database_Exception(':error', 435 array(':error' => mysql_error($this->_connection)),
-
MODPATH/database/classes/Kohana/Database.php [ 478 ] » Kohana_Database_MySQL->escape(arguments)
0
string(9) "site_name"
473 { 474 // Convert to non-locale aware float to prevent possible commas 475 return sprintf('%F', $value); 476 } 477 478 return $this->escape($value); 479 } 480 481 /** 482 * Quote a database column name and add the table prefix if needed. 483 *
-
MODPATH/database/classes/Kohana/Database/Query/Builder.php [ 116 ] » Kohana_Database->quote(arguments)
0
string(9) "site_name"
111 $value = $min.' AND '.$max; 112 } 113 elseif ((is_string($value) AND array_key_exists($value, $this->_parameters)) === FALSE) 114 { 115 // Quote the value, it is not a parameter 116 $value = $db->quote($value); 117 } 118 119 if ($column) 120 { 121 if (is_array($column))
-
MODPATH/database/classes/Kohana/Database/Query/Builder/Select.php [ 372 ] » Kohana_Database_Query_Builder->_compile_conditions(arguments)
0
object Database_MySQL(6)
{ protected _connection_id => NULL protected _identifier => string(1) "`" public last_query => NULL protected _instance => string(7) "default" protected _connection => NULL protected _config => array(6) ( "type" => string(5) "MySQL" "connection" => array(3) ( "hostname" => string(9) "localhost" "database" => string(13) "jolie74ru_koh" "persistent" => bool FALSE ) "table_prefix" => string(4) "hay_" "charset" => string(4) "utf8" "caching" => bool FALSE "profiling" => bool TRUE ) }
1
array(1) ( 0 => array(1) ( "AND" => array(3) ( 0 => string(3) "key" 1 => string(1) "=" 2 => string(9) "site_name" ) ) )
367 } 368 369 if ( ! empty($this->_where)) 370 { 371 // Add selection conditions 372 $query .= ' WHERE '.$this->_compile_conditions($db, $this->_where); 373 } 374 375 if ( ! empty($this->_group_by)) 376 { 377 // Add grouping
-
MODPATH/database/classes/Kohana/Database/Query.php [ 234 ] » Kohana_Database_Query_Builder_Select->compile(arguments)
0
object Database_MySQL(6)
{ protected _connection_id => NULL protected _identifier => string(1) "`" public last_query => NULL protected _instance => string(7) "default" protected _connection => NULL protected _config => array(6) ( "type" => string(5) "MySQL" "connection" => array(3) ( "hostname" => string(9) "localhost" "database" => string(13) "jolie74ru_koh" "persistent" => bool FALSE ) "table_prefix" => string(4) "hay_" "charset" => string(4) "utf8" "caching" => bool FALSE "profiling" => bool TRUE ) }
229 { 230 $object_params = $this->_object_params; 231 } 232 233 // Compile the SQL query 234 $sql = $this->compile($db); 235 236 if ($this->_lifetime !== NULL AND $this->_type === Database::SELECT) 237 { 238 // Set the cache key based on the database instance name and SQL 239 $cache_key = 'Database::query("'.$db.'", "'.$sql.'")';
-
MODPATH/orm/classes/Kohana/ORM.php [ 1069 ] » Kohana_Database_Query->execute(arguments)
0
object Database_MySQL(6)
{ protected _connection_id => NULL protected _identifier => string(1) "`" public last_query => NULL protected _instance => string(7) "default" protected _connection => NULL protected _config => array(6) ( "type" => string(5) "MySQL" "connection" => array(3) ( "hostname" => string(9) "localhost" "database" => string(13) "jolie74ru_koh" "persistent" => bool FALSE ) "table_prefix" => string(4) "hay_" "charset" => string(4) "utf8" "caching" => bool FALSE "profiling" => bool TRUE ) }
1064 return $result; 1065 } 1066 else 1067 { 1068 // Load the result as an associative array 1069 $result = $this->_db_builder->as_assoc()->execute($this->_db); 1070 1071 $this->reset(); 1072 1073 if ($result->count() === 1) 1074 {
-
MODPATH/orm/classes/Kohana/ORM.php [ 976 ] » Kohana_ORM->_load_result(arguments)
0
bool FALSE
971 } 972 } 973 974 $this->_build(Database::SELECT); 975 976 return $this->_load_result(FALSE); 977 } 978 979 /** 980 * Finds multiple database rows and returns an iterator of the rows found. 981 *
-
APPPATH/classes/Controller/Base.php [ 38 ] » Kohana_ORM->find()
33 $this->session = Session::instance(); 34 35 // Вывод в шаблон 36 $site_name = ORM::factory('Setting') 37 ->where('key', '=', 'site_name') 38 ->find(); 39 if ($site_name->loaded() && !empty($site_name->value)) 40 { 41 $this->site_name = $site_name->value; 42 } 43 else
-
APPPATH/classes/Controller/Index.php [ 37 ] » Controller_Base->before()
32 /*Вывод сообщения перед формой коментария*/ 33 public $msg_comments = NULL; 34 35 public function before() 36 { 37 parent::before(); 38 // returns $_GET['foo'] or NULL if not exists 39 $this->filters = $this->request->query(); 40 41 $this->auto_render = TRUE; 42 //Если выполняем ajax запрос, то отключаем генерацию мета данных
-
APPPATH/classes/Controller/Index/Catalog.php [ 17 ] » Controller_Index->before()
12 protected $vendor; 13 14 15 public function before() 16 { 17 parent::before(); 18 19 $this->template->select = $this->select; 20 } 21 22 public function after()
-
SYSPATH/classes/Kohana/Controller.php [ 69 ] » Controller_Index_Catalog->before()
64 * @return Response 65 */ 66 public function execute() 67 { 68 // Execute the "before action" method 69 $this->before(); 70 71 // Determine the action to use 72 $action = 'action_'.$this->request->action(); 73 74 // If the action doesn't exist, it's a 404
-
{PHP internal call} » Kohana_Controller->execute()
-
SYSPATH/classes/Kohana/Request/Client/Internal.php [ 97 ] » ReflectionMethod->invoke(arguments)
0
object Controller_Index_Catalog(39)
{ protected select => string(0) "" protected alias_product => NULL protected alias_catalog => NULL protected alias_vendor => NULL protected vendor => NULL public template => object View(2)
{ protected _file => string(69) "/home/j/jolie74ru/jolie74ru/kohana/application/views/index/v_base.php" protected _data => array(0) }
public ajaxAllow => bool FALSE public scripts => array(0) public styles => array(0) public errors => array(0) public filters => array(0) public breadcrumb => array(0) public content => NULL public content_bottom => NULL public style_text_end => array(0) public benchmark => NULL public data_comment => NULL public products_popup => NULL public image_src => NULL public razdelit_title => NULL public captcha => NULL public block_main_menu => array(0) public block_center => array(0) public msg_comments => NULL protected user => NULL protected auth => object Auth_ORM(2){ protected _session => object Session_Cookie(5)
protected cache => object Cache_File(2){ protected _name => string(7) "session" protected _lifetime => integer 43200 protected _encrypted => string(7) "default" protected _data => array(0) protected _destroyed => bool FALSE }
protected _config => object Config_Group(7){ public driver => string(3) "ORM" public hash_method => string(6) "sha256" public hash_key => string(16) "asjdhas6f2e12kas" public lifetime => integer 1209600 public session_type => string(6) "cookie" public session_key => string(9) "auth_user" public users => array(0) }
}{ protected _cache_dir => object SplFileInfo(0)
protected session => object Session_Cookie(5){ }
protected _config => array(3) ( "driver" => string(4) "file" "cache_dir" => string(52) "/home/j/jolie74ru/jolie74ru/kohana/application/cache" "default_expire" => integer 3600 ) }{ protected _name => string(7) "session" protected _lifetime => integer 43200 protected _encrypted => string(7) "default" protected _data => array(0) protected _destroyed => bool FALSE }
public site_name => NULL public title => NULL public meta_keywords => NULL public meta_description => string(0) "" protected total_items => NULL protected otzyv_in_product => NULL protected pagination => NULL public email_connection => NULL public auto_render => bool TRUE public request => object Request(19){ protected _requested_with => NULL protected _method => string(3) "GET" protected _protocol => string(8) "HTTP/1.1" protected _secure => bool FALSE protected _referrer => NULL protected _route => object Route(5)
public response => object Response(5){ protected _filters => array(0) protected _uri => string(71) "<controller>(/<catalog_alias>((/ven_<vendor_alias>)(/<product_alias>)))" protected _regex => array(1) ( "controller" => string(15) "Catalog|catalog" ) protected _defaults => array(3) ( "directory" => string(5) "Index" "controller" => string(7) "Catalog" "action" => string(5) "index" ) protected _route_regex => string(156) "#^(?P<controller>Catalog|catalog)(?:/(?P<catalog_alias>[^/.,;?\n]++)(?:(?:/ven_(?P<vendor_alias>[^/.,;?\n]++))?(?:/(?P<product_a …" }
protected _routes => array(0) protected _header => object HTTP_Header(0){ }
protected _body => NULL protected _directory => string(5) "Index" protected _controller => string(7) "Catalog" protected _action => string(5) "index" protected _uri => string(29) "catalog/women/versace-vanitas" protected _external => bool FALSE protected _params => array(3) ( "catalog_alias" => string(5) "women" "vendor_alias" => string(0) "" "product_alias" => string(15) "versace-vanitas" ) 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(1)
}{ public x-powered-by => string(6) "PATERM" }
protected _body => string(0) "" protected _cookies => array(0) protected _protocol => NULL }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)
0
object Request(19)
{ protected _requested_with => NULL protected _method => string(3) "GET" protected _protocol => string(8) "HTTP/1.1" protected _secure => bool FALSE protected _referrer => NULL protected _route => object Route(5)
{ protected _filters => array(0) protected _uri => string(71) "<controller>(/<catalog_alias>((/ven_<vendor_alias>)(/<product_alias>)))" protected _regex => array(1) ( "controller" => string(15) "Catalog|catalog" ) protected _defaults => array(3) ( "directory" => string(5) "Index" "controller" => string(7) "Catalog" "action" => string(5) "index" ) protected _route_regex => string(156) "#^(?P<controller>Catalog|catalog)(?:/(?P<catalog_alias>[^/.,;?\n]++)(?:(?:/ven_(?P<vendor_alias>[^/.,;?\n]++))?(?:/(?P<product_a …" }
protected _routes => array(0) protected _header => object HTTP_Header(0){ }
protected _body => NULL protected _directory => string(5) "Index" protected _controller => string(7) "Catalog" protected _action => string(5) "index" protected _uri => string(29) "catalog/women/versace-vanitas" protected _external => bool FALSE protected _params => array(3) ( "catalog_alias" => string(5) "women" "vendor_alias" => string(0) "" "product_alias" => string(15) "versace-vanitas" ) 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) }
}1
object Response(5)
{ protected _status => integer 200 protected _header => object HTTP_Header(1)
{ public x-powered-by => string(6) "PATERM" }
protected _body => string(0) "" protected _cookies => array(0) protected _protocol => NULL }109 $orig_response = $response = Response::factory(); 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 [ 990 ] » Kohana_Request_Client->execute(arguments)
0
object Request(19)
{ protected _requested_with => NULL protected _method => string(3) "GET" protected _protocol => string(8) "HTTP/1.1" protected _secure => bool FALSE protected _referrer => NULL protected _route => object Route(5)
{ protected _filters => array(0) protected _uri => string(71) "<controller>(/<catalog_alias>((/ven_<vendor_alias>)(/<product_alias>)))" protected _regex => array(1) ( "controller" => string(15) "Catalog|catalog" ) protected _defaults => array(3) ( "directory" => string(5) "Index" "controller" => string(7) "Catalog" "action" => string(5) "index" ) protected _route_regex => string(156) "#^(?P<controller>Catalog|catalog)(?:/(?P<catalog_alias>[^/.,;?\n]++)(?:(?:/ven_(?P<vendor_alias>[^/.,;?\n]++))?(?:/(?P<product_a …" }
protected _routes => array(0) protected _header => object HTTP_Header(0){ }
protected _body => NULL protected _directory => string(5) "Index" protected _controller => string(7) "Catalog" protected _action => string(5) "index" protected _uri => string(29) "catalog/women/versace-vanitas" protected _external => bool FALSE protected _params => array(3) ( "catalog_alias" => string(5) "women" "vendor_alias" => string(0) "" "product_alias" => string(15) "versace-vanitas" ) 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) }
}985 throw new Request_Exception('Unable to execute :uri without a Kohana_Request_Client', array( 986 ':uri' => $this->_uri, 987 )); 988 } 989 990 return $this->_client->execute($this); 991 } 992 993 /** 994 * Returns whether this request is the initial request Kohana received. 995 * Can be used to test for sub requests.
-
DOCROOT/index.php [ 123 ] » Kohana_Request->execute()
118 /** 119 * Execute the main request. A source of the URI can be passed, eg: $_SERVER['PATH_INFO']. 120 * If no source is specified, the URI will be automatically detected. 121 */ 122 echo Request::factory(TRUE, array(), FALSE) 123 ->execute() 124 ->send_headers(TRUE) 125 ->body(); 126 }