render in div


I’ve implemented a Login for my website and for this also a logoutbutton, everything works fine except the redirect. There a some sites unlogged persons shouldn’t see so I’d like to implement a redirect to the index.php when the User logs out. This also works a kind of… well when it redirects (I’ve also tried to render the site again) it shows the site where the user pushes the logoutbutton and the index.php in the same site. Firebug says that index.php is shown in the so called header div box (where the logoutbutton is) and the origin site is shown normal. The source code says that there is no second website or code of the index.php. This happens in every browser.

public function actionLogout() {

      Yii::app()->xml->login(1, Yii::app()->user->id);




Why does this happen? Can anybody help me and give me a tip whats wrong?

Maybe you are doing some strange ajax logout?

Yes you are right… used a colleagues code and there is ajax. Thanks for the tip. Have a nice day :)