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

Hi all i install the codeigniter on subfolder .. like
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..

what i need to change this is my htaccess file
Code:
<IfModule mod_rewrite.c>
# CodeIgniter Subfolder .Htaccess
# today hints by www.insanen.com
Options +FollowSymLinks

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 www.site.com/contrroler
and its need to be www.site.com/cms/contrroler

but the main page load good www.site.com/cms/
Reply
#2

(01-16-2016, 09:46 AM)ofir Wrote: Hi all  i install the codeigniter on subfolder .. like
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..

what i need to change this is my htaccess file
Code:
<IfModule mod_rewrite.c>
# CodeIgniter Subfolder .Htaccess
# today hints by www.insanen.com
Options +FollowSymLinks

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 www.site.com/contrroler
and its need to be www.site.com/cms/contrroler

but the main page load good  www.site.com/cms/

Did you configure your base_url in config/config?
Reply
#3

yes i did it with the subfolder
Reply




Theme © iAndrew 2016 - Forum software by © MyBB