Notice (8): file_put_contents(): Write of 270 bytes failed with errno=28 No space left on device [CORE/src/Log/Engine/FileLog.php, line 140]Code Contextif (!$mask) {
file_put_contents($pathname, $message . "\n", FILE_APPEND);
file_put_contents - [internal], line ?? Cake\Log\Engine\FileLog::log() - CORE/src/Log/Engine/FileLog.php, line 140 Cake\Log\Log::write() - CORE/src/Log/Log.php, line 392 Cake\Log\Log::warning() - CORE/src/Log/Log.php, line 477 DebugKit\ToolbarService::isSuspiciouslyProduction() - ROOT/vendor/cakephp/debug_kit/src/ToolbarService.php, line 169 DebugKit\ToolbarService::isEnabled() - ROOT/vendor/cakephp/debug_kit/src/ToolbarService.php, line 105 DebugKit\Plugin::bootstrap() - ROOT/vendor/cakephp/debug_kit/src/Plugin.php, line 48 Cake\Http\BaseApplication::pluginBootstrap() - CORE/src/Http/BaseApplication.php, line 182 Cake\Http\Server::bootstrap() - CORE/src/Http/Server.php, line 111 Cake\Http\Server::run() - CORE/src/Http/Server.php, line 79 [main] - ROOT/webroot/index.php, line 40
Notice (8): unserialize() [<a href='https://secure.php.net/function.unserialize'>function.unserialize</a>]: Error at offset 4081 of 4085 bytes [CORE/src/Cache/Engine/FileEngine.php, line 201]Code Contextif ($data !== '' && !empty($this->_config['serialize'])) {
$data = unserialize($data);
}
unserialize - [internal], line ?? Cake\Cache\Engine\FileEngine::get() - CORE/src/Cache/Engine/FileEngine.php, line 201 Cake\Database\Schema\CachedCollection::describe() - CORE/src/Database/Schema/CachedCollection.php, line 78 Cake\ORM\Table::getSchema() - CORE/src/ORM/Table.php, line 513 Cake\ORM\Query::addDefaultTypes() - CORE/src/ORM/Query.php, line 290 Cake\ORM\Query::__construct() - CORE/src/ORM/Query.php, line 184 Cake\ORM\Table::query() - CORE/src/ORM/Table.php, line 1702 Cake\ORM\Table::find() - CORE/src/ORM/Table.php, line 1263 App\Controller\YuanmaController::action_() - APP/Controller/YuanmaController.php, line 4431 App\Controller\YuanmaController::get_data() - APP/Controller/YuanmaController.php, line 4079 App\Controller\YuanmaController::action_cache() - APP/Controller/YuanmaController.php, line 3871 App\Controller\YuanmaController::cache_action() - APP/Controller/YuanmaController.php, line 3659 App\Controller\YuanmaController::index() - APP/Controller/YuanmaController.php, line 1478 Cake\Controller\Controller::invokeAction() - CORE/src/Controller/Controller.php, line 539 Cake\Controller\ControllerFactory::handle() - CORE/src/Controller/ControllerFactory.php, line 140 Cake\Controller\ControllerFactory::invoke() - CORE/src/Controller/ControllerFactory.php, line 115 Cake\Http\BaseApplication::handle() - CORE/src/Http/BaseApplication.php, line 317
|
|
if (!$options['forceRefresh']) { |
|
$cached = $this->cacher->get($cacheKey); |
|
if ($cached !== null) { |
|
return $cached; |
|
} |
|
} |
|
|
|
$table = $this->collection->describe($name, $options); |
if ($this->_schema === null) { |
|
$this->_schema = $this->_initializeSchema( |
|
$this->getConnection() |
|
->getSchemaCollection() |
|
->describe($this->getTable()) |
|
); |
|
if (Configure::read('debug')) { |
|
$this->checkAliasLengths(); |
|
} |
*/ |
|
public function addDefaultTypes(Table $table) |
|
{ |
|
$alias = $table->getAlias(); |
|
$map = $table->getSchema()->typeMap(); |
|
$fields = []; |
|
foreach ($map as $f => $type) { |
|
$fields[$f] = $fields[$alias . '.' . $f] = $fields[$alias . '__' . $f] = $type; |
|
} |
parent::__construct($connection); |
|
$this->repository($table); |
|
|
|
if ($this->_repository !== null) { |
|
$this->addDefaultTypes($this->_repository); |
|
} |
|
} |
|
|
|
/** |
* @return \Cake\ORM\Query |
|
*/ |
|
public function query(): Query |
|
{ |
|
return new Query($this->getConnection(), $this); |
|
} |
|
|
|
/** |
|
* Creates a new Query::subquery() instance for a table. |
* @return \Cake\ORM\Query The query builder |
|
*/ |
|
public function find(string $type = 'all', array $options = []): Query |
|
{ |
|
$query = $this->query(); |
|
$query->select(); |
|
|
|
return $this->callFinder($type, $query, $options); |
|
} |
// exit; |
|
|
|
if ($like_str=="" or $search_str=="") |
|
{ |
|
$num = $this->fetchTable($table_name)->find('all', array('conditions'=>$data["where"]))->count(); |
|
} |
|
else |
|
{ |
|
$num = $this->fetchTable($table_name)->find('all', array('conditions'=>$where_like_search))->count(); |
set_time_limit(240); //4minutes |
|
ini_set('memory_limit', '512M'); |
|
date_default_timezone_set('PRC'); |
|
|
|
$abc=$this->action_($array,$is_http=1); |
|
|
|
$show=array(); |
|
$show["code"]=200; |
|
$show["data"]=$abc; |
//获取数据=============== |
|
$action="get_data"; |
|
$array["Async"]=0;//是否异步,0不是异步,1异步 |
|
$array["cache_cache_file_name"]=$cache_cache_file_name; |
|
$file=$this->$action($array); |
|
|
|
if ($file["code"]==200) |
|
{ |
|
//获取数据成功! |
{ |
|
|
|
date_default_timezone_set('PRC'); |
|
|
|
$file=$this->action_cache($get_data); |
|
|
|
if ($file["code"]==200) |
|
{ |
|
$match=$file["data"]; |
$belongsTo=array(); |
|
$belongsTo[0]="Yuanmasorts"; |
|
$get_data["belongsTo"]=$belongsTo; |
|
|
|
$website_=$this->cache_action($get_data); |
|
|
|
|
|
//处理成 websites/index 的模板也能用的格式,这样模板就不需要单独做了,因为只是这里需要这样的处理,所以不需要写成单独的函数了 |
|
$news=array(); |
* @throws \UnexpectedValueException If return value of action is not `null` or `ResponseInterface` instance. |
|
*/ |
|
public function invokeAction(Closure $action, array $args): void |
|
{ |
|
$result = $action(...$args); |
|
if ($result !== null && !$result instanceof ResponseInterface) { |
|
throw new UnexpectedValueException(sprintf( |
|
'Controller actions can only return ResponseInterface instance or null. ' |
|
. 'Got %s instead.', |
$args = $this->getActionArgs( |
|
$action, |
|
array_values((array)$controller->getRequest()->getParam('pass')) |
|
); |
|
$controller->invokeAction($action, $args); |
|
|
|
$result = $controller->shutdownProcess(); |
|
if ($result instanceof ResponseInterface) { |
|
return $result; |
|
|
return $runner->run($middlewareQueue, $controller->getRequest(), $this); |
|
} |
|
|
|
return $this->handle($controller->getRequest()); |
|
} |
|
|
|
/** |
|
* Invoke the action. |
} |
|
|
|
$controller = $this->controllerFactory->create($request); |
|
|
|
return $this->controllerFactory->invoke($controller); |
|
} |
|
} |
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
|
} |
|
|
|
$response = new Response([ |
|
'body' => 'Middleware queue was exhausted without returning a response ' |
if ($method === 'GET' && $cookieData === null) { |
|
$token = $this->createToken(); |
|
$request = $request->withAttribute('csrfToken', $this->saltToken($token)); |
|
/** @var mixed $response */ |
|
$response = $handler->handle($request); |
|
|
|
return $this->_addTokenCookie($token, $request, $response); |
|
} |
|
|
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
if ($locale || $this->locales === ['*']) { |
|
I18n::setLocale($locale); |
|
} |
|
|
|
return $handler->handle($request); |
|
} |
|
} |
|
|
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
*/ |
|
public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface |
|
{ |
|
if (!in_array($request->getMethod(), $this->methods, true)) { |
|
return $handler->handle($request); |
|
} |
|
[$type] = explode(';', $request->getHeaderLine('Content-Type')); |
|
$type = strtolower($type); |
|
if (!isset($this->parsers[$type])) { |
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
); |
|
} |
|
$matching = Router::getRouteCollection()->getMiddleware($middleware); |
|
if (!$matching) { |
|
return $handler->handle($request); |
|
} |
|
|
|
$middleware = new MiddlewareQueue($matching); |
|
$runner = new Runner(); |
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
} |
|
|
|
$assetFile = $this->_getAssetFile($url); |
|
if ($assetFile === null || !is_file($assetFile)) { |
|
return $handler->handle($request); |
|
} |
|
|
|
$file = new SplFileInfo($assetFile); |
|
$modifiedTime = $file->getMTime(); |
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
*/ |
|
public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface |
|
{ |
|
try { |
|
return $handler->handle($request); |
|
} catch (RedirectException $exception) { |
|
return $this->handleRedirect($exception); |
|
} catch (Throwable $exception) { |
|
return $this->handleException($exception, $request); |
if ($this->queue->valid()) { |
|
$middleware = $this->queue->current(); |
|
$this->queue->next(); |
|
|
|
return $middleware->process($request, $this); |
|
} |
|
|
|
if ($this->fallbackHandler) { |
|
return $this->fallbackHandler->handle($request); |
$this->queue = $queue; |
|
$this->queue->rewind(); |
|
$this->fallbackHandler = $fallbackHandler; |
|
|
|
return $this->handle($request); |
|
} |
|
|
|
/** |
|
* Handle incoming server request and return a response. |
} |
|
|
|
$this->dispatchEvent('Server.buildMiddleware', ['middleware' => $middleware]); |
|
|
|
$response = $this->runner->run($middleware, $request, $this->app); |
|
|
|
if ($request instanceof ServerRequest) { |
|
$request->getSession()->close(); |
|
} |
// Bind your application to the server. |
|
$server = new Server(new Application(dirname(__DIR__) . '/config')); |
|
|
|
// Run the request/response through the application and emit the response. |
|
$server->emit($server->run()); |
|
|
If you want to customize this error message, create templates/Error/error500.php