![]() |
Custom page login issue
Ive created custom page that has login...
when I login it loads and when the loading is done, it still shows logged out, exept if I go to vBulletin page that is not custom made, then I'm logged in... when ever I go to my custom page then I'm back to logged out, but actually I'm logged in but showing logged out... My custom page is outaide vBulletin installation folder called "forum" |
If it's outside the /forum directory, then you probably need to move a bunch of required files to outside the /forum directory also. You should use a browser webmaster tool to see which files aren't being called by your script (assuming you used the tutorial in the vB4 Articles section to create the custom page).
|
I can never get it straight how error messages are controlled so in every project I build I put this at the top
Code:
ini_set('display_errors', 1); Then after your required files I would put in Code:
echo 'userid = ' . $vbulletin->userinfo['userid']; |
:eek: Ok, now I'm stuck there...
Code:
userid = Unable to add cookies, header already sent. |
Well, my echo line isn't working. I think it doesn't know your userid.
Try a plugin in "load_show_variables", and put that echo line in there and comment it out in your custom file. Try it just once and then turn off the plugin or it will echo that on every page. It should take just a few seconds |
I see header, navbar... everything, but still shows me as "not logged in" :) but actually I'm logged it.
|
If you don't see "userid = " above the regular page styling I suspect includes/class_bootstrap.php did not open a stream.
Does it show on other pages? If so turn off that plugin so it doesn't interfer with other pages |
on my custom page it says:
userid = 0 in normal vB4 pages userid = 1 |
OK, that means it thinks you are a guest. So apparently it isn't reading your cookies. I'm not sure where it's supposed to do that but I'll have a look
|
oky, thx, will wait
|
It could be the cookies aren't being sent. What do you have for Settings > Options > Cookies and HTTP Header Options > Path to Save Cookies? But if you're logging in from your custom page and the cookie path is wrong, I don't know how you'd be logged in on other forum pages.
|
Quote:
(from the dropdown menu) should I do something in "Custom Setting" my custom page has no directory/folder |
You could try choosing '/' from the dropdown menu, as long as you aren't running 2 forums from the same domain name.
|
Quote:
happy face now :) |
Well, so far I've found it's supposed to read your userid cookie on line 647 of includes/init.php. From there it should get all your userinfo.
I don't know how to test if it's got a problem reading the cookie |
All times are GMT. The time now is 06:40 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|