I have a login link on the top of all pages - this points to mysite/member/login
Sometimes when I click this link and submit the login form, it redirects me back to mysite/index.php
So I echo'd Yii::app()->user->returnUrl; and it is actually being set to mysite/index.php
I haven't modified the login function in the controller - it is just the same default code.
This only happens when I directly access the login page - if the login page is displayed due to a redirect (if the requested page requires authentication) then it works as expected.
Basically what I want is if the login page is accessed directly, then it should redirect to the member panel - mysite/member.
Sometimes when I click this link and submit the login form, it redirects me back to mysite/index.php
So I echo'd Yii::app()->user->returnUrl; and it is actually being set to mysite/index.php
I haven't modified the login function in the controller - it is just the same default code.
This only happens when I directly access the login page - if the login page is displayed due to a redirect (if the requested page requires authentication) then it works as expected.
Basically what I want is if the login page is accessed directly, then it should redirect to the member panel - mysite/member.