0
Fixed

PHP Error creating a project

BrianG 13 years ago updated by Ricardo 13 years ago 0

PHP Error

Cannot modify header information - headers already sent by (output started at /homepages/44/d353854819/htdocs/tonkapps/scrumrf/protected/messages/en/gui.php:1)

/homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/CHttpRequest.php(657)

645     /**646      * Redirects the browser to the specified URL.647      * @param string $url URL to be redirected to. If the URL is a relative one, the base URL of648      * the application will be inserted at the beginning.649      * @param boolean $terminate whether to terminate the current application650      * @param integer $statusCode the HTTP status code. Defaults to 302. See {@link http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html}651      * for details about HTTP status code. This parameter has been available since version 1.0.4.652      */653     public function redirect($url,$terminate=true,$statusCode=302)654     {655         if(strpos($url,'/')===0)656             $url=$this->getHostInfo().$url;657         header('Location: '.$url, true, $statusCode);658         if($terminate)659             Yii::app()->end();660     }661 662     /**663      * Returns the user preferred language.664      * The returned language ID will be canonicalized using {@link CLocale::getCanonicalID}.665      * This method returns false if the user does not have language preference.666      * @return string the user preferred language.667      */668     public function getPreferredLanguage()669     {

Stack Trace

#0
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/CHttpRequest.php(657): header("Location: http://www.scrumrf.com/project/1106", true, 302)
#1
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/CController.php(1005): CHttpRequest->redirect("/project/1106", true, 302)
#2
  /homepages/44/d353854819/htdocs/tonkapps/scrumrf/protected/controllers/ProjectController.php(112): CController->redirect(array("project/view", "id" => "1106"))
107                 if ($model->save()) {108                     $pusers = $_POST['users'];109                     $this->saveProjectUsers($model, $pusers);110                     $transaction->commit();111                     user()->setFlash('success', t('msg', 'project.save.ok'));112                     $this->redirect(array('project/view', 'id' => $model->project_id));113                 }114             } catch (Exception $e) {115                 yiilog($e, 'error');116                 $transaction->rollBack();117                 user()->setFlash('error', t('msg', 'project.save.error'));
#3
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/actions/CInlineAction.php(50): ProjectController->actionCreate()
#4
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/CController.php(300): CInlineAction->runWithParams(array())
#5
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/filters/CFilterChain.php(133): CController->runAction(CInlineAction)
#6
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/filters/CFilter.php(41): CFilterChain->run()
#7
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/filters/CFilterChain.php(130): CFilter->filter(CFilterChain)
#8
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/filters/CFilter.php(41): CFilterChain->run()
#9
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/CController.php(1122): CFilter->filter(CFilterChain)
#10
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/filters/CInlineFilter.php(59): CController->filterAccessControl(CFilterChain)
#11
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/filters/CFilterChain.php(130): CInlineFilter->filter(CFilterChain)
#12
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/CController.php(283): CFilterChain->run()
#13
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/CController.php(257): CController->runActionWithFilters(CInlineAction, array("accessControl", array("application.filters.YXssFilter", "clean" => "*", "tags" => "strict", "actions" => "all")))
#14
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/CWebApplication.php(328): CController->run("create")
#15
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/web/CWebApplication.php(121): CWebApplication->runController("project/create")
#16
+
  /homepages/44/d353854819/htdocs/tonkapps/yii/framework/base/CApplication.php(155): CWebApplication->processRequest()
#17
  /homepages/44/d353854819/htdocs/tonkapps/scrumrf/index.php(15): CApplication->run()
10 // specify how many levels of call stack should be shown in each log message11 defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3);12 13 require_once($globals);14 require_once($yii);15 Yii::createWebApplication($config)->run();
2011-11-30 21:30:55 Apache Yii Framework/1.1.7

Answer

Answer
Fixed
Hi Brian!
Try now to check if it works ok.
Thanks for your feedback!
Cheers!
Answer
Fixed
Hi Brian!
Try now to check if it works ok.
Thanks for your feedback!
Cheers!