SimplePortal

Support => Install and Upgrade => Topic started by: steiger on April 02, 2009, 02:22:19 PM

Title: Installed 2.2 on 1.1.8, getting errors
Post by: steiger on April 02, 2009, 02:22:19 PM
Hi,
I just installed 2.2 on my 1.1.8 installation as described. Uninstall 2.1, install 2.2.

Now I get the following error:

Fatal error: Cannot redeclare ssi_shutdown() (previously declared in D:\xampp\htdocs\smf\SSI.php:196) in D:\xampp\htdocs\smf\SSI.php on line 198

Here are lines 193-198 of SSI.php

// This shuts down the SSI and shows the footer.
function ssi_shutdown()
{
   if (!isset($_GET['ssi_function']) || $_GET['ssi_function'] != 'shutdown')
      template_footer();
}


The linenumbers in the error message do not fit the code. There is no declaration on 196 and no redefine on 198.


If I comment out the lines
   if (SMF != 'SSI')
      require_once($boarddir . '/SSI.php');

in SPortal1-1.php the portal starts as expected.


Interestingly enough I had a small test.php which just includes SSI.php and calls ssi_welcome(). I had the same error there. After moving the require_once('SSI.php') to the line after "<?php" it worked again.



Do you have any ideas what is happening?
Title: Re: Installed 2.2 on 1.1.8, getting errors
Post by: steiger on April 02, 2009, 05:03:29 PM
Problem solved.
Had require instead of require_once in one location in my header.php.
Don't know why this wasn't a problem before.
Title: Re: Installed 2.2 on 1.1.8, getting errors
Post by: [SiNaN] on April 03, 2009, 03:33:10 AM
Because now SimplePortal includes SSI.php before anything else does. I suggest always using require_once(), just in case.
Title: Re: Installed 2.2 on 1.1.8, getting errors
Post by: steiger on April 03, 2009, 05:13:26 AM
Because now SimplePortal includes SSI.php before anything else does. I suggest always using require_once(), just in case.
I normally do.
Don't know why not in this location.
SimplePortal 2.3.8 © 2008-2024, SimplePortal