|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
Patchesyaf_response_http.patch (last revision 2018-04-11 12:05 UTC by fanjiapeng at 126 dot com)Pull RequestsHistoryAllCommentsChangesGit/SVN commits
[2021-09-09 10:36 UTC] cmb@php.net
|
|||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Thu Nov 06 20:00:02 2025 UTC |
Description: ------------ In some cases, the function is called in CLI mode. Although it does not work in CLI mode. Test script: --------------- <?php class IndexController extends Yaf_Controller_Abstract { public function indexAction() { Yaf_Dispatcher::getInstance()->disableView(); $a = $b; $response = new Yaf_Response_HTTP(); var_dump($response->setRedirect('https://yourdomain.com')); } } Expected result: ---------------- bool(false) Actual result: -------------- Notice: Undefined variable: b in /www/application/controllers/Index.php on line 8 Warning: Cannot modify header information - headers already sent by (output started at /www/application/controllers/Index.php:8) in /www/application/controllers/Index.php on line 11 bool(false)