Admin login using relative paths

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Post Reply
seitenwind
New Member
New Member
Posts: 9
Joined: Sun Apr 29, 2007 9:19 am

Admin login using relative paths

Post by seitenwind »

Hi, I'm managing a website that is hosted in a subdirectory ie www.myhost.net/cms, it can be accesed by a redirection from www.url.com.
I'm using these settings:

$config['root_url'] = '';
$config['root_path'] = '/is/htdocs/wpxxxxxxxx_GRAW4AWMNV/www/cms';
$config['admin_dir'] = 'admin';
$config['previews_path'] = '/is/htdocs/wpxxxxxxxx_GRAW4AWMNV/www/cms/tmp/cache';
$config['uploads_path'] = '/is/htdocs/wpxxxxxxxx_GRAW4AWMNV/www/cms/uploads';
$config['uploads_url'] = 'http://www.url.com/uploads';

So far it works fine, but when I try to enter www.url.com/admin I am redirected to www.myhost.net/admin wich should be www.myhost.net/cms/admin and even when I'm entering my data and press submit it directs me to www.myhost.net/admin/. Entering the url by hand (www.myhost.net/admin/index.php) after login in works fine.
Any ideas how to solve this?
Last edited by seitenwind on Thu Jun 07, 2007 9:50 am, edited 1 time in total.
cyberman

Re: Admin login using relative paths

Post by cyberman »

Please look at /admin/themes/default/login.php at line 12 - you will found
GetConfig(); echo $config['root_url'] . '/' . $config['admin_dir'] . '/'; ?>" />
As you can see you need only to define correct root url in config.php (cant see it in your example).

Otherwise there's maybe a fault in your redirect  ::) ...
seitenwind
New Member
New Member
Posts: 9
Joined: Sun Apr 29, 2007 9:19 am

Re: Admin login using relative paths

Post by seitenwind »

Maybe you are right with the redirect, because I have to leave $config['root_url'] = ''; blank, otherwise it's not working correctly...
Post Reply

Return to “CMSMS Core”