1
Christien
ShortURLs 0.4a
  • 2007/2/17 1:22

  • Christien

  • Just popping in

  • Posts: 78

  • Since: 2004/11/15


Does this hack work with safe_mode on? If not, does it mean i can't use it? Are there other solutions, i cant find them!

Warning: putenv(): Safe Mode warning: Cannot set environment variable 'SCRIPT_FILENAME'

Thanks,

2
Sublime
Re: ShortURLs 0.4a
  • 2007/2/17 8:39

  • Sublime

  • Just popping in

  • Posts: 99

  • Since: 2006/5/23


First off let me say that I'm not entirely familiar with this module. It appearers though that you cut off a bit of the error...something like "- in /whatever.php on line ___" that may help someone solve your problem.

Basically your issue is that safe_mode is stopping putenv() from returning the environment variable SCRIPT_FILENAME (which returns the path of the script that calls it).

You MAY be able to work around this by adding SCRIPT_FILENAME to safe_mode_allowed_env_vars

safe_mode_allowed_env_vars PHP_,SCRIPT_FILENAME


in your php.ini, however I cant guarantee it as I have never had the need to run safe_mode. I must say though, it isn't the most secure way of doing it as it's pretty much defeating the purpose of safe_mode blocking all env variables other than PHP_ in the first place. However it may be a temporary fix for you until someone can provide you a better solution.

Login

Who's Online

171 user(s) are online (112 user(s) are browsing Support Forums)


Members: 0


Guests: 171


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits