renathy
(Renate Vidruska)
July 1, 2012, 4:24pm
1
Hi!
I have backend and frontend in seperate folders.
I have installed user module.
Currently, when I am on my backend and click logout, it goes to www.mypage.com/backend/user/login
Login form is put into backend layout.
Instead I want it to go to www.mypage.com/user/login that is my frontend.
Afterwards I want to redirect admin users to backend.
kiran123
(Sharmakiran71)
July 1, 2012, 5:52pm
2
you can update actionLogout method in your controller and redirect page whenever you want,
generally it found in SiteController.
outrage
(Site Sense Web)
July 2, 2012, 2:26am
3
Look in your controller where the login and logout actions are.
Search for lines similar to this:
$this->redirect(Yii::app()->homeUrl);
or maybe
$this->redirect(Yii::app()->user->returnUrl);
Change the line to redirect to the url of your choice.
Jedyny
(Lando20)
September 27, 2012, 9:07pm
4
Hey guys. Sorry if this will be newbie question but I really need your help.
I separate my application for frontend and backend, using this approach http://www.yiiframework.com/wiki/63/organize-directories-for-applications-with-front-end-and-back-end-using-webapplicationend-behavior/ .
Application has a shop module (after few tweaks) and yum module (http://www.yiiframework.com/extension/yii-user-management/ ) (I also tried with user module - http://www.yiiframework.com/extension/yii-user )
The problem I have is that despite I’m logged in the backend the page shows that I’m not logged in.
Such problem does not exist on the frontend.
Why I know that I’m logged in - when I click on Login link in the backend it redirect my to my “admin” user profile, also $_SESSION has all information about admin user.
Any hint/tip? I’m out of ideas.