Loading...
 
Skip to main content

Custom Share Module 0.1dev

Features / Usability

Features / Usability


Logout problem with Firefox 3 and localhost

posts: 9

I have installed tikiwiki on my desktop. When I try to log out, I get an error display as follows:

Firefox can't find the server at localhost\.

The url for the page is given as http://localhost\/tiki-index.php
Note the \/ after localhost.

If I try this with IE 7, I get my homepage. The url is shown as:

http://localhost//tiki-index.php
Note the // after localhost.

If I log in to tikiwiki.org and then log out, there is a single / after tikiwiki.org.

Seems there is some problem with tiki-logout.php that is shipped in tikiwiki 2.2.
I don't know PHP, so I can't determine the problem. Help would be greatly appreciated.

By the way, this occurs with a fresh install of tikiwiki 2.2; that is, before I have made any changes whatsoever.

posts: 9

I have been doing a bit of debugging on this, at least all the debugging that my lack of PHP knowledge allows.

The problem is with the variable $base_url. There is a comment in changelog.txt that it is set in tiki-setup.php. The only reference in that file is:

Image
Copy to clipboard
$smarty->assign('base_url', $base_url);


Since the Search facility in Windows XP does not seem to find anything in any PHP file, I am unable to pursue this further.


posts: 13

Hi Everybody

For my part, I just add the code : $base_url = '/'; in the file "tiki-logout.php".

Image
Copy to clipboard
// RFC 2616 defines that the 'Location' HTTP headerconsists of an absolute URI if ( ! eregi('^https?\:', $url) ) { $base_url = '/'; $url = ( ereg('^/', $url) ? $url_scheme.'://'.$url_host.(($url_port!='')?":$url_port":'') : $base_url ).$url; }


Have a nice day

posts: 9
Thanks for this. I had eventually done something similar, although your solution is more general.
posts: 26 United States
Are you having issues with $base_url in other places? I certainly am...