Everything seems to be fine EXCEPT I can't configure my forum from the Admin Panel. Which means no Forum Creation....this will not do.
I get the returned Access Denied when logged in as Admin. [Even logged in as the God Account]
Now I had a similar problem before as you can see here.
I think it has something to do with me changing my admin.php file name, however I can't locate the check in the Forums module that is returning the error.
Any assistance would be greatly appreciated.
I'd like to have things up and running by this afternoon.
I am running 7.6 3.1 w/ 2.0.11 bbtonuke
[I know I need to upgrade, however I would like to identify and fix this problem first. I already upgraded from .10 to .11 and have had the same error]
gemini7 Nuke Soldier
Joined: Jan 24, 2006
Posts: 12
Posted:
Tue Feb 28, 2006 9:58 am
Well I've been looking at the code all morning and I think something like this
Code:
global $admin_file;
if (!eregi("".$admin_file.".php", $_SERVER['PHP_SELF'])) { die ("Access Denied"); }
adminmenu("".$admin_file.".php?op=forums", "Forums", "forums.gif");
found in Forum\admin\links.php is returning the access denied, but I have tried modifying it with no luck.
Any ideas on a possible solutions are greatly appreciated
I found someone who had a similar problem that discussion definitely leads me to believe that SOMEWHERE in the code of the forum the path is wrong. but where I have no idea....this is very frustrating
gemini7 Nuke Soldier
Joined: Jan 24, 2006
Posts: 12
Posted:
Tue Feb 28, 2006 12:56 pm
Okay I found it...
Line 31 of nuke_root\modules\Forums\admin\forums.php
Code:
if (!eregi("admin.php", $_SERVER['SCRIPT_NAME'])) { die ("Access Denied");
That needs to be:
Code:
if (!eregi("".$admin_file.".php", $_SERVER['PHP_SELF'])) { die ("Access Denied"); }
The problem stems from actually calling up admin.php instead of the variable $admin_file which can be set in config.php to the changed admin file name.
I do have a question though... what exactly is the different between $_SERVER['SCRIPT_NAME'] and $_SERVER['PHP_SELF'] I know both are used to check that the instruction is comming from the server itself, but if someone could elaborate on why one is better than the other or specifically what the differences are between ['SCRIPT_NAME'] and ['PHP_SELF]
Thanks
Evaders99 Site Admin
Joined: Aug 17, 2003
Posts: 12395
Posted:
Wed Mar 01, 2006 5:27 pm
If there's a signficant difference, I haven't found it yet. 'SCRIPT_NAME' is something defined for the HTTP standard, while 'PHP_SELF' is only used in PHP
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum