Login problem with new user
Posted by mohitjain
Login problem with new user September 28, 2010 09:36AM |
Registered: 14 years ago Posts: 9 |
When the new user registers and then try to login, it goes to blank list.php page. How ever when the click the forum botton, they see they are logged in. This only happens when first time they try to login. After that it is fine. For old user it is not a problem. No error only warnings. Please see below for one of the warning:
Message:
PHP warning: Cannot modify header information - headers already sent by (output started at /var/www/vhosts/example.com/httpdocs/phorum-5.2.15a/list.php:155)
PHP warning generated at /var/www/vhosts/example.com/httpdocs/phorum-5.2.15a/include/api/user.php:2149
Back trace:
Function setcookie called at
{path to Phorum}/include/api/user.php:2149
----
Function phorum_api_user_session_create called at
{path to Phorum}/include/api/user.php:2540
----
Function phorum_api_user_session_restore called at
{path to Phorum}/common.php:594
----
Function include_once called at
{path to Phorum}/list.php:175
----
Request info:
HTTP_HOST = example.com
HTTP_REFERER = example/phorum-5.2.15a/login.php
REQUEST_URI = /phorum-5.2.15a/list.php
Message:
PHP warning: Cannot modify header information - headers already sent by (output started at /var/www/vhosts/example.com/httpdocs/phorum-5.2.15a/list.php:155)
PHP warning generated at /var/www/vhosts/example.com/httpdocs/phorum-5.2.15a/include/api/user.php:2149
Back trace:
Function setcookie called at
{path to Phorum}/include/api/user.php:2149
----
Function phorum_api_user_session_create called at
{path to Phorum}/include/api/user.php:2540
----
Function phorum_api_user_session_restore called at
{path to Phorum}/common.php:594
----
Function include_once called at
{path to Phorum}/list.php:175
----
Request info:
HTTP_HOST = example.com
HTTP_REFERER = example/phorum-5.2.15a/login.php
REQUEST_URI = /phorum-5.2.15a/list.php
Re: Login problem with new user September 28, 2010 02:07PM |
Admin Registered: 22 years ago Posts: 9,240 |
Re: Login problem with new user September 29, 2010 12:33AM |
Registered: 14 years ago Posts: 9 |
September 29, 2010 03:06AM |
Admin Registered: 20 years ago Posts: 8,532 |
Line 155 of list.php in 5.2.15 should not have outputted any data. Not being able to login with a white screen sounds familiar though. That normally happens when the PHP version that is used is not PHP5. Please check if your server uses PHP5.
If that does not lead you anywhere, then please tell us what code is in your list.php at line 155.
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauce
If that does not lead you anywhere, then please tell us what code is in your list.php at line 155.
Maurice Makaay
Phorum Development Team



Re: Login problem with new user September 30, 2010 12:15AM |
Registered: 14 years ago Posts: 9 |
Thanks for the reply Maurice. Yes I am using php 5. I tried one more time reloading the original. Now it give warning at list.php:166, where the command is following:
Line 166: if($page>1){
$prevpage=$page-1;
$PHORUM["DATA"]["URL"]["PREVPAGE"]=str_replace(array('%forum_id%','%page_num%'),array($PHORUM["forum_id"],$prevpage),$list_page_url_template);
}
Note this happens only first time user login, after creating an account, later it is fine. Also the URL which it redirects to is following:
example.com/phorum-5.2.15a/list.php
and when I type "?2" in front of it, like:
example.com/phorum-5.2.15a/list.php?2
I can see the normal page with user logged in
I have PM you the site link also if you want to see it in action
Thanks in advance
Following is the error:
PHP warning: Cannot modify header information - headers already sent by (output started at /var/www/vhosts/example.com/httpdocs/phorum-5.2.15a/list.php:166)
PHP warning generated at /var/www/vhosts/example.com/httpdocs/phorum-5.2.15a/include/api/user.php:2149
Back trace:
Function setcookie called at
{path to Phorum}/include/api/user.php:2149
----
Function phorum_api_user_session_create called at
{path to Phorum}/include/api/user.php:2540
----
Function phorum_api_user_session_restore called at
{path to Phorum}/common.php:594
----
Function include_once called at
{path to Phorum}/list.php:186
----
Request info:
HTTP_HOST = example.com
HTTP_REFERER = [example.com]
REQUEST_URI = /phorum-5.2.15a/list.php
Line 166: if($page>1){
$prevpage=$page-1;
$PHORUM["DATA"]["URL"]["PREVPAGE"]=str_replace(array('%forum_id%','%page_num%'),array($PHORUM["forum_id"],$prevpage),$list_page_url_template);
}
Note this happens only first time user login, after creating an account, later it is fine. Also the URL which it redirects to is following:
example.com/phorum-5.2.15a/list.php
and when I type "?2" in front of it, like:
example.com/phorum-5.2.15a/list.php?2
I can see the normal page with user logged in
I have PM you the site link also if you want to see it in action
Thanks in advance
Following is the error:
PHP warning: Cannot modify header information - headers already sent by (output started at /var/www/vhosts/example.com/httpdocs/phorum-5.2.15a/list.php:166)
PHP warning generated at /var/www/vhosts/example.com/httpdocs/phorum-5.2.15a/include/api/user.php:2149
Back trace:
Function setcookie called at
{path to Phorum}/include/api/user.php:2149
----
Function phorum_api_user_session_create called at
{path to Phorum}/include/api/user.php:2540
----
Function phorum_api_user_session_restore called at
{path to Phorum}/common.php:594
----
Function include_once called at
{path to Phorum}/list.php:186
----
Request info:
HTTP_HOST = example.com
HTTP_REFERER = [example.com]
REQUEST_URI = /phorum-5.2.15a/list.php
September 30, 2010 04:14AM |
Admin Registered: 20 years ago Posts: 8,532 |
That's not a white screen. That is a screen, showing only your header and footer and nothing where Phorum is supposed to show up. A really white screen is some PHP error. This is more likely a templating issue.
Did you put in your own site header unmodified in the header.tpl or did you take care of keeping the Phorum specific parts in there? Something that might be missing here, is the meta refresh code that is used for redirection. That list.php page should redirect to index.php.
Also check if you have the other required parts in there ({HEAD_TAGS}, javascript, stylesheets inside the <head> section).
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauce
Did you put in your own site header unmodified in the header.tpl or did you take care of keeping the Phorum specific parts in there? Something that might be missing here, is the meta refresh code that is used for redirection. That list.php page should redirect to index.php.
Also check if you have the other required parts in there ({HEAD_TAGS}, javascript, stylesheets inside the <head> section).
Maurice Makaay
Phorum Development Team



Re: Login problem with new user September 30, 2010 08:40AM |
Registered: 14 years ago Posts: 9 |
Re: Login problem with new user September 30, 2010 11:36PM |
Registered: 14 years ago Posts: 9 |
Re: Login problem with new user September 30, 2010 11:55PM |
Registered: 14 years ago Posts: 9 |
Sorry spoke too soon. It only works when the user has created account when they are in the forum , if they create account when they are on forum/index.php than it does not redirect to index.php when they try to login after creating an account. Again it happens only first time after creating an account
October 01, 2010 04:02AM |
Admin Registered: 20 years ago Posts: 8,532 |
Please, try and change the template to the default Emerald template in your default forum settings and try again. If that works, then we know that it's a templating issue.
The list.php script that already outputted data and two times at different line numbers is still very suspicious, but I really have no clue at all what could cause that.
Maurice Makaay
Phorum Development Team
my blog
linkedin profile
secret sauce
The list.php script that already outputted data and two times at different line numbers is still very suspicious, but I really have no clue at all what could cause that.
Maurice Makaay
Phorum Development Team



Sorry, only registered users may post in this forum.