0

404 error occurred after login into the forum though pages are there

Wednesday, November 7, 2007

After login into the forum (phpBB), you will get an error message 404 (page not found though page
s are there.

This issue mainly occurring due to the https redirection instead of http.

Replace the following code in the profile.php, privmsg.php and includes/functions.php
$server_protocol = ( $board_config['cookie_secure'] ) ? 'https://' : 'http://';

with
$server_protocol = ( $board_config['cookie_secure'] ) ? 'http://' : 'http://';

Don't forget to replace the includes/bbcode.php
$text = preg_replace("#\[img\]((http|ftp|https|ftps)://)([^ \?&=\#\"\n\r\t<]*?(\.(jpg|jpeg|gif|pn
g)))\[/img\]#sie","'[img:$uid]\\1' . str_replace(' ', '%20', '\\3') . '[/img:$uid]'", $text);

with
$text = preg_replace("#\[img\]((http|ftp|http|ftps)://)([^ \?&=\#\"\n\r\t<]*?(\.(jpg|jpeg|gif|png
)))\[/img\]#sie","'[img:$uid]\\1' . str_replace(' ', '%20', '\\3') . '[/img:$uid]'", $text);

This will fix the issue.

0 Responses to "404 error occurred after login into the forum though pages are there"