Page 1 of 1

Errors after fresh install

Posted: Mon Sep 14, 2015 10:48 pm
by cbsarge
Argh.... finished the install and right after I received the following:

Can anyone offer any ideas on what might have gone wrong? I believe I have the option to drop back to older versions of PHP if that's a possible fix.

Code: Select all

Error: Undefined index: SERVER_ADDR
HINT: If you are accessing a GET or POST, make sure to use the isset function.

Error in "/hermes/bosnaweb03a/b2751/ipg.cbsargecom/VillainsandHeroes/libs/template.php"
Line 290
Error in /hermes/bosnaweb03a/b2751/ipg.cbsargecom/VillainsandHeroes/templates/public_art_medieval/main.php
Line 31
Error in /hermes/bosnaweb03a/b2751/ipg.cbsargecom/VillainsandHeroes/libs/template.php
Line 16
Error in /hermes/bosnaweb03a/b2751/ipg.cbsargecom/VillainsandHeroes/index.php
Line 387

Please help us to improve the game by providing as much information regards any bugs.

Step by step how to reproduce it:


ReportBack
Error: Directive 'register_long_arrays' is deprecated in PHP 5.3 and greater
Error in "Unknown"
Line 0

Please help us to improve the game by providing as much information regards any bugs.

Re: Errors after fresh install

Posted: Mon Sep 14, 2015 11:37 pm
by gmoore
Just looking at it quickly seems to be some change in PHP.

Might take me a couple days to jump on it.

Greg

Re: Errors after fresh install

Posted: Tue Sep 15, 2015 3:24 am
by KyleMassacre
Well what version are you using? On my dev box I use 5.6

Re: Errors after fresh install

Posted: Tue Sep 15, 2015 12:24 pm
by cbsarge
I'm using 5.3

It seems as if it's not able to use the $_SERVER['SERVER_ADDR'] object. I was able to get around it by modifying the VerifyIt() function in libs\template.php to the code below:

Code: Select all

function VerifyIt ()
{
    global $engineLicenseKey;
	$host= gethostname();
	$ip = gethostbyname($host);    
    echo "<a href='http://nwe.funmayhem.com/verify.php?l=" . substr($engineLicenseKey, 0, 10);
    echo "&sip=" . $ip . "' target='_blank'><img src='http://nwe.funmayhem.com/verify.php?image=button&l=";
    echo substr($engineLicenseKey, 0, 10) . "' border='0'></a>";
}
Does anyone know if my host not supporting $_SERVER['SERVER_ADDR'] might bite me anywhere else?

Re: Errors after fresh install

Posted: Tue Sep 15, 2015 12:25 pm
by cbsarge
Whoops! Spoke too soon. The page comes up but, when I try to log in I'm getting:

Code: Select all

Error: session_start(): open(/var/php_sessions/sess_7a41759674aa5d36e7f260d8e9f4a3f9, 

Re: Errors after fresh install

Posted: Tue Sep 15, 2015 12:29 pm
by KyleMassacre
That is a really weird error that you were getting. When I get home from work and if I remember I will take a couple minutes and load up 5.3 and see if I can get it to work

Re: Errors after fresh install

Posted: Tue Sep 15, 2015 1:20 pm
by cbsarge
ok, I think I've got that one fixed too. I have access to my php.ini file through the cpanel of my hosting company. I changed the path to where the session variable is located to include the full path as expressed in my earlier errors. It now is prefaced by the /hermes/bosnaweb03a/b2751/ipg.cbsargecom part and I'm in! :D