$arrRes = $query->toArray();
return $arrRes[0]->id;
}
Cake\Error\ErrorTrap->handleError() /home/xs713684/wellx.net/cakephp-5-1-5/src/Model/Table/ArticleCategoriesTable.php, line 118 App\Model\Table\ArticleCategoriesTable->getIdByCode() /home/xs713684/wellx.net/cakephp-5-1-5/src/Controller/ArticlesController.php, line 93 App\Controller\ArticlesController->pages() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Controller/Controller.php, line 500 Cake\Controller\Controller->invokeAction() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 166 Cake\Controller\ControllerFactory->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 141 Cake\Controller\ControllerFactory->invoke() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/BaseApplication.php, line 362 Cake\Http\BaseApplication->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 86 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Middleware/CsrfProtectionMiddleware.php, line 159 Cake\Http\Middleware\CsrfProtectionMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/authentication/src/Middleware/AuthenticationMiddleware.php, line 107 Authentication\Middleware\AuthenticationMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Middleware/BodyParserMiddleware.php, line 157 Cake\Http\Middleware\BodyParserMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Routing/Middleware/RoutingMiddleware.php, line 118 Cake\Routing\Middleware\RoutingMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Routing/Middleware/AssetMiddleware.php, line 78 Cake\Routing\Middleware\AssetMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Error/Middleware/ErrorHandlerMiddleware.php, line 115 Cake\Error\Middleware\ErrorHandlerMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 60 Cake\Http\Runner->run() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Server.php, line 104 Cake\Http\Server->run() /home/xs713684/wellx.net/public_html/index.php, line 42 [main]
$arrRes = $query->toArray();
return $arrRes[0]->id;
}
Cake\Error\ErrorTrap->handleError() /home/xs713684/wellx.net/cakephp-5-1-5/src/Model/Table/ArticleCategoriesTable.php, line 118 App\Model\Table\ArticleCategoriesTable->getIdByCode() /home/xs713684/wellx.net/cakephp-5-1-5/src/Controller/ArticlesController.php, line 93 App\Controller\ArticlesController->pages() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Controller/Controller.php, line 500 Cake\Controller\Controller->invokeAction() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 166 Cake\Controller\ControllerFactory->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Controller/ControllerFactory.php, line 141 Cake\Controller\ControllerFactory->invoke() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/BaseApplication.php, line 362 Cake\Http\BaseApplication->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 86 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Middleware/CsrfProtectionMiddleware.php, line 159 Cake\Http\Middleware\CsrfProtectionMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/authentication/src/Middleware/AuthenticationMiddleware.php, line 107 Authentication\Middleware\AuthenticationMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Middleware/BodyParserMiddleware.php, line 157 Cake\Http\Middleware\BodyParserMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Routing/Middleware/RoutingMiddleware.php, line 118 Cake\Routing\Middleware\RoutingMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Routing/Middleware/AssetMiddleware.php, line 78 Cake\Routing\Middleware\AssetMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Error/Middleware/ErrorHandlerMiddleware.php, line 115 Cake\Error\Middleware\ErrorHandlerMiddleware->process() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 82 Cake\Http\Runner->handle() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Runner.php, line 60 Cake\Http\Runner->run() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Server.php, line 104 Cake\Http\Server->run() /home/xs713684/wellx.net/public_html/index.php, line 42 [main]
$message = "Unable to emit headers. Headers sent in file={$file} line={$line}";
trigger_error($message, E_USER_WARNING);
}
Cake\Error\ErrorTrap->handleError() [internal], line ?? /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 65 Cake\Http\ResponseEmitter->emit() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Server.php, line 148 Cake\Http\Server->emit() /home/xs713684/wellx.net/public_html/index.php, line 42 [main]
$reasonPhrase = $response->getReasonPhrase();
header(sprintf(
'HTTP/%s %d%s',
Cake\Error\ErrorTrap->handleError() [internal], line ?? /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 159 Cake\Http\ResponseEmitter->emitStatusLine() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 68 Cake\Http\ResponseEmitter->emit() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Server.php, line 148 Cake\Http\Server->emit() /home/xs713684/wellx.net/public_html/index.php, line 42 [main]
foreach ($values as $value) {
header(sprintf(
'%s: %s',
Cake\Error\ErrorTrap->handleError() [internal], line ?? /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 192 Cake\Http\ResponseEmitter->emitHeaders() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 69 Cake\Http\ResponseEmitter->emit() /home/xs713684/wellx.net/cakephp-5-1-5/vendor/cakephp/cakephp/src/Http/Server.php, line 148 Cake\Http\Server->emit() /home/xs713684/wellx.net/public_html/index.php, line 42 [main]
`article_category_id`
is missing operator (IS, IS NOT) with `null`
value.
📋
$operator = '!='; |
|
} |
|
|
|
if ($value === null && $this->_conjunction !== ',') { |
|
throw new InvalidArgumentException( |
|
sprintf('Expression `%s` is missing operator (IS, IS NOT) with `null` value.', $expression), |
|
); |
|
} |
|
|
continue; |
|
} |
|
|
|
if (!$numericKey) { |
|
$this->_conditions[] = $this->_parseCondition($k, $c); |
|
} |
|
} |
|
} |
|
|
|
|
return $this; |
|
} |
|
|
|
$this->_addConditions($conditions, $types); |
|
|
|
return $this; |
|
} |
|
|
$append = $append($this->newExpr(), $this); |
|
} |
|
|
|
if ($expression->getConjunction() === $conjunction) { |
|
$expression->add($append, $types); |
|
} else { |
|
$expression = $this->newExpr() |
|
->setConjunction($conjunction) |
|
->add([$expression, $append], $types); |
) { |
|
if ($overwrite) { |
|
$this->_parts['where'] = $this->newExpr(); |
|
} |
|
$this->_conjugate('where', $conditions, 'AND', $types); |
|
|
|
return $this; |
|
} |
|
|
$arrArticleCategories1 = $this->ArticleCategories->getArrDescriptionList(); |
|
$this->set('arrArticleCategories1', $arrArticleCategories1); |
|
|
|
$arrDatas['ArticleCategories'] = $arrArticleCategories['ArticleCategories']; |
|
$arrDatas['Articles'] = $this->Articles->find('all')->where(['article_category_id' => $article_category_id])->orderBy(['id' => 'DESC'])->toArray(); |
|
$pgnum = $this->request->getQuery('pg'); |
|
|
|
// 条件表示 |
|
$disp_num = 10; |
* @return void |
|
*/ |
|
public function invokeAction(Closure $action, array $args): void |
|
{ |
|
$result = $action(...$args); |
|
if ($result !== null) { |
|
assert( |
|
$result instanceof Response, |
|
sprintf( |
$args = $this->getActionArgs( |
|
$action, |
|
array_values((array)$controller->getRequest()->getParam('pass')), |
|
); |
|
$controller->invokeAction($action, $args); |
|
|
|
$result = $controller->shutdownProcess(); |
|
if ($result !== null) { |
|
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); |
|
} |
|
|
|
return 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)); |
|
$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); |
$request = $request->withAttribute('authentication', $service); |
|
$request = $request->withAttribute('authenticationResult', $result); |
|
|
|
try { |
|
$response = $handler->handle($request); |
|
$authenticator = $service->getAuthenticationProvider(); |
|
|
|
if ($authenticator !== null && !$authenticator instanceof StatelessInterface) { |
|
/** |
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); |
|
} |
|
|
|
$container = $this->app instanceof ContainerApplicationInterface |
|
? $this->app->getContainer() |
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, Router::getRequest() ?? $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($cakephpRoot . '/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