Notice (8): Undefined variable: data [APP/View/Layouts/default.ctp, line 9]Code Context//---
//pr($data);
$pn_menu = mtouch_d($data, "punkt_menu", "");
$viewFile = '/usr/home/www/pollut/nos/cpnos/app/View/Layouts/default.ctp' $dataForView = array( 'class' => 'Postgres', 'message' => 'SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?', 'enabled' => true, 'code' => (int) 500, 'name' => 'Database connection "Postgres" is missing, or could not be created.', 'url' => '/nos/cpnos/main', 'error' => object(MissingConnectionException) { }, '_serialize' => array( (int) 0 => 'code', (int) 1 => 'name', (int) 2 => 'message', (int) 3 => 'url' ), 'content_for_layout' => '<h2>Missing Database Connection</h2> <p class="error"> <strong>Error: </strong> A Database connection using "Postgres" was missing or unable to connect. <br /> The database server returned this error: SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?</p> <p class="notice"> <strong>Notice: </strong> If you want to customize this error message, create app/View/Errors/missing_connection.ctp</p> <h3>Stack Trace</h3> <ul class="cake-stack-trace"> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-0')">CORE/Cake/Model/Datasource/DboSource.php line 260</a> → <a href="#" onclick="traceToggle(event, 'trace-args-0')">Postgres->connect()</a> <div id="file-excerpt-0" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$autoConnect</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">connect</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-0" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-1')">CORE/Cake/Model/ConnectionManager.php line 105</a> → <a href="#" onclick="traceToggle(event, 'trace-args-1')">DboSource->__construct(array)</a> <div id="file-excerpt-1" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'message' </span><span style="color: #007700">=> </span><span style="color: #DD0000">'Datasource is not found in Model/Datasource package.'</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">] = new </span><span style="color: #0000BB">$class</span><span style="color: #007700">(</span><span style="color: #0000BB">self</span><span style="color: #007700">::</span><span style="color: #0000BB">$config</span><span style="color: #007700">->{</span><span style="color: #0000BB">$name</span><span style="color: #007700">});</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">]-></span><span style="color: #0000BB">configKeyName </span><span style="color: #007700">= </span><span style="color: #0000BB">$name</span><span style="color: #007700">;</span></span></code></pre></div> <div id="trace-args-1" class="cake-code-dump" style="display: none;"><pre>array( 'password' => '*****', 'login' => '*****', 'host' => '*****', 'database' => '*****', 'port' => '*****', 'prefix' => '*****', 'schema' => '*****', 'datasource' => 'Database/Postgres', 'persistent' => false, 'encoding' => 'utf8' )</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-2')">CORE/Cake/Model/Model.php line 3617</a> → <a href="#" onclick="traceToggle(event, 'trace-args-2')">ConnectionManager::getDataSource(string)</a> <div id="file-excerpt-2" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig </span><span style="color: #007700">= </span><span style="color: #0000BB">$dataSource</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!empty(</span><span style="color: #0000BB">$oldConfig</span><span style="color: #007700">) && isset(</span><span style="color: #0000BB">$db</span><span style="color: #007700">-></span><span style="color: #0000BB">config</span><span style="color: #007700">[</span><span style="color: #DD0000">'prefix'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-2" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-3')">CORE/Cake/Model/Model.php line 1155</a> → <a href="#" onclick="traceToggle(event, 'trace-args-3')">Model->setDataSource(string)</a> <div id="file-excerpt-3" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">* @return </span><span style="color: #0000BB">void</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$tableName</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-3" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-4')">CORE/Cake/Model/Model.php line 3644</a> → <a href="#" onclick="traceToggle(event, 'trace-args-4')">Model->setSource(string)</a> <div id="file-excerpt-4" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">() {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">&& </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable </span><span style="color: #007700">!== </span><span style="color: #0000BB">false</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-4" class="cake-code-dump" style="display: none;"><pre>'nos_data'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-5')">CORE/Cake/Model/Model.php line 3446</a> → <a href="#" onclick="traceToggle(event, 'trace-args-5')">Model->getDataSource()</a> <div id="file-excerpt-5" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $params </span><span style="color: #007700">= </span><span style="color: #0000BB">func_get_args</span><span style="color: #007700">();</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">call_user_func_array</span><span style="color: #007700">(array(&</span><span style="color: #0000BB">$db</span><span style="color: #007700">, </span><span style="color: #DD0000">'query'</span><span style="color: #007700">), </span><span style="color: #0000BB">$params</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-5" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-6')">APP/Controller/MainController.php line 23</a> → <a href="#" onclick="traceToggle(event, 'trace-args-6')">Model->query(string)</a> <div id="file-excerpt-6" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #FF8000">//---</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">loadModel</span><span style="color: #007700">(</span><span style="color: #DD0000">'Nos_data'</span><span style="color: #007700">);</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $sql </span><span style="color: #007700">= </span><span style="color: #DD0000">"select count(id) as k_ from nos_data"</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $res </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">Nos_data</span><span style="color: #007700">-></span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $n_data </span><span style="color: #007700">= </span><span style="color: #0000BB">$res</span><span style="color: #007700">[</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #DD0000">'k_'</span><span style="color: #007700">];</span></span></code></pre></div> <div id="trace-args-6" class="cake-code-dump" style="display: none;"><pre>'select count(id) as k_ from nos_data'</pre></div></li> <li><a href="#">[internal function]</a> → <a href="#" onclick="traceToggle(event, 'trace-args-7')">MainController->index()</a> <div id="trace-args-7" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-8')">CORE/Cake/Controller/Controller.php line 490</a> → <a href="#" onclick="traceToggle(event, 'trace-args-8')">ReflectionMethod->invokeArgs(MainController, array)</a> <div id="file-excerpt-8" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'action' </span><span style="color: #007700">=> </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'action'</span><span style="color: #007700">]</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">$method</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeArgs</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'pass'</span><span style="color: #007700">]);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-8" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } array()</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-9')">CORE/Cake/Routing/Dispatcher.php line 193</a> → <a href="#" onclick="traceToggle(event, 'trace-args-9')">Controller->invokeAction(CakeRequest)</a> <div id="file-excerpt-9" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">response</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $render </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $result </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeAction</span><span style="color: #007700">(</span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$result </span><span style="color: #007700">instanceof </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">) {</span></span></code></pre></div> <div id="trace-args-9" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-10')">CORE/Cake/Routing/Dispatcher.php line 167</a> → <a href="#" onclick="traceToggle(event, 'trace-args-10')">Dispatcher->_invoke(MainController, CakeRequest)</a> <div id="file-excerpt-10" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_invoke</span><span style="color: #007700">(</span><span style="color: #0000BB">$controller</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (isset(</span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'return'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-10" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-11')">APP/webroot/index.php line 118</a> → <a href="#" onclick="traceToggle(event, 'trace-args-11')">Dispatcher->dispatch(CakeRequest, CakeResponse)</a> <div id="file-excerpt-11" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB">$Dispatcher</span><span style="color: #007700">-></span><span style="color: #0000BB">dispatch</span><span style="color: #007700">(</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeRequest</span><span style="color: #007700">(),</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">()</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"></span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-11" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } object(CakeResponse) { }</pre></div></li> </ul> <script type="text/javascript"> function traceToggle(event, id) { var el = document.getElementById(id); el.style.display = (el.style.display === 'block') ? 'none' : 'block'; event.preventDefault(); return false; } </script> ', 'scripts_for_layout' => '', 'title_for_layout' => 'Errors' ) $class = 'Postgres' $message = 'SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?' $enabled = true $code = (int) 500 $name = 'Database connection "Postgres" is missing, or could not be created.' $url = '/nos/cpnos/main' $error = object(MissingConnectionException) { } $_serialize = array( (int) 0 => 'code', (int) 1 => 'name', (int) 2 => 'message', (int) 3 => 'url' ) $content_for_layout = '<h2>Missing Database Connection</h2> <p class="error"> <strong>Error: </strong> A Database connection using "Postgres" was missing or unable to connect. <br /> The database server returned this error: SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?</p> <p class="notice"> <strong>Notice: </strong> If you want to customize this error message, create app/View/Errors/missing_connection.ctp</p> <h3>Stack Trace</h3> <ul class="cake-stack-trace"> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-0')">CORE/Cake/Model/Datasource/DboSource.php line 260</a> → <a href="#" onclick="traceToggle(event, 'trace-args-0')">Postgres->connect()</a> <div id="file-excerpt-0" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$autoConnect</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">connect</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-0" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-1')">CORE/Cake/Model/ConnectionManager.php line 105</a> → <a href="#" onclick="traceToggle(event, 'trace-args-1')">DboSource->__construct(array)</a> <div id="file-excerpt-1" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'message' </span><span style="color: #007700">=> </span><span style="color: #DD0000">'Datasource is not found in Model/Datasource package.'</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">] = new </span><span style="color: #0000BB">$class</span><span style="color: #007700">(</span><span style="color: #0000BB">self</span><span style="color: #007700">::</span><span style="color: #0000BB">$config</span><span style="color: #007700">->{</span><span style="color: #0000BB">$name</span><span style="color: #007700">});</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">]-></span><span style="color: #0000BB">configKeyName </span><span style="color: #007700">= </span><span style="color: #0000BB">$name</span><span style="color: #007700">;</span></span></code></pre></div> <div id="trace-args-1" class="cake-code-dump" style="display: none;"><pre>array( 'password' => '*****', 'login' => '*****', 'host' => '*****', 'database' => '*****', 'port' => '*****', 'prefix' => '*****', 'schema' => '*****', 'datasource' => 'Database/Postgres', 'persistent' => false, 'encoding' => 'utf8' )</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-2')">CORE/Cake/Model/Model.php line 3617</a> → <a href="#" onclick="traceToggle(event, 'trace-args-2')">ConnectionManager::getDataSource(string)</a> <div id="file-excerpt-2" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig </span><span style="color: #007700">= </span><span style="color: #0000BB">$dataSource</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!empty(</span><span style="color: #0000BB">$oldConfig</span><span style="color: #007700">) && isset(</span><span style="color: #0000BB">$db</span><span style="color: #007700">-></span><span style="color: #0000BB">config</span><span style="color: #007700">[</span><span style="color: #DD0000">'prefix'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-2" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-3')">CORE/Cake/Model/Model.php line 1155</a> → <a href="#" onclick="traceToggle(event, 'trace-args-3')">Model->setDataSource(string)</a> <div id="file-excerpt-3" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">* @return </span><span style="color: #0000BB">void</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$tableName</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-3" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-4')">CORE/Cake/Model/Model.php line 3644</a> → <a href="#" onclick="traceToggle(event, 'trace-args-4')">Model->setSource(string)</a> <div id="file-excerpt-4" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">() {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">&& </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable </span><span style="color: #007700">!== </span><span style="color: #0000BB">false</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-4" class="cake-code-dump" style="display: none;"><pre>'nos_data'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-5')">CORE/Cake/Model/Model.php line 3446</a> → <a href="#" onclick="traceToggle(event, 'trace-args-5')">Model->getDataSource()</a> <div id="file-excerpt-5" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $params </span><span style="color: #007700">= </span><span style="color: #0000BB">func_get_args</span><span style="color: #007700">();</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">call_user_func_array</span><span style="color: #007700">(array(&</span><span style="color: #0000BB">$db</span><span style="color: #007700">, </span><span style="color: #DD0000">'query'</span><span style="color: #007700">), </span><span style="color: #0000BB">$params</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-5" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-6')">APP/Controller/MainController.php line 23</a> → <a href="#" onclick="traceToggle(event, 'trace-args-6')">Model->query(string)</a> <div id="file-excerpt-6" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #FF8000">//---</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">loadModel</span><span style="color: #007700">(</span><span style="color: #DD0000">'Nos_data'</span><span style="color: #007700">);</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $sql </span><span style="color: #007700">= </span><span style="color: #DD0000">"select count(id) as k_ from nos_data"</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $res </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">Nos_data</span><span style="color: #007700">-></span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $n_data </span><span style="color: #007700">= </span><span style="color: #0000BB">$res</span><span style="color: #007700">[</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #DD0000">'k_'</span><span style="color: #007700">];</span></span></code></pre></div> <div id="trace-args-6" class="cake-code-dump" style="display: none;"><pre>'select count(id) as k_ from nos_data'</pre></div></li> <li><a href="#">[internal function]</a> → <a href="#" onclick="traceToggle(event, 'trace-args-7')">MainController->index()</a> <div id="trace-args-7" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-8')">CORE/Cake/Controller/Controller.php line 490</a> → <a href="#" onclick="traceToggle(event, 'trace-args-8')">ReflectionMethod->invokeArgs(MainController, array)</a> <div id="file-excerpt-8" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'action' </span><span style="color: #007700">=> </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'action'</span><span style="color: #007700">]</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">$method</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeArgs</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'pass'</span><span style="color: #007700">]);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-8" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } array()</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-9')">CORE/Cake/Routing/Dispatcher.php line 193</a> → <a href="#" onclick="traceToggle(event, 'trace-args-9')">Controller->invokeAction(CakeRequest)</a> <div id="file-excerpt-9" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">response</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $render </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $result </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeAction</span><span style="color: #007700">(</span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$result </span><span style="color: #007700">instanceof </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">) {</span></span></code></pre></div> <div id="trace-args-9" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-10')">CORE/Cake/Routing/Dispatcher.php line 167</a> → <a href="#" onclick="traceToggle(event, 'trace-args-10')">Dispatcher->_invoke(MainController, CakeRequest)</a> <div id="file-excerpt-10" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_invoke</span><span style="color: #007700">(</span><span style="color: #0000BB">$controller</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (isset(</span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'return'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-10" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-11')">APP/webroot/index.php line 118</a> → <a href="#" onclick="traceToggle(event, 'trace-args-11')">Dispatcher->dispatch(CakeRequest, CakeResponse)</a> <div id="file-excerpt-11" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB">$Dispatcher</span><span style="color: #007700">-></span><span style="color: #0000BB">dispatch</span><span style="color: #007700">(</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeRequest</span><span style="color: #007700">(),</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">()</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"></span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-11" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } object(CakeResponse) { }</pre></div></li> </ul> <script type="text/javascript"> function traceToggle(event, id) { var el = document.getElementById(id); el.style.display = (el.style.display === 'block') ? 'none' : 'block'; event.preventDefault(); return false; } </script> ' $scripts_for_layout = '' $title_for_layout = 'Errors' $bs = '/nos/cpnos'include - APP/View/Layouts/default.ctp, line 9 View::_evaluate() - CORE/Cake/View/View.php, line 961 View::_render() - CORE/Cake/View/View.php, line 923 View::renderLayout() - CORE/Cake/View/View.php, line 546 View::render() - CORE/Cake/View/View.php, line 481 Controller::render() - CORE/Cake/Controller/Controller.php, line 960 ExceptionRenderer::_outputMessage() - CORE/Cake/Error/ExceptionRenderer.php, line 289 ExceptionRenderer::_cakeError() - CORE/Cake/Error/ExceptionRenderer.php, line 210 ExceptionRenderer::render() - CORE/Cake/Error/ExceptionRenderer.php, line 187 ErrorHandler::handleException() - CORE/Cake/Error/ErrorHandler.php, line 127 [main] - [internal], line ??
Notice (8): Undefined variable: data [APP/View/Layouts/default.ctp, line 10]Code Context//pr($data);
$pn_menu = mtouch_d($data, "punkt_menu", "");
$tek_menu = mtouch_d($data, "side_menu", "");
$viewFile = '/usr/home/www/pollut/nos/cpnos/app/View/Layouts/default.ctp' $dataForView = array( 'class' => 'Postgres', 'message' => 'SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?', 'enabled' => true, 'code' => (int) 500, 'name' => 'Database connection "Postgres" is missing, or could not be created.', 'url' => '/nos/cpnos/main', 'error' => object(MissingConnectionException) { }, '_serialize' => array( (int) 0 => 'code', (int) 1 => 'name', (int) 2 => 'message', (int) 3 => 'url' ), 'content_for_layout' => '<h2>Missing Database Connection</h2> <p class="error"> <strong>Error: </strong> A Database connection using "Postgres" was missing or unable to connect. <br /> The database server returned this error: SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?</p> <p class="notice"> <strong>Notice: </strong> If you want to customize this error message, create app/View/Errors/missing_connection.ctp</p> <h3>Stack Trace</h3> <ul class="cake-stack-trace"> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-0')">CORE/Cake/Model/Datasource/DboSource.php line 260</a> → <a href="#" onclick="traceToggle(event, 'trace-args-0')">Postgres->connect()</a> <div id="file-excerpt-0" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$autoConnect</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">connect</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-0" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-1')">CORE/Cake/Model/ConnectionManager.php line 105</a> → <a href="#" onclick="traceToggle(event, 'trace-args-1')">DboSource->__construct(array)</a> <div id="file-excerpt-1" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'message' </span><span style="color: #007700">=> </span><span style="color: #DD0000">'Datasource is not found in Model/Datasource package.'</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">] = new </span><span style="color: #0000BB">$class</span><span style="color: #007700">(</span><span style="color: #0000BB">self</span><span style="color: #007700">::</span><span style="color: #0000BB">$config</span><span style="color: #007700">->{</span><span style="color: #0000BB">$name</span><span style="color: #007700">});</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">]-></span><span style="color: #0000BB">configKeyName </span><span style="color: #007700">= </span><span style="color: #0000BB">$name</span><span style="color: #007700">;</span></span></code></pre></div> <div id="trace-args-1" class="cake-code-dump" style="display: none;"><pre>array( 'password' => '*****', 'login' => '*****', 'host' => '*****', 'database' => '*****', 'port' => '*****', 'prefix' => '*****', 'schema' => '*****', 'datasource' => 'Database/Postgres', 'persistent' => false, 'encoding' => 'utf8' )</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-2')">CORE/Cake/Model/Model.php line 3617</a> → <a href="#" onclick="traceToggle(event, 'trace-args-2')">ConnectionManager::getDataSource(string)</a> <div id="file-excerpt-2" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig </span><span style="color: #007700">= </span><span style="color: #0000BB">$dataSource</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!empty(</span><span style="color: #0000BB">$oldConfig</span><span style="color: #007700">) && isset(</span><span style="color: #0000BB">$db</span><span style="color: #007700">-></span><span style="color: #0000BB">config</span><span style="color: #007700">[</span><span style="color: #DD0000">'prefix'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-2" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-3')">CORE/Cake/Model/Model.php line 1155</a> → <a href="#" onclick="traceToggle(event, 'trace-args-3')">Model->setDataSource(string)</a> <div id="file-excerpt-3" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">* @return </span><span style="color: #0000BB">void</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$tableName</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-3" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-4')">CORE/Cake/Model/Model.php line 3644</a> → <a href="#" onclick="traceToggle(event, 'trace-args-4')">Model->setSource(string)</a> <div id="file-excerpt-4" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">() {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">&& </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable </span><span style="color: #007700">!== </span><span style="color: #0000BB">false</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-4" class="cake-code-dump" style="display: none;"><pre>'nos_data'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-5')">CORE/Cake/Model/Model.php line 3446</a> → <a href="#" onclick="traceToggle(event, 'trace-args-5')">Model->getDataSource()</a> <div id="file-excerpt-5" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $params </span><span style="color: #007700">= </span><span style="color: #0000BB">func_get_args</span><span style="color: #007700">();</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">call_user_func_array</span><span style="color: #007700">(array(&</span><span style="color: #0000BB">$db</span><span style="color: #007700">, </span><span style="color: #DD0000">'query'</span><span style="color: #007700">), </span><span style="color: #0000BB">$params</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-5" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-6')">APP/Controller/MainController.php line 23</a> → <a href="#" onclick="traceToggle(event, 'trace-args-6')">Model->query(string)</a> <div id="file-excerpt-6" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #FF8000">//---</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">loadModel</span><span style="color: #007700">(</span><span style="color: #DD0000">'Nos_data'</span><span style="color: #007700">);</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $sql </span><span style="color: #007700">= </span><span style="color: #DD0000">"select count(id) as k_ from nos_data"</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $res </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">Nos_data</span><span style="color: #007700">-></span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $n_data </span><span style="color: #007700">= </span><span style="color: #0000BB">$res</span><span style="color: #007700">[</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #DD0000">'k_'</span><span style="color: #007700">];</span></span></code></pre></div> <div id="trace-args-6" class="cake-code-dump" style="display: none;"><pre>'select count(id) as k_ from nos_data'</pre></div></li> <li><a href="#">[internal function]</a> → <a href="#" onclick="traceToggle(event, 'trace-args-7')">MainController->index()</a> <div id="trace-args-7" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-8')">CORE/Cake/Controller/Controller.php line 490</a> → <a href="#" onclick="traceToggle(event, 'trace-args-8')">ReflectionMethod->invokeArgs(MainController, array)</a> <div id="file-excerpt-8" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'action' </span><span style="color: #007700">=> </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'action'</span><span style="color: #007700">]</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">$method</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeArgs</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'pass'</span><span style="color: #007700">]);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-8" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } array()</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-9')">CORE/Cake/Routing/Dispatcher.php line 193</a> → <a href="#" onclick="traceToggle(event, 'trace-args-9')">Controller->invokeAction(CakeRequest)</a> <div id="file-excerpt-9" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">response</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $render </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $result </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeAction</span><span style="color: #007700">(</span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$result </span><span style="color: #007700">instanceof </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">) {</span></span></code></pre></div> <div id="trace-args-9" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-10')">CORE/Cake/Routing/Dispatcher.php line 167</a> → <a href="#" onclick="traceToggle(event, 'trace-args-10')">Dispatcher->_invoke(MainController, CakeRequest)</a> <div id="file-excerpt-10" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_invoke</span><span style="color: #007700">(</span><span style="color: #0000BB">$controller</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (isset(</span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'return'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-10" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-11')">APP/webroot/index.php line 118</a> → <a href="#" onclick="traceToggle(event, 'trace-args-11')">Dispatcher->dispatch(CakeRequest, CakeResponse)</a> <div id="file-excerpt-11" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB">$Dispatcher</span><span style="color: #007700">-></span><span style="color: #0000BB">dispatch</span><span style="color: #007700">(</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeRequest</span><span style="color: #007700">(),</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">()</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"></span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-11" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } object(CakeResponse) { }</pre></div></li> </ul> <script type="text/javascript"> function traceToggle(event, id) { var el = document.getElementById(id); el.style.display = (el.style.display === 'block') ? 'none' : 'block'; event.preventDefault(); return false; } </script> ', 'scripts_for_layout' => '', 'title_for_layout' => 'Errors' ) $class = 'Postgres' $message = 'SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?' $enabled = true $code = (int) 500 $name = 'Database connection "Postgres" is missing, or could not be created.' $url = '/nos/cpnos/main' $error = object(MissingConnectionException) { } $_serialize = array( (int) 0 => 'code', (int) 1 => 'name', (int) 2 => 'message', (int) 3 => 'url' ) $content_for_layout = '<h2>Missing Database Connection</h2> <p class="error"> <strong>Error: </strong> A Database connection using "Postgres" was missing or unable to connect. <br /> The database server returned this error: SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?</p> <p class="notice"> <strong>Notice: </strong> If you want to customize this error message, create app/View/Errors/missing_connection.ctp</p> <h3>Stack Trace</h3> <ul class="cake-stack-trace"> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-0')">CORE/Cake/Model/Datasource/DboSource.php line 260</a> → <a href="#" onclick="traceToggle(event, 'trace-args-0')">Postgres->connect()</a> <div id="file-excerpt-0" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$autoConnect</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">connect</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-0" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-1')">CORE/Cake/Model/ConnectionManager.php line 105</a> → <a href="#" onclick="traceToggle(event, 'trace-args-1')">DboSource->__construct(array)</a> <div id="file-excerpt-1" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'message' </span><span style="color: #007700">=> </span><span style="color: #DD0000">'Datasource is not found in Model/Datasource package.'</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">] = new </span><span style="color: #0000BB">$class</span><span style="color: #007700">(</span><span style="color: #0000BB">self</span><span style="color: #007700">::</span><span style="color: #0000BB">$config</span><span style="color: #007700">->{</span><span style="color: #0000BB">$name</span><span style="color: #007700">});</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">]-></span><span style="color: #0000BB">configKeyName </span><span style="color: #007700">= </span><span style="color: #0000BB">$name</span><span style="color: #007700">;</span></span></code></pre></div> <div id="trace-args-1" class="cake-code-dump" style="display: none;"><pre>array( 'password' => '*****', 'login' => '*****', 'host' => '*****', 'database' => '*****', 'port' => '*****', 'prefix' => '*****', 'schema' => '*****', 'datasource' => 'Database/Postgres', 'persistent' => false, 'encoding' => 'utf8' )</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-2')">CORE/Cake/Model/Model.php line 3617</a> → <a href="#" onclick="traceToggle(event, 'trace-args-2')">ConnectionManager::getDataSource(string)</a> <div id="file-excerpt-2" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig </span><span style="color: #007700">= </span><span style="color: #0000BB">$dataSource</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!empty(</span><span style="color: #0000BB">$oldConfig</span><span style="color: #007700">) && isset(</span><span style="color: #0000BB">$db</span><span style="color: #007700">-></span><span style="color: #0000BB">config</span><span style="color: #007700">[</span><span style="color: #DD0000">'prefix'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-2" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-3')">CORE/Cake/Model/Model.php line 1155</a> → <a href="#" onclick="traceToggle(event, 'trace-args-3')">Model->setDataSource(string)</a> <div id="file-excerpt-3" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">* @return </span><span style="color: #0000BB">void</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$tableName</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-3" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-4')">CORE/Cake/Model/Model.php line 3644</a> → <a href="#" onclick="traceToggle(event, 'trace-args-4')">Model->setSource(string)</a> <div id="file-excerpt-4" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">() {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">&& </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable </span><span style="color: #007700">!== </span><span style="color: #0000BB">false</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-4" class="cake-code-dump" style="display: none;"><pre>'nos_data'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-5')">CORE/Cake/Model/Model.php line 3446</a> → <a href="#" onclick="traceToggle(event, 'trace-args-5')">Model->getDataSource()</a> <div id="file-excerpt-5" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $params </span><span style="color: #007700">= </span><span style="color: #0000BB">func_get_args</span><span style="color: #007700">();</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">call_user_func_array</span><span style="color: #007700">(array(&</span><span style="color: #0000BB">$db</span><span style="color: #007700">, </span><span style="color: #DD0000">'query'</span><span style="color: #007700">), </span><span style="color: #0000BB">$params</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-5" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-6')">APP/Controller/MainController.php line 23</a> → <a href="#" onclick="traceToggle(event, 'trace-args-6')">Model->query(string)</a> <div id="file-excerpt-6" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #FF8000">//---</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">loadModel</span><span style="color: #007700">(</span><span style="color: #DD0000">'Nos_data'</span><span style="color: #007700">);</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $sql </span><span style="color: #007700">= </span><span style="color: #DD0000">"select count(id) as k_ from nos_data"</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $res </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">Nos_data</span><span style="color: #007700">-></span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $n_data </span><span style="color: #007700">= </span><span style="color: #0000BB">$res</span><span style="color: #007700">[</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #DD0000">'k_'</span><span style="color: #007700">];</span></span></code></pre></div> <div id="trace-args-6" class="cake-code-dump" style="display: none;"><pre>'select count(id) as k_ from nos_data'</pre></div></li> <li><a href="#">[internal function]</a> → <a href="#" onclick="traceToggle(event, 'trace-args-7')">MainController->index()</a> <div id="trace-args-7" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-8')">CORE/Cake/Controller/Controller.php line 490</a> → <a href="#" onclick="traceToggle(event, 'trace-args-8')">ReflectionMethod->invokeArgs(MainController, array)</a> <div id="file-excerpt-8" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'action' </span><span style="color: #007700">=> </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'action'</span><span style="color: #007700">]</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">$method</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeArgs</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'pass'</span><span style="color: #007700">]);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-8" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } array()</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-9')">CORE/Cake/Routing/Dispatcher.php line 193</a> → <a href="#" onclick="traceToggle(event, 'trace-args-9')">Controller->invokeAction(CakeRequest)</a> <div id="file-excerpt-9" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">response</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $render </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $result </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeAction</span><span style="color: #007700">(</span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$result </span><span style="color: #007700">instanceof </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">) {</span></span></code></pre></div> <div id="trace-args-9" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-10')">CORE/Cake/Routing/Dispatcher.php line 167</a> → <a href="#" onclick="traceToggle(event, 'trace-args-10')">Dispatcher->_invoke(MainController, CakeRequest)</a> <div id="file-excerpt-10" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_invoke</span><span style="color: #007700">(</span><span style="color: #0000BB">$controller</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (isset(</span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'return'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-10" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-11')">APP/webroot/index.php line 118</a> → <a href="#" onclick="traceToggle(event, 'trace-args-11')">Dispatcher->dispatch(CakeRequest, CakeResponse)</a> <div id="file-excerpt-11" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB">$Dispatcher</span><span style="color: #007700">-></span><span style="color: #0000BB">dispatch</span><span style="color: #007700">(</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeRequest</span><span style="color: #007700">(),</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">()</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"></span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-11" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } object(CakeResponse) { }</pre></div></li> </ul> <script type="text/javascript"> function traceToggle(event, id) { var el = document.getElementById(id); el.style.display = (el.style.display === 'block') ? 'none' : 'block'; event.preventDefault(); return false; } </script> ' $scripts_for_layout = '' $title_for_layout = 'Errors' $bs = '/nos/cpnos' $pn_menu = ''include - APP/View/Layouts/default.ctp, line 10 View::_evaluate() - CORE/Cake/View/View.php, line 961 View::_render() - CORE/Cake/View/View.php, line 923 View::renderLayout() - CORE/Cake/View/View.php, line 546 View::render() - CORE/Cake/View/View.php, line 481 Controller::render() - CORE/Cake/Controller/Controller.php, line 960 ExceptionRenderer::_outputMessage() - CORE/Cake/Error/ExceptionRenderer.php, line 289 ExceptionRenderer::_cakeError() - CORE/Cake/Error/ExceptionRenderer.php, line 210 ExceptionRenderer::render() - CORE/Cake/Error/ExceptionRenderer.php, line 187 ErrorHandler::handleException() - CORE/Cake/Error/ErrorHandler.php, line 127 [main] - [internal], line ??
Notice (8): Undefined variable: data [APP/View/Layouts/default.ctp, line 13]Code Context
//---
$page_js = mtouch_d($data, "page_js", "");
$viewFile = '/usr/home/www/pollut/nos/cpnos/app/View/Layouts/default.ctp' $dataForView = array( 'class' => 'Postgres', 'message' => 'SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?', 'enabled' => true, 'code' => (int) 500, 'name' => 'Database connection "Postgres" is missing, or could not be created.', 'url' => '/nos/cpnos/main', 'error' => object(MissingConnectionException) { }, '_serialize' => array( (int) 0 => 'code', (int) 1 => 'name', (int) 2 => 'message', (int) 3 => 'url' ), 'content_for_layout' => '<h2>Missing Database Connection</h2> <p class="error"> <strong>Error: </strong> A Database connection using "Postgres" was missing or unable to connect. <br /> The database server returned this error: SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?</p> <p class="notice"> <strong>Notice: </strong> If you want to customize this error message, create app/View/Errors/missing_connection.ctp</p> <h3>Stack Trace</h3> <ul class="cake-stack-trace"> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-0')">CORE/Cake/Model/Datasource/DboSource.php line 260</a> → <a href="#" onclick="traceToggle(event, 'trace-args-0')">Postgres->connect()</a> <div id="file-excerpt-0" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$autoConnect</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">connect</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-0" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-1')">CORE/Cake/Model/ConnectionManager.php line 105</a> → <a href="#" onclick="traceToggle(event, 'trace-args-1')">DboSource->__construct(array)</a> <div id="file-excerpt-1" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'message' </span><span style="color: #007700">=> </span><span style="color: #DD0000">'Datasource is not found in Model/Datasource package.'</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">] = new </span><span style="color: #0000BB">$class</span><span style="color: #007700">(</span><span style="color: #0000BB">self</span><span style="color: #007700">::</span><span style="color: #0000BB">$config</span><span style="color: #007700">->{</span><span style="color: #0000BB">$name</span><span style="color: #007700">});</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">]-></span><span style="color: #0000BB">configKeyName </span><span style="color: #007700">= </span><span style="color: #0000BB">$name</span><span style="color: #007700">;</span></span></code></pre></div> <div id="trace-args-1" class="cake-code-dump" style="display: none;"><pre>array( 'password' => '*****', 'login' => '*****', 'host' => '*****', 'database' => '*****', 'port' => '*****', 'prefix' => '*****', 'schema' => '*****', 'datasource' => 'Database/Postgres', 'persistent' => false, 'encoding' => 'utf8' )</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-2')">CORE/Cake/Model/Model.php line 3617</a> → <a href="#" onclick="traceToggle(event, 'trace-args-2')">ConnectionManager::getDataSource(string)</a> <div id="file-excerpt-2" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig </span><span style="color: #007700">= </span><span style="color: #0000BB">$dataSource</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!empty(</span><span style="color: #0000BB">$oldConfig</span><span style="color: #007700">) && isset(</span><span style="color: #0000BB">$db</span><span style="color: #007700">-></span><span style="color: #0000BB">config</span><span style="color: #007700">[</span><span style="color: #DD0000">'prefix'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-2" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-3')">CORE/Cake/Model/Model.php line 1155</a> → <a href="#" onclick="traceToggle(event, 'trace-args-3')">Model->setDataSource(string)</a> <div id="file-excerpt-3" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">* @return </span><span style="color: #0000BB">void</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$tableName</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-3" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-4')">CORE/Cake/Model/Model.php line 3644</a> → <a href="#" onclick="traceToggle(event, 'trace-args-4')">Model->setSource(string)</a> <div id="file-excerpt-4" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">() {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">&& </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable </span><span style="color: #007700">!== </span><span style="color: #0000BB">false</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-4" class="cake-code-dump" style="display: none;"><pre>'nos_data'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-5')">CORE/Cake/Model/Model.php line 3446</a> → <a href="#" onclick="traceToggle(event, 'trace-args-5')">Model->getDataSource()</a> <div id="file-excerpt-5" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $params </span><span style="color: #007700">= </span><span style="color: #0000BB">func_get_args</span><span style="color: #007700">();</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">call_user_func_array</span><span style="color: #007700">(array(&</span><span style="color: #0000BB">$db</span><span style="color: #007700">, </span><span style="color: #DD0000">'query'</span><span style="color: #007700">), </span><span style="color: #0000BB">$params</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-5" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-6')">APP/Controller/MainController.php line 23</a> → <a href="#" onclick="traceToggle(event, 'trace-args-6')">Model->query(string)</a> <div id="file-excerpt-6" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #FF8000">//---</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">loadModel</span><span style="color: #007700">(</span><span style="color: #DD0000">'Nos_data'</span><span style="color: #007700">);</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $sql </span><span style="color: #007700">= </span><span style="color: #DD0000">"select count(id) as k_ from nos_data"</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $res </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">Nos_data</span><span style="color: #007700">-></span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $n_data </span><span style="color: #007700">= </span><span style="color: #0000BB">$res</span><span style="color: #007700">[</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #DD0000">'k_'</span><span style="color: #007700">];</span></span></code></pre></div> <div id="trace-args-6" class="cake-code-dump" style="display: none;"><pre>'select count(id) as k_ from nos_data'</pre></div></li> <li><a href="#">[internal function]</a> → <a href="#" onclick="traceToggle(event, 'trace-args-7')">MainController->index()</a> <div id="trace-args-7" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-8')">CORE/Cake/Controller/Controller.php line 490</a> → <a href="#" onclick="traceToggle(event, 'trace-args-8')">ReflectionMethod->invokeArgs(MainController, array)</a> <div id="file-excerpt-8" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'action' </span><span style="color: #007700">=> </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'action'</span><span style="color: #007700">]</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">$method</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeArgs</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'pass'</span><span style="color: #007700">]);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-8" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } array()</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-9')">CORE/Cake/Routing/Dispatcher.php line 193</a> → <a href="#" onclick="traceToggle(event, 'trace-args-9')">Controller->invokeAction(CakeRequest)</a> <div id="file-excerpt-9" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">response</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $render </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $result </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeAction</span><span style="color: #007700">(</span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$result </span><span style="color: #007700">instanceof </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">) {</span></span></code></pre></div> <div id="trace-args-9" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-10')">CORE/Cake/Routing/Dispatcher.php line 167</a> → <a href="#" onclick="traceToggle(event, 'trace-args-10')">Dispatcher->_invoke(MainController, CakeRequest)</a> <div id="file-excerpt-10" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_invoke</span><span style="color: #007700">(</span><span style="color: #0000BB">$controller</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (isset(</span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'return'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-10" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-11')">APP/webroot/index.php line 118</a> → <a href="#" onclick="traceToggle(event, 'trace-args-11')">Dispatcher->dispatch(CakeRequest, CakeResponse)</a> <div id="file-excerpt-11" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB">$Dispatcher</span><span style="color: #007700">-></span><span style="color: #0000BB">dispatch</span><span style="color: #007700">(</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeRequest</span><span style="color: #007700">(),</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">()</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"></span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-11" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } object(CakeResponse) { }</pre></div></li> </ul> <script type="text/javascript"> function traceToggle(event, id) { var el = document.getElementById(id); el.style.display = (el.style.display === 'block') ? 'none' : 'block'; event.preventDefault(); return false; } </script> ', 'scripts_for_layout' => '', 'title_for_layout' => 'Errors' ) $class = 'Postgres' $message = 'SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?' $enabled = true $code = (int) 500 $name = 'Database connection "Postgres" is missing, or could not be created.' $url = '/nos/cpnos/main' $error = object(MissingConnectionException) { } $_serialize = array( (int) 0 => 'code', (int) 1 => 'name', (int) 2 => 'message', (int) 3 => 'url' ) $content_for_layout = '<h2>Missing Database Connection</h2> <p class="error"> <strong>Error: </strong> A Database connection using "Postgres" was missing or unable to connect. <br /> The database server returned this error: SQLSTATE[08006] [7] could not connect to server: Host is down Is the server running on host "192.168.0.3" and accepting TCP/IP connections on port 5433?</p> <p class="notice"> <strong>Notice: </strong> If you want to customize this error message, create app/View/Errors/missing_connection.ctp</p> <h3>Stack Trace</h3> <ul class="cake-stack-trace"> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-0')">CORE/Cake/Model/Datasource/DboSource.php line 260</a> → <a href="#" onclick="traceToggle(event, 'trace-args-0')">Postgres->connect()</a> <div id="file-excerpt-0" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$autoConnect</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">connect</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-0" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-1')">CORE/Cake/Model/ConnectionManager.php line 105</a> → <a href="#" onclick="traceToggle(event, 'trace-args-1')">DboSource->__construct(array)</a> <div id="file-excerpt-1" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'message' </span><span style="color: #007700">=> </span><span style="color: #DD0000">'Datasource is not found in Model/Datasource package.'</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">] = new </span><span style="color: #0000BB">$class</span><span style="color: #007700">(</span><span style="color: #0000BB">self</span><span style="color: #007700">::</span><span style="color: #0000BB">$config</span><span style="color: #007700">->{</span><span style="color: #0000BB">$name</span><span style="color: #007700">});</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> self</span><span style="color: #007700">::</span><span style="color: #0000BB">$_dataSources</span><span style="color: #007700">[</span><span style="color: #0000BB">$name</span><span style="color: #007700">]-></span><span style="color: #0000BB">configKeyName </span><span style="color: #007700">= </span><span style="color: #0000BB">$name</span><span style="color: #007700">;</span></span></code></pre></div> <div id="trace-args-1" class="cake-code-dump" style="display: none;"><pre>array( 'password' => '*****', 'login' => '*****', 'host' => '*****', 'database' => '*****', 'port' => '*****', 'prefix' => '*****', 'schema' => '*****', 'datasource' => 'Database/Postgres', 'persistent' => false, 'encoding' => 'utf8' )</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-2')">CORE/Cake/Model/Model.php line 3617</a> → <a href="#" onclick="traceToggle(event, 'trace-args-2')">ConnectionManager::getDataSource(string)</a> <div id="file-excerpt-2" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig </span><span style="color: #007700">= </span><span style="color: #0000BB">$dataSource</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!empty(</span><span style="color: #0000BB">$oldConfig</span><span style="color: #007700">) && isset(</span><span style="color: #0000BB">$db</span><span style="color: #007700">-></span><span style="color: #0000BB">config</span><span style="color: #007700">[</span><span style="color: #DD0000">'prefix'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-2" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-3')">CORE/Cake/Model/Model.php line 1155</a> → <a href="#" onclick="traceToggle(event, 'trace-args-3')">Model->setDataSource(string)</a> <div id="file-excerpt-3" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">* @return </span><span style="color: #0000BB">void</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$tableName</span><span style="color: #007700">) {</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">ConnectionManager</span><span style="color: #007700">::</span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useDbConfig</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-3" class="cake-code-dump" style="display: none;"><pre>'default'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-4')">CORE/Cake/Model/Model.php line 3644</a> → <a href="#" onclick="traceToggle(event, 'trace-args-4')">Model->setSource(string)</a> <div id="file-excerpt-4" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">() {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (!</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">&& </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable </span><span style="color: #007700">!== </span><span style="color: #0000BB">false</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">_sourceConfigured </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">setSource</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">useTable</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code></pre></div> <div id="trace-args-4" class="cake-code-dump" style="display: none;"><pre>'nos_data'</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-5')">CORE/Cake/Model/Model.php line 3446</a> → <a href="#" onclick="traceToggle(event, 'trace-args-5')">Model->getDataSource()</a> <div id="file-excerpt-5" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">*/</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">public function </span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">) {</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $params </span><span style="color: #007700">= </span><span style="color: #0000BB">func_get_args</span><span style="color: #007700">();</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $db </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">getDataSource</span><span style="color: #007700">();</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">call_user_func_array</span><span style="color: #007700">(array(&</span><span style="color: #0000BB">$db</span><span style="color: #007700">, </span><span style="color: #DD0000">'query'</span><span style="color: #007700">), </span><span style="color: #0000BB">$params</span><span style="color: #007700">);</span></span></code></pre></div> <div id="trace-args-5" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-6')">APP/Controller/MainController.php line 23</a> → <a href="#" onclick="traceToggle(event, 'trace-args-6')">Model->query(string)</a> <div id="file-excerpt-6" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #FF8000">//---</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $this</span><span style="color: #007700">-></span><span style="color: #0000BB">loadModel</span><span style="color: #007700">(</span><span style="color: #DD0000">'Nos_data'</span><span style="color: #007700">);</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $sql </span><span style="color: #007700">= </span><span style="color: #DD0000">"select count(id) as k_ from nos_data"</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $res </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">Nos_data</span><span style="color: #007700">-></span><span style="color: #0000BB">query</span><span style="color: #007700">(</span><span style="color: #0000BB">$sql</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> $n_data </span><span style="color: #007700">= </span><span style="color: #0000BB">$res</span><span style="color: #007700">[</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #0000BB">0</span><span style="color: #007700">][</span><span style="color: #DD0000">'k_'</span><span style="color: #007700">];</span></span></code></pre></div> <div id="trace-args-6" class="cake-code-dump" style="display: none;"><pre>'select count(id) as k_ from nos_data'</pre></div></li> <li><a href="#">[internal function]</a> → <a href="#" onclick="traceToggle(event, 'trace-args-7')">MainController->index()</a> <div id="trace-args-7" class="cake-code-dump" style="display: none;"><pre></pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-8')">CORE/Cake/Controller/Controller.php line 490</a> → <a href="#" onclick="traceToggle(event, 'trace-args-8')">ReflectionMethod->invokeArgs(MainController, array)</a> <div id="file-excerpt-8" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #DD0000">'action' </span><span style="color: #007700">=> </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'action'</span><span style="color: #007700">]</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">return </span><span style="color: #0000BB">$method</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeArgs</span><span style="color: #007700">(</span><span style="color: #0000BB">$this</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'pass'</span><span style="color: #007700">]);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-8" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } array()</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-9')">CORE/Cake/Routing/Dispatcher.php line 193</a> → <a href="#" onclick="traceToggle(event, 'trace-args-9')">Controller->invokeAction(CakeRequest)</a> <div id="file-excerpt-9" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">response</span><span style="color: #007700">;</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> $render </span><span style="color: #007700">= </span><span style="color: #0000BB">true</span><span style="color: #007700">;</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $result </span><span style="color: #007700">= </span><span style="color: #0000BB">$controller</span><span style="color: #007700">-></span><span style="color: #0000BB">invokeAction</span><span style="color: #007700">(</span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (</span><span style="color: #0000BB">$result </span><span style="color: #007700">instanceof </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">) {</span></span></code></pre></div> <div id="trace-args-9" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-10')">CORE/Cake/Routing/Dispatcher.php line 167</a> → <a href="#" onclick="traceToggle(event, 'trace-args-10')">Dispatcher->_invoke(MainController, CakeRequest)</a> <div id="file-excerpt-10" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">));</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">}</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"> $response </span><span style="color: #007700">= </span><span style="color: #0000BB">$this</span><span style="color: #007700">-></span><span style="color: #0000BB">_invoke</span><span style="color: #007700">(</span><span style="color: #0000BB">$controller</span><span style="color: #007700">, </span><span style="color: #0000BB">$request</span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">if (isset(</span><span style="color: #0000BB">$request</span><span style="color: #007700">-></span><span style="color: #0000BB">params</span><span style="color: #007700">[</span><span style="color: #DD0000">'return'</span><span style="color: #007700">])) {</span></span></code></pre></div> <div id="trace-args-10" class="cake-code-dump" style="display: none;"><pre>object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }</pre></div></li> <li><a href="#" onclick="traceToggle(event, 'file-excerpt-11')">APP/webroot/index.php line 118</a> → <a href="#" onclick="traceToggle(event, 'trace-args-11')">Dispatcher->dispatch(CakeRequest, CakeResponse)</a> <div id="file-excerpt-11" class="cake-code-dump" style="display:none;"><pre><code><span style="color: #000000"><span style="color: #0000BB">$Dispatcher</span><span style="color: #007700">-></span><span style="color: #0000BB">dispatch</span><span style="color: #007700">(</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeRequest</span><span style="color: #007700">(),</span></span></code> <code><span style="color: #000000"><span style="color: #0000BB"> </span><span style="color: #007700">new </span><span style="color: #0000BB">CakeResponse</span><span style="color: #007700">()</span></span></code> <span class="code-highlight"><code><span style="color: #000000"><span style="color: #0000BB"></span><span style="color: #007700">);</span></span></code></span> <code><span style="color: #000000"><span style="color: #0000BB"></span></span></code></pre></div> <div id="trace-args-11" class="cake-code-dump" style="display: none;"><pre>object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } object(CakeResponse) { }</pre></div></li> </ul> <script type="text/javascript"> function traceToggle(event, id) { var el = document.getElementById(id); el.style.display = (el.style.display === 'block') ? 'none' : 'block'; event.preventDefault(); return false; } </script> ' $scripts_for_layout = '' $title_for_layout = 'Errors' $bs = '/nos/cpnos' $pn_menu = '' $tek_menu = ''include - APP/View/Layouts/default.ctp, line 13 View::_evaluate() - CORE/Cake/View/View.php, line 961 View::_render() - CORE/Cake/View/View.php, line 923 View::renderLayout() - CORE/Cake/View/View.php, line 546 View::render() - CORE/Cake/View/View.php, line 481 Controller::render() - CORE/Cake/Controller/Controller.php, line 960 ExceptionRenderer::_outputMessage() - CORE/Cake/Error/ExceptionRenderer.php, line 289 ExceptionRenderer::_cakeError() - CORE/Cake/Error/ExceptionRenderer.php, line 210 ExceptionRenderer::render() - CORE/Cake/Error/ExceptionRenderer.php, line 187 ErrorHandler::handleException() - CORE/Cake/Error/ErrorHandler.php, line 127 [main] - [internal], line ??
Error:
A Database connection using "Postgres" was missing or unable to connect.
The database server returned this error: SQLSTATE[08006] [7] could not connect to server: Host is down
Is the server running on host "192.168.0.3" and accepting
TCP/IP connections on port 5433?
Notice: If you want to customize this error message, create app/View/Errors/missing_connection.ctp
));
}
if ($autoConnect) {
$this->connect();
}
'message' => 'Datasource is not found in Model/Datasource package.'
));
}
self::$_dataSources[$name] = new $class(self::$config->{$name});
self::$_dataSources[$name]->configKeyName = $name;
array( 'password' => '*****', 'login' => '*****', 'host' => '*****', 'database' => '*****', 'port' => '*****', 'prefix' => '*****', 'schema' => '*****', 'datasource' => 'Database/Postgres', 'persistent' => false, 'encoding' => 'utf8' )
$this->useDbConfig = $dataSource;
}
$db = ConnectionManager::getDataSource($this->useDbConfig);
if (!empty($oldConfig) && isset($db->config['prefix'])) {
'default'
* @return void
*/
public function setSource($tableName) {
$this->setDataSource($this->useDbConfig);
$db = ConnectionManager::getDataSource($this->useDbConfig);
'default'
public function getDataSource() {
if (!$this->_sourceConfigured && $this->useTable !== false) {
$this->_sourceConfigured = true;
$this->setSource($this->useTable);
}
'nos_data'
*/
public function query($sql) {
$params = func_get_args();
$db = $this->getDataSource();
return call_user_func_array(array(&$db, 'query'), $params);
//---
$this->loadModel('Nos_data');
$sql = "select count(id) as k_ from nos_data";
$res = $this->Nos_data->query($sql);
$n_data = $res[0][0]['k_'];
'select count(id) as k_ from nos_data'
'action' => $request->params['action']
));
}
return $method->invokeArgs($this, $request->params['pass']);
object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } array()
$response = $controller->response;
$render = true;
$result = $controller->invokeAction($request);
if ($result instanceof CakeResponse) {
object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }
));
}
$response = $this->_invoke($controller, $request);
if (isset($request->params['return'])) {
object(MainController) { components => array( (int) 0 => 'Flash', (int) 1 => 'Session', 'Auth' => array( 'authenticate' => array( [maximum depth reached] ), 'authorize' => 'Controller' ) ) name => 'Main' uses => array( (int) 0 => 'Main', (int) 1 => 'Nos_data' ) helpers => array() request => object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } response => object(CakeResponse) { } viewPath => 'Main' layoutPath => null viewVars => array() view => 'index' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) { defaultPriority => (int) 10 } viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array() scaffold => false methods => array( (int) 0 => 'index', (int) 1 => 'apk', (int) 2 => 'api_get_years', (int) 4 => 'mkk_autorize' ) modelClass => 'Main' modelKey => 'main' validationErrors => null Flash => object(FlashComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Session => object(SessionComponent) { settings => array([maximum depth reached]) components => array([maximum depth reached]) } Auth => object(AuthComponent) { components => array( [maximum depth reached] ) authenticate => array( [maximum depth reached] ) authorize => 'Controller' ajaxLogin => null flash => array( [maximum depth reached] ) loginAction => array( [maximum depth reached] ) loginRedirect => null logoutRedirect => array( [maximum depth reached] ) authError => 'You are not authorized to access that location.' unauthorizedRedirect => true allowedActions => array( [maximum depth reached] ) request => object(CakeRequest) {} response => object(CakeResponse) {} settings => array( [maximum depth reached] ) } Nos_data => object(AppModel) { useDbConfig => 'default' useTable => 'nos_data' id => null data => array([maximum depth reached]) schemaName => null table => 'nos_data' primaryKey => 'id' validate => array([maximum depth reached]) validationErrors => array([maximum depth reached]) validationDomain => null plugin => null name => 'Nos_data' alias => 'Nos_data' tableToModel => array( [maximum depth reached] ) cacheQueries => false belongsTo => array([maximum depth reached]) hasOne => array([maximum depth reached]) hasMany => array([maximum depth reached]) hasAndBelongsToMany => array([maximum depth reached]) actsAs => null Behaviors => object(BehaviorCollection) {} whitelist => array([maximum depth reached]) cacheSources => true findQueryType => null recursive => (int) 1 order => null virtualFields => array([maximum depth reached]) __backAssociation => array([maximum depth reached]) __backInnerAssociation => array([maximum depth reached]) __backOriginalAssociation => array([maximum depth reached]) __backContainableAssociation => array([maximum depth reached]) __safeUpdateMode => false useConsistentAfterFind => true findMethods => array( [maximum depth reached] ) } } object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' }
$Dispatcher->dispatch(
new CakeRequest(),
new CakeResponse()
);
object(CakeRequest) { params => array( 'plugin' => null, 'controller' => 'main', 'action' => 'index', 'named' => array(), 'pass' => array(), 'models' => array( 'Nos_data' => array( [maximum depth reached] ) ) ) data => array() query => array() url => 'main' base => '/nos/cpnos' webroot => '/nos/cpnos/' here => '/nos/cpnos/main' } object(CakeResponse) { }