Warning (2): file_put_contents(): Only 0 of 2191 bytes written, possibly out of free disk space [CORE\Cake\Log\Engine\FileLog.php, line 142]Code Context$pathname = $this->_path . $filename;
if (empty($this->_config['mask'])) {
return file_put_contents($pathname, $output, FILE_APPEND);
$type = 'error' $message = '[MissingConnectionException] Database connection "Mysql" is missing, or could not be created. Exception Attributes: array ( 'class' => 'Mysql', 'message' => 'SQLSTATE[HY000] [2002] No connection could be made because the target machine actively refused it. ', 'enabled' => true, ) Request URL: /Users/market_online/market_online_detail/36/main/item_info/23/page:34 Stack Trace: #0 D:\xampp\htdocs\agtrust\lib\Cake\Model\Datasource\DboSource.php(260): Mysql->connect() #1 D:\xampp\htdocs\agtrust\lib\Cake\Model\ConnectionManager.php(105): DboSource->__construct(Array) #2 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(3498): ConnectionManager::getDataSource('agtrust') #3 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(1136): Model->setDataSource('agtrust') #4 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(3525): Model->setSource('items') #5 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(1365): Model->getDataSource() #6 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(1457): Model->schema() #7 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(1444): Model->hasField('title', false) #8 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(888): Model->hasField(Array) #9 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(3088): Model->__get('displayField') #10 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(2953): Model->_findList('before', Array) #11 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(2888): Model->buildQuery('list', Array) #12 D:\xampp\htdocs\agtrust\app\Controller\UsersController.php(4198): Model->find('list') #13 [internal function]: UsersController->market_online('market_online_d...', '36', 'main', 'item_info', '23') #14 D:\xampp\htdocs\agtrust\lib\Cake\Controller\Controller.php(490): ReflectionMethod->invokeArgs(Object(UsersController), Array) #15 D:\xampp\htdocs\agtrust\lib\Cake\Routing\Dispatcher.php(191): Controller->invokeAction(Object(CakeRequest)) #16 D:\xampp\htdocs\agtrust\lib\Cake\Routing\Dispatcher.php(165): Dispatcher->_invoke(Object(UsersController), Object(CakeRequest)) #17 D:\xampp\htdocs\agtrust\app\webroot\index.php(108): Dispatcher->dispatch(Object(CakeRequest), Object(CakeResponse)) #18 {main}' $output = '2025-05-06 11:52:47 Error: [MissingConnectionException] Database connection "Mysql" is missing, or could not be created. Exception Attributes: array ( 'class' => 'Mysql', 'message' => 'SQLSTATE[HY000] [2002] No connection could be made because the target machine actively refused it. ', 'enabled' => true, ) Request URL: /Users/market_online/market_online_detail/36/main/item_info/23/page:34 Stack Trace: #0 D:\xampp\htdocs\agtrust\lib\Cake\Model\Datasource\DboSource.php(260): Mysql->connect() #1 D:\xampp\htdocs\agtrust\lib\Cake\Model\ConnectionManager.php(105): DboSource->__construct(Array) #2 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(3498): ConnectionManager::getDataSource('agtrust') #3 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(1136): Model->setDataSource('agtrust') #4 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(3525): Model->setSource('items') #5 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(1365): Model->getDataSource() #6 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(1457): Model->schema() #7 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(1444): Model->hasField('title', false) #8 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(888): Model->hasField(Array) #9 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(3088): Model->__get('displayField') #10 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(2953): Model->_findList('before', Array) #11 D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php(2888): Model->buildQuery('list', Array) #12 D:\xampp\htdocs\agtrust\app\Controller\UsersController.php(4198): Model->find('list') #13 [internal function]: UsersController->market_online('market_online_d...', '36', 'main', 'item_info', '23') #14 D:\xampp\htdocs\agtrust\lib\Cake\Controller\Controller.php(490): ReflectionMethod->invokeArgs(Object(UsersController), Array) #15 D:\xampp\htdocs\agtrust\lib\Cake\Routing\Dispatcher.php(191): Controller->invokeAction(Object(CakeRequest)) #16 D:\xampp\htdocs\agtrust\lib\Cake\Routing\Dispatcher.php(165): Dispatcher->_invoke(Object(UsersController), Object(CakeRequest)) #17 D:\xampp\htdocs\agtrust\app\webroot\index.php(108): Dispatcher->dispatch(Object(CakeRequest), Object(CakeResponse)) #18 {main} ' $filename = 'error.log' $pathname = 'D:\xampp\htdocs\agtrust\app\tmp\logs\error.log'file_put_contents - [internal], line ?? FileLog::write() - CORE\Cake\Log\Engine\FileLog.php, line 142 CakeLog::write() - CORE\Cake\Log\CakeLog.php, line 439 ErrorHandler::_log() - CORE\Cake\Error\ErrorHandler.php, line 178 ErrorHandler::handleException() - CORE\Cake\Error\ErrorHandler.php, line 110 [main] - [internal], line ??
Error:
A Database connection using "Mysql" was missing or unable to connect.
The database server returned this error: SQLSTATE[HY000] [2002] No connection could be made because the target machine actively refused it.
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' => '*****', 'prefix' => '*****', 'datasource' => 'Database/Mysql', 'persistent' => false, 'encoding' => 'utf8' )
$this->useDbConfig = $dataSource;
}
$db = ConnectionManager::getDataSource($this->useDbConfig);
if (!empty($oldConfig) && isset($db->config['prefix'])) {
'agtrust'
* @return void
*/
public function setSource($tableName) {
$this->setDataSource($this->useDbConfig);
$db = ConnectionManager::getDataSource($this->useDbConfig);
'agtrust'
public function getDataSource() {
if (!$this->_sourceConfigured && $this->useTable !== false) {
$this->_sourceConfigured = true;
$this->setSource($this->useTable);
}
'items'
*/
public function schema($field = false) {
if ($this->useTable !== false && (!is_array($this->_schema) || $field === true)) {
$db = $this->getDataSource();
$db->cacheSources = ($this->cacheSources && $db->cacheSources);
}
if (empty($this->_schema)) {
$this->schema();
}
public function hasField($name, $checkVirtual = false) {
if (is_array($name)) {
foreach ($name as $n) {
if ($this->hasField($n, $checkVirtual)) {
return $n;
'title' false
*/
public function __get($name) {
if ($name === 'displayField') {
return $this->displayField = $this->hasField(array('title', 'name', $this->primaryKey));
}
array( (int) 0 => 'title', (int) 1 => 'name', (int) 2 => 'id' )
protected function _findList($state, $query, $results = array()) {
if ($state === 'before') {
if (empty($query['fields'])) {
$query['fields'] = array("{$this->alias}.{$this->primaryKey}", "{$this->alias}.{$this->displayField}");
$list = array("{n}.{$this->alias}.{$this->primaryKey}", "{n}.{$this->alias}.{$this->displayField}", null);
'displayField'
);
if ($this->findMethods[$type] === true) {
$query = $this->{'_find' . ucfirst($type)}('before', $query);
}
'before' array( 'conditions' => null, 'fields' => null, 'joins' => array(), 'limit' => null, 'offset' => null, 'order' => null, 'page' => (int) 1, 'group' => null, 'callbacks' => true )
$this->findQueryType = $type;
$this->id = $this->getID();
$query = $this->buildQuery($type, $query);
if ($query === null) {
'list' array()
//debug('');debug('');debug('');debug('');
//debug($test);
$list_vegies = $this->Item->find('list');
$this->set(compact('list_vegies'));
'list'
'market_online_detail' '36' 'main' 'item_info' '23'
'action' => $request->params['action']
));
}
return $method->invokeArgs($this, $request->params['pass']);
object(UsersController) { uses => array( [maximum depth reached] ) name => 'Users' helpers => array([maximum depth reached]) request => object(CakeRequest) {} response => object(CakeResponse) {} viewPath => 'Users' layoutPath => null viewVars => array( [maximum depth reached] ) view => 'market_online' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) {} components => array( [maximum depth reached] ) viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array( [maximum depth reached] ) scaffold => false methods => array( [maximum depth reached] ) modelClass => 'User' modelKey => 'user' validationErrors => null Session => object(SessionComponent) {} Item => object(Item) {} [protected] _responseClass => 'CakeResponse' [protected] _mergeParent => 'AppController' [protected] _eventManager => object(CakeEventManager) {} [private] title_for_layout => 'AGTRACE CMU,Faculty of Agriculture Chiangmai University' [private] keywords => 'AGTRACE CMU,Faculty of Agriculture Chiangmai University' [private] keywordsTh => 'AGTRACE CMU,Faculty of Agriculture Chiangmai University' [private] description => 'AGTRACE CMU,Faculty of Agriculture Chiangmai University' [private] urlRoot => 'https://www.agtracecmu.agri.cmu.ac.th/' [private] img_url => 'https://www.agtracecmu.agri.cmu.ac.th/' } array( (int) 0 => 'market_online_detail', (int) 1 => '36', (int) 2 => 'main', (int) 3 => 'item_info', (int) 4 => '23' )
$response = $controller->response;
$render = true;
$result = $controller->invokeAction($request);
if ($result instanceof CakeResponse) {
object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'Users/market_online/market_online_detail/36/main/item_info/23/page:34' base => '' webroot => '/' here => '/Users/market_online/market_online_detail/36/main/item_info/23/page:34' [protected] _detectors => array( [maximum depth reached] ) [protected] _input => '' }
));
}
$response = $this->_invoke($controller, $request);
if (isset($request->params['return'])) {
object(UsersController) { uses => array( [maximum depth reached] ) name => 'Users' helpers => array([maximum depth reached]) request => object(CakeRequest) {} response => object(CakeResponse) {} viewPath => 'Users' layoutPath => null viewVars => array( [maximum depth reached] ) view => 'market_online' layout => 'default' autoRender => true autoLayout => true Components => object(ComponentCollection) {} components => array( [maximum depth reached] ) viewClass => 'View' View => null ext => '.ctp' plugin => null cacheAction => false passedArgs => array( [maximum depth reached] ) scaffold => false methods => array( [maximum depth reached] ) modelClass => 'User' modelKey => 'user' validationErrors => null Session => object(SessionComponent) {} Item => object(Item) {} [protected] _responseClass => 'CakeResponse' [protected] _mergeParent => 'AppController' [protected] _eventManager => object(CakeEventManager) {} [private] title_for_layout => 'AGTRACE CMU,Faculty of Agriculture Chiangmai University' [private] keywords => 'AGTRACE CMU,Faculty of Agriculture Chiangmai University' [private] keywordsTh => 'AGTRACE CMU,Faculty of Agriculture Chiangmai University' [private] description => 'AGTRACE CMU,Faculty of Agriculture Chiangmai University' [private] urlRoot => 'https://www.agtracecmu.agri.cmu.ac.th/' [private] img_url => 'https://www.agtracecmu.agri.cmu.ac.th/' } object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'Users/market_online/market_online_detail/36/main/item_info/23/page:34' base => '' webroot => '/' here => '/Users/market_online/market_online_detail/36/main/item_info/23/page:34' [protected] _detectors => array( [maximum depth reached] ) [protected] _input => '' }
$Dispatcher->dispatch(
new CakeRequest(),
new CakeResponse()
);
object(CakeRequest) { params => array( [maximum depth reached] ) data => array([maximum depth reached]) query => array([maximum depth reached]) url => 'Users/market_online/market_online_detail/36/main/item_info/23/page:34' base => '' webroot => '/' here => '/Users/market_online/market_online_detail/36/main/item_info/23/page:34' [protected] _detectors => array( [maximum depth reached] ) [protected] _input => '' } object(CakeResponse) { [protected] _statusCodes => array( [maximum depth reached] ) [protected] _mimeTypes => array( [maximum depth reached] ) [protected] _protocol => 'HTTP/1.1' [protected] _status => (int) 200 [protected] _contentType => 'text/html' [protected] _headers => array([maximum depth reached]) [protected] _body => null [protected] _file => null [protected] _fileRange => null [protected] _charset => 'UTF-8' [protected] _cacheDirectives => array([maximum depth reached]) [protected] _cookies => array([maximum depth reached]) }
Warning (512): _cake_core_ cache was unable to write 'file_map' to File cache [CORE\Cake\Cache\Cache.php, line 323]Code Context),
E_USER_WARNING
);
$key = 'file_map' $value = array( 'Configure' => 'D:\xampp\htdocs\agtrust\lib\Cake\Core\Configure.php', 'Hash' => 'D:\xampp\htdocs\agtrust\lib\Cake\Utility\Hash.php', 'Cache' => 'D:\xampp\htdocs\agtrust\lib\Cake\Cache\Cache.php', 'FileEngine' => 'D:\xampp\htdocs\agtrust\lib\Cake\Cache/Engine\FileEngine.php', 'CacheEngine' => 'D:\xampp\htdocs\agtrust\lib\Cake\Cache\CacheEngine.php', 'Inflector' => 'D:\xampp\htdocs\agtrust\lib\Cake\Utility\Inflector.php', 'ErrorHandler' => 'D:\xampp\htdocs\agtrust\lib\Cake\Error\ErrorHandler.php', 'CakePlugin' => 'D:\xampp\htdocs\agtrust\lib\Cake\Core\CakePlugin.php', 'CakeLog' => 'D:\xampp\htdocs\agtrust\lib\Cake\Log\CakeLog.php', 'LogEngineCollection' => 'D:\xampp\htdocs\agtrust\lib\Cake\Log\LogEngineCollection.php', 'ObjectCollection' => 'D:\xampp\htdocs\agtrust\lib\Cake\Utility\ObjectCollection.php', 'FileLog' => 'D:\xampp\htdocs\agtrust\lib\Cake\Log/Engine\FileLog.php', 'BaseLog' => 'D:\xampp\htdocs\agtrust\lib\Cake\Log/Engine\BaseLog.php', 'CakeLogInterface' => 'D:\xampp\htdocs\agtrust\lib\Cake\Log\CakeLogInterface.php', 'Debugger' => 'D:\xampp\htdocs\agtrust\lib\Cake\Utility\Debugger.php', 'String' => 'D:\xampp\htdocs\agtrust\lib\Cake\Utility\String.php', 'Dispatcher' => 'D:\xampp\htdocs\agtrust\lib\Cake\Routing\Dispatcher.php', 'CakeEventListener' => 'D:\xampp\htdocs\agtrust\lib\Cake\Event\CakeEventListener.php', 'CakeRequest' => 'D:\xampp\htdocs\agtrust\lib\Cake\Network\CakeRequest.php', 'CakeResponse' => 'D:\xampp\htdocs\agtrust\lib\Cake\Network\CakeResponse.php', 'CakeEvent' => 'D:\xampp\htdocs\agtrust\lib\Cake\Event\CakeEvent.php', 'CakeEventManager' => 'D:\xampp\htdocs\agtrust\lib\Cake\Event\CakeEventManager.php', 'AssetDispatcher' => 'D:\xampp\htdocs\agtrust\lib\Cake\Routing/Filter\AssetDispatcher.php', 'DispatcherFilter' => 'D:\xampp\htdocs\agtrust\lib\Cake\Routing\DispatcherFilter.php', 'CacheDispatcher' => 'D:\xampp\htdocs\agtrust\lib\Cake\Routing/Filter\CacheDispatcher.php', 'Router' => 'D:\xampp\htdocs\agtrust\lib\Cake\Routing\Router.php', 'CakeRoute' => 'D:\xampp\htdocs\agtrust\lib\Cake\Routing/Route\CakeRoute.php', 'PluginShortRoute' => 'D:\xampp\htdocs\agtrust\lib\Cake\Routing/Route\PluginShortRoute.php', 'UsersController' => 'D:\xampp\htdocs\agtrust\app\Controller\UsersController.php', 'AppController' => 'D:\xampp\htdocs\agtrust\app\Controller\AppController.php', 'Controller' => 'D:\xampp\htdocs\agtrust\lib\Cake\Controller\Controller.php', 'Object' => 'D:\xampp\htdocs\agtrust\lib\Cake\Core\Object.php', 'ComponentCollection' => 'D:\xampp\htdocs\agtrust\lib\Cake\Controller\ComponentCollection.php', 'SessionComponent' => 'D:\xampp\htdocs\agtrust\lib\Cake\Controller/Component\SessionComponent.php', 'Component' => 'D:\xampp\htdocs\agtrust\lib\Cake\Controller\Component.php', 'ClassRegistry' => 'D:\xampp\htdocs\agtrust\lib\Cake\Utility\ClassRegistry.php', 'Item' => 'D:\xampp\htdocs\agtrust\app\Model\Item.php', 'AppModel' => 'D:\xampp\htdocs\agtrust\app\Model\AppModel.php', 'Model' => 'D:\xampp\htdocs\agtrust\lib\Cake\Model\Model.php', 'BehaviorCollection' => 'D:\xampp\htdocs\agtrust\lib\Cake\Model\BehaviorCollection.php', 'ConnectionManager' => 'D:\xampp\htdocs\agtrust\lib\Cake\Model\ConnectionManager.php', 'Mysql' => 'D:\xampp\htdocs\agtrust\lib\Cake\Model/Datasource/Database\Mysql.php', 'DboSource' => 'D:\xampp\htdocs\agtrust\lib\Cake\Model/Datasource\DboSource.php', 'DataSource' => 'D:\xampp\htdocs\agtrust\lib\Cake\Model/Datasource\DataSource.php', 'I18n' => 'D:\xampp\htdocs\agtrust\lib\Cake\I18n\I18n.php', 'L10n' => 'D:\xampp\htdocs\agtrust\lib\Cake\I18n\L10n.php', 'CakeSession' => 'D:\xampp\htdocs\agtrust\lib\Cake\Model/Datasource\CakeSession.php', 'ExceptionRenderer' => 'D:\xampp\htdocs\agtrust\lib\Cake\Error\ExceptionRenderer.php', 'CakeErrorController' => 'D:\xampp\htdocs\agtrust\lib\Cake\Controller\CakeErrorController.php', 'View' => 'D:\xampp\htdocs\agtrust\lib\Cake\View\View.php', 'HelperCollection' => 'D:\xampp\htdocs\agtrust\lib\Cake\View\HelperCollection.php', 'ViewBlock' => 'D:\xampp\htdocs\agtrust\lib\Cake\View\ViewBlock.php', 'HtmlHelper' => 'D:\xampp\htdocs\agtrust\lib\Cake\View/Helper\HtmlHelper.php', 'AppHelper' => 'D:\xampp\htdocs\agtrust\app\View\Helper\AppHelper.php', 'Helper' => 'D:\xampp\htdocs\agtrust\lib\Cake\View\Helper.php', 'SessionHelper' => 'D:\xampp\htdocs\agtrust\lib\Cake\View/Helper\SessionHelper.php' ) $config = '_cake_core_' $settings = array( 'prefix' => '*****', 'engine' => 'File', 'path' => 'D:\xampp\htdocs\agtrust\app\tmp\cache\persistent\', 'serialize' => true, 'duration' => (int) 10, 'lock' => true, 'isWindows' => true, 'mask' => (int) 436, 'probability' => (int) 100, 'groups' => array() ) $success = falseCache::write() - CORE\Cake\Cache\Cache.php, line 323 App::shutdown() - CORE\Cake\Core\App.php, line 899 [main] - [internal], line ??