Welcome Guest, Not a member yet? Register   Sign In
redirect controller
#1

Hi all i install the codeigniter on subfolder .. like
http://www.site.com/subfolder
its load my the main controller good (its login page).
after i do the login good the redirect try now from the main domain and not from the subfolder..
Code:
RewriteEngine On
# Please do-not forget to change RewriteBase /cms
RewriteBase /cms

RewriteRule ^$ /cms/index.php [L]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond $1 !^(index\.php|robots\.txt|favicon\.ico)

RewriteRule ^(.*)$ /cms/index.php?/$1 [L]
</IfModule>

after i try to login this redirect me to http://www.site.com/contrroler
and its need to be http://www.site.com/cms/contrroler

but the main page load good http://www.site.com/cms/
also i did base_url in config
Reply
#2

Showing your code might help other people to understand your situation.

How did you config `base_url`?
And what's your controller code like?
Reply
#3

the config is $config['base_url'] = 'www.agri-da.com/cms/';
if you will login to this page you will see login page .. if you will try to login its will redirect you but from the main .. for example :
after the login on the cms folder its need to be dashboard. so the url need to be www.agri-da.com/cms/dashboard
i see www.agri-da.com/dashboard


what can i do ?
Reply
#4

You would have to look in your login controller, there you will probably find a redirect action that is performed after the login was successfully.If you post some relevant code we can help you a bit more.
Reply
#5

`base_url` should be `http://www.agri-da.com/cms/`.

And what's the real HTTP header look like?
Reply




Theme © iAndrew 2016 - Forum software by © MyBB