Quantcast
Channel: Yii Framework Forum
Viewing all articles
Browse latest Browse all 18717

Cannot modify header information

$
0
0
Good Day!

I'm trying to saving the contents of my form, I'm using CJuiDialog and CActiveForm at the same time. There's is no problem in the form, the problem occurs when hitting the save button.

Here is the description of error returned by PHP:

Cannot modify header information - headers already sent by (output started at C:\xampp\htdocs\ADS\protected\controllers\CreditorDebtorController.php:73)

here is the stack trace:

     public function redirect($url,$terminate=true,$statusCode=302)
654     {
655         if(strpos($url,'/')===0)
656             $url=$this->getHostInfo().$url;
[color="#FF0000"]657         header('Location: '.$url, true, $statusCode);[/color]
658         if($terminate)
659             Yii::app()->end();
660     }



Stack Trace #2
C:\xampp\htdocs\ADS\protected\controllers\CreditorDebtorController.php(102): CController->redirect(array("view", "creditorId" => null))

097                                             //$this->redirect(array('view','id'=>$model->BOOK_UID)); // Redirect to another page.
098                                 exit;
099                             }
100                             else
101                             //print_r($_POST['CreditorDebtor']);    
[color="#FF0000"]102                             $this->redirect(array('view','creditorId'=>$model->creditorId));[/color]
103                         }
104                    
105                         //$this->renderPartial('_form',array('model'=>$model));
106                     }


Thank you very much guys.....

:D :D :D :D

Viewing all articles
Browse latest Browse all 18717

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>