Problem with paths (huge redirect issues)
Problem with paths (huge redirect issues)
I'm having weird problems. My host has php safe_mode on so I'm not sure if that's causing problems (doubt it).
If I edit a news entry the system throws me back at the front page.
My site has a proper path in the config ini (www.domain.com) and the admin directory is also set. Still sometimes the admin interface returns to the basic path from certain operations (modify theme, edit news etc). For some reason the admin directory is just dropped from the url after the domain. If I try to login the system throws me back at the public frontpage. I have to login and then manually type the address to access the admin pages.
I just did a clean install of 1.1 but it didn't help. I've spent many evenings troubleshooting this but can't get it to work. Tried 1.05 and 1.08 also.
Please see the last post
If I edit a news entry the system throws me back at the front page.
My site has a proper path in the config ini (www.domain.com) and the admin directory is also set. Still sometimes the admin interface returns to the basic path from certain operations (modify theme, edit news etc). For some reason the admin directory is just dropped from the url after the domain. If I try to login the system throws me back at the public frontpage. I have to login and then manually type the address to access the admin pages.
I just did a clean install of 1.1 but it didn't help. I've spent many evenings troubleshooting this but can't get it to work. Tried 1.05 and 1.08 also.
Please see the last post
Last edited by Hare on Tue Jul 17, 2007 5:55 pm, edited 1 time in total.
Re: Problem with paths but config.php is ok?
Hello,
have you checked your config.php after moving ? paths there should be updated.
And have you cleared your cache after ? (sorry to ask this)
You can try to reinstall 1.0.8 without creating database tables&objects : you will have a fresh new working generated config.php that fits your new hosting place.
Pierre M.
have you checked your config.php after moving ? paths there should be updated.
And have you cleared your cache after ? (sorry to ask this)
You can try to reinstall 1.0.8 without creating database tables&objects : you will have a fresh new working generated config.php that fits your new hosting place.
Pierre M.
Re: Problem with paths but config.php is ok?
I have checked the config.php and actually installed the site on a new host from scratch. I installed it to a sub directory and after moving content with the backup module I moved the installation to public_html's root. At this point I removed all references to the temp directory where the installation originally was.Pierre M. wrote: Hello,
have you checked your config.php after moving ? paths there should be updated.
And have you cleared your cache after ? (sorry to ask this)
You can try to reinstall 1.0.8 without creating database tables&objects : you will have a fresh new working generated config.php that fits your new hosting place.
Pierre M.
I quess I have to try a reinstall...
Re: Problem with paths but config.php is ok?
If you have a working config.php (as you can log into the admin) and have cleared the cache, I don't understand what is wrong.
But you say problems occur "sometimes", not allways... may be a volume problem if you have lots of pages. or may be a silly module poluting your install.
Is there any difference in "sometimes" between the install in a subfolder and the install in the root ?
Pierre M.
But you say problems occur "sometimes", not allways... may be a volume problem if you have lots of pages. or may be a silly module poluting your install.
Is there any difference in "sometimes" between the install in a subfolder and the install in the root ?
Pierre M.
Re: Problem with paths but config.php is ok?
First of all. Sorry about my post. I was a bit vague.
Some things in the admin interface cause problems. I can edit pages without problems etc but if I edit a stylesheet or edit news entry i either get a blank "page not found" or I'm dropped from the admin pages to the frontpage of my site.
This happens when I log in. www.domain.com/admin -> type in my username and password and boom, I'm back at the public frontpage. If I then type www.domain.com/admin again I can see the admin interface. I don't think there's anything wrong with my config.php as most stuff works just fine but some things are broken (news editing, stylesheet editing, template editing etc). I've now double checked the config.php and can't see anything wrong with it.
Could this be a problem with safe_mode ? I personally doubt it.
Some things in the admin interface cause problems. I can edit pages without problems etc but if I edit a stylesheet or edit news entry i either get a blank "page not found" or I'm dropped from the admin pages to the frontpage of my site.
This happens when I log in. www.domain.com/admin -> type in my username and password and boom, I'm back at the public frontpage. If I then type www.domain.com/admin again I can see the admin interface. I don't think there's anything wrong with my config.php as most stuff works just fine but some things are broken (news editing, stylesheet editing, template editing etc). I've now double checked the config.php and can't see anything wrong with it.
Could this be a problem with safe_mode ? I personally doubt it.
Last edited by Hare on Sat Jun 30, 2007 3:03 pm, edited 1 time in total.
Re: Problem with paths but config.php is ok?
I don't know if it is safe mode related. May be safe mode, may be volume, may be buggy module.
If only some things (allways the same) are broken and others things go well, some parts of the software may be corrupted. As you have said, you can try to reinstall (overwrite) with a fresh reuploaded CMSms standard distribution without creating the database tables&objects to keep you database content.
Pierre M.
If only some things (allways the same) are broken and others things go well, some parts of the software may be corrupted. As you have said, you can try to reinstall (overwrite) with a fresh reuploaded CMSms standard distribution without creating the database tables&objects to keep you database content.
Pierre M.
Re: Problem with paths but config.php is ok?
Ok. I just did a reinstall and it didn't help. Tried to clear cache, no help.
I also deleted cmsms files and uploaded them again, no help.
During installation there are three yellow "lights"
______________
X Checking if session.save_path is writable
Your session.save_path is "/tmp". Not having this as writable may make logins to the Admin Panel not work. You may want to look into making this path writable if you have trouble logging into the Admin Panel. This test may fail if safe_mode is enabled (see below).
X Checking if ini_set works
Although the ability to override php ini settings is not mandatory, some addon (optional) functionality uses ini_set to extend timeouts, and allow uploading of larger files, etc. You may have difficulty with some addon functionality without this capability. This test may fail if safe_mode is enabled (see below).
X Checking for Safe mode
PHP Safe mode could create some problems with uploading files and other functions. It all depends on how strict your server safe mode settings are.
____________
Anyway. The reinstall didn't help. If I look at the source in news edit window I can see that the path in the form action is the following:
but it doesn't return to www.domain.com/admin/moduleinterface.php after I press submit. It actually goes to my public frontpage and displays admin stuff etc over there. This is the address to be more specific:
http://www.domain.com/moduleinterface.p ... b=articles
As you can see, there's no "admin" directory after the domain name.
There's also an error displayd:
Fatal error: Call to a member function on a non-object in /data/webhotel/storage/sitename/data/modules/News/action.defaultadmin.php on line 99
Btw. This is what line 99 looks like in the mentioned file:
Even if I click sign out in the admin view I get a blank page because it can't locate www.domain.com/login.php file (again admin-part missing).
I also deleted cmsms files and uploaded them again, no help.
During installation there are three yellow "lights"
______________
X Checking if session.save_path is writable
Your session.save_path is "/tmp". Not having this as writable may make logins to the Admin Panel not work. You may want to look into making this path writable if you have trouble logging into the Admin Panel. This test may fail if safe_mode is enabled (see below).
X Checking if ini_set works
Although the ability to override php ini settings is not mandatory, some addon (optional) functionality uses ini_set to extend timeouts, and allow uploading of larger files, etc. You may have difficulty with some addon functionality without this capability. This test may fail if safe_mode is enabled (see below).
X Checking for Safe mode
PHP Safe mode could create some problems with uploading files and other functions. It all depends on how strict your server safe mode settings are.
____________
Anyway. The reinstall didn't help. If I look at the source in news edit window I can see that the path in the form action is the following:
Code: Select all
< form ... action="moduleinterface.php">
http://www.domain.com/moduleinterface.p ... b=articles
As you can see, there's no "admin" directory after the domain name.
There's also an error displayd:
Fatal error: Call to a member function on a non-object in /data/webhotel/storage/sitename/data/modules/News/action.defaultadmin.php on line 99
Btw. This is what line 99 looks like in the mentioned file:
Code: Select all
$onerow->editlink = $this->CreateLink($id, 'editarticle', $returnid, $gCms->variables['admintheme']->DisplayImage('icons/system/edit.gif', $this->Lang('edit'),'','','systemicon'), array('articleid'=>$row['news_id']));
Last edited by Hare on Sat Jun 30, 2007 8:59 pm, edited 1 time in total.
Re: Problem with paths but config.php is ok?
I just noticed that I can't even see the title in the browser windows when I'm looking at the admin pages. This happened also when I tried 1.05. I have no idea what's wrong. I quess I have to call the webhost.
Re: Problem with paths but config.php is ok?
EDIT: ok...
I just turned debuggin on. This is the redirect address after I press submit from a news edit view.
Redirecting disabled... Please click this link to continue.
http://www.domain.com/moduleinterface.p ... b=articles
The admin part is just skipped, why? Any ideas what's wrong?
Ok, I just did more debugging.
I echoed the redirect on the login page:
it comes out like this:
http://www.domain.com/testinstallation/admin/index.php
This is how it should be. BUT if I submit the login form I get bounced back to the www.domain.com url (frontpage). I have no idea why? Thoughts?
I did a quick test to see if my redirects work
No problems here, works just fine.
I just turned debuggin on. This is the redirect address after I press submit from a news edit view.
Redirecting disabled... Please click this link to continue.
http://www.domain.com/moduleinterface.p ... b=articles
The admin part is just skipped, why? Any ideas what's wrong?
Ok, I just did more debugging.
I echoed the redirect on the login page:
Code: Select all
echo ($gCms->config['root_url'].'/'.$config['admin_dir'].'/index.php');
http://www.domain.com/testinstallation/admin/index.php
This is how it should be. BUT if I submit the login form I get bounced back to the www.domain.com url (frontpage). I have no idea why? Thoughts?
I did a quick test to see if my redirects work
Code: Select all
<?php header('Location: http://www.google.com/') ;?>
Last edited by Hare on Sun Jul 01, 2007 4:35 pm, edited 1 time in total.
Re: Problem with paths but config.php is ok?
Could this be causing the problems? From phpinfo:
System: SunOS webserver1-7 5.9 Generic_112233-11 sun4u
I just can't get this working. I've tried 1.05, 1.08 and now 1.1. Nothing works, logging to the admin panel simply throws me to the public frontpage and modules behave badly.
Any ideas would be very much appreciated!
System: SunOS webserver1-7 5.9 Generic_112233-11 sun4u
I just can't get this working. I've tried 1.05, 1.08 and now 1.1. Nothing works, logging to the admin panel simply throws me to the public frontpage and modules behave badly.
Any ideas would be very much appreciated!
Last edited by Hare on Tue Jul 17, 2007 5:49 pm, edited 1 time in total.
Re: Problem with paths but config.php is ok?
There is something strange here, isn't it ?Hare wrote: Redirecting disabled...
CMSms installer (and admin console) needs redirects and it is disabled ?
I'm confused. You should ask you hosting provider.
Pierre M.
Re: Problem with paths (huge redirect issues)
if debug is on redirecting is disabled
this is just for the fact that you can see what happens on the intermediate page..
this is just for the fact that you can see what happens on the intermediate page..
Re: Problem with paths (huge redirect issues)
Hopefully my host will finally disable safe_mode quite soon. I'll update this topic once it's done. I'm hoping safe_mode is the root of these problems...
Re: Problem with paths (huge redirect issues)
Safe_mode is off and didn't do anything.
I'm still having massive problems. The installation is slow (processing time 2-5sec) even though the server should be fast. I can't login to admin pages because I get redirected to the public frontpage. I can manually enter the admin path in the browser to login so fortunately I can do some debugging. Modifying a news entry still redirects me out of the admin-pages etc.
Any ideas why. I'm getting desperate! I've cleared cache, did multiple reinstallations, checked the paths over and over again but it just won't work!
Could this be a problem with the host Sun ONE Web Server/6.1? phpinfo looks ok and if I try normal php path funtions they return the right values.
EDIT: Hmm... Somethings still wrong
I'm still having massive problems. The installation is slow (processing time 2-5sec) even though the server should be fast. I can't login to admin pages because I get redirected to the public frontpage. I can manually enter the admin path in the browser to login so fortunately I can do some debugging. Modifying a news entry still redirects me out of the admin-pages etc.
Any ideas why. I'm getting desperate! I've cleared cache, did multiple reinstallations, checked the paths over and over again but it just won't work!
Could this be a problem with the host Sun ONE Web Server/6.1? phpinfo looks ok and if I try normal php path funtions they return the right values.
EDIT: Hmm... Somethings still wrong
Is this a hosting issue? the tmp folder in the cmsms installation is writeable?Checking if session.save_path is writable
Your session.save_path is "/tmp". Not having this as writable may make logins to the Admin Panel not work. You may want to look into making this path writable if you have trouble logging into the Admin Panel. This test may fail if safe_mode is enabled (see below).
Last edited by Hare on Wed Aug 15, 2007 4:14 pm, edited 1 time in total.
Re: Problem with paths (huge redirect issues)
Well, Sun ONE Web Server is not supported today and you seem to have a problem at the PHP sessions level inside this webserver. Working PHP sessions are a requirement. Check your PHP tuning or switch to supported lightty or Apache.
Pierre M.
Pierre M.