DragonPrime - LoGD Resource Community
Welcome Guest
  • Good evening, Guest.
    Please log in, or register.
  • August 30, 2016, 09:18:00 PM
Home Forums News Links Downloads Login Register Advanced Search
* * *
DragonPrime Menu
Login
 
 
Resource Pages
IRC Channels
Search

Pages: [1]   Go Down
  Print  
Author Topic: Bad link in pvplist  (Read 2028 times)
0 Members and 1 Guest are viewing this topic.
ratbastid
Guest
« on: December 27, 2005, 07:53:02 PM »

My pvplist is linking to /lotgd/php.cgi?act=attack... on the "attack" button in the list of potential pvp targets.

I followed that list to lib/pvplist.php, where I found (on line 16):

Code:
if ($link===false) {
  $link = basename($_SERVER['SCRIPT_NAME']);
}

I changed that to:
Code:
if ($link===false) {
  $link = basename($_SERVER['SCRIPT_URI']);
}
... which solved the problem.

Is there any unforseen side-effect of this? Is this just a necessity of how PHP happens to be configured on my server?
Logged
Talisman
Administrator
Mod God
*****
Offline Offline

Posts: 5462



View Profile WWW
« Reply #1 on: December 27, 2005, 08:30:42 PM »

More likely a side effect of how php is configured on your server - that being, in cgi mode.  Running LoGD under php in cgi mode does cause such issues and is not recommended!
Logged

Play the latest beta version here on DragonPrime
ratbastid
Guest
« Reply #2 on: December 31, 2005, 08:32:33 AM »

Is there anywhere else this is likely to bite me?

Actually, now that I think of it, the email validation was failing because the URL that was going out was to /cgi-bin/php.cgi, which was obviously bogus. I maybe hack that code too, and turn validation back on...  Hmmmm....

Okay, fine. Where else is this known to show up? Should I just search the code for $_SERVER['SCRIPT_NAME'] and see what turns up?

It'd be nice to change to the DSO version of PHP, but I don't have that much control over this environment. Sad
Logged
Talisman
Administrator
Mod God
*****
Offline Offline

Posts: 5462



View Profile WWW
« Reply #3 on: December 31, 2005, 12:17:26 PM »

Have you asked your host to make the switch?
Logged

Play the latest beta version here on DragonPrime
ratbastid
Guest
« Reply #4 on: January 01, 2006, 08:25:00 PM »

Oh, it's not going to happen. This is a tiny fish in a big pond. Larger account types can do DSO PHP, but the account I'm using doesn't have that kind of flexibility. They're configured the way they're configured, and that's about it.
Logged
Talisman
Administrator
Mod God
*****
Offline Offline

Posts: 5462



View Profile WWW
« Reply #5 on: January 01, 2006, 09:39:42 PM »

Hope it's a freebie then.  Otherwise I'd be looking for a new host.
Logged

Play the latest beta version here on DragonPrime
Pages: [1]   Go Up
  Print  
 
Jump to:  


*
DragonPrime Notices
Please take the time to read the FAQ and browse the DragonPedia

Support Us
No funds raised yet this year
Your help is greatly appreciated!
Who's Online
18 Guests, 0 Users
DragonPrime LoGD
Recent Topics
Home Forums News Links Downloads Login Register Advanced Search