Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Shop dead after PLESK / PHP changes


crockett

Recommended Posts

Posted

I'm getting plenty of these:

 

PHP Fatal error: require(): Failed opening required 'DIR_WS_INCLUDESheader.php'

 

Since we changed the subscription for the shop domain in PLESK. PLESK synchronized our hosting settings with the default values and that’s when we lost the working PHP settings for the shop.

 

This is a very old shop, we are about to upgrade but need the shop working for the import of customers and orders.

 

I tried all kinds of settings in the php.ini but I'm not getting back to the settings that just worked fine until yesterday.

 

This issue must be around the following settings I think:

 

- base dir
- php path
- sessions (not using sql, tmp folder is empty)
- shop needs register_long_arrays = On and register_globals = On

 

I’d really appreciate any help.

Posted
Dan Cole, on 17 Dec 2015 - 08:24, said:

@@crockett

 

DIR_WS_INCLUDES is defined in your configuration files....includes/configuration.php so have a look and see why it's no longer defined.  

 

Dan

 

But nobody changed the files. The shop was running fine for many years. All that was changed was within PLESK. PLESK changed the Apache / PHP / path settings. That’s where the problem must be.

Posted

Go make a copy of the database and modify that for use in a new 2.3.4 BS site and forget about old site. If it is that old you will probably have to spend hours upon hours to get it to work again if you have not been keeping up with all the modifications for while. Depending on what you need on your site to take orders, you will be able to have a new working site up pretty quick with old database info in place.

Posted

@@MrPhil

 

Hi Phil,

 

Your PMs are full, so I'll try to tag you :)

 

You replied to a thread a while ago:

 

http://www.oscommerce.com/forums/topic/383962-error-after-host-changed-servers/

 

I have the exact same issue.

I really need some help with this. My hoster isn’t getting anywhere, same with my coder.

 

The shop was working fine yesterday. I’m 99% positive that PLESK changed Apache / base dir / PHP path / php.ini / something server side. So the fix needs to be within PLESK / server.

 

Can you help? I’m willing to pay.

 

Thanks,

 

Don
 

Posted

The first thing is to confirm that some hacker hasn't broken your PHP files (they still "include" the configure.php and other files), and the wanted files are still there in the right place. Then check your PHP include_path. Run the following script and search for include_path

<?php phpinfo(); ?>

and make sure it includes "." as one of the entries. If not, talk to your host about how to fix that (possibly a php.ini entry). You would need to either add . or some store paths to it.

Posted
MrPhil, on 17 Dec 2015 - 13:45, said:

The first thing is to confirm that some hacker hasn't broken your PHP files (they still "include" the configure.php and other files), and the wanted files are still there in the right place. Then check your PHP include_path. Run the following script and search for include_path

<?php phpinfo(); ?>

and make sure it includes "." as one of the entries. If not, talk to your host about how to fix that (possibly a php.ini entry). You would need to either add . or some store paths to it.

 

 

Thank you for looking into this Phil!

 

The config files are both in place and no files have been changed. All this happened after I changed the Domain subscription in PLESK. That’s when I lost the custom php.ini settings or something along the lines in Apache.

 

phpinfo

include_path .:/opt/plesk/php/5.3/share/pear .:/opt/plesk/php/5.3/share/pear

open_basedir no value no value (tried the entire path to tmp, no change)

 

What else can we try?

Posted
cornishpirate, on 18 Dec 2015 - 04:02, said:

Plesk can change the version of PHP.

 

Check which version you were using and which is now being used.

 

That must have been the issue. Now its PHP 5.4, was 5.3. No register globals anymore. Fuck PLESK and auto update.

 

Thanks.

Posted

Register globals have been deprecated for quite a while in PHP, since at least 5.0 I think. Only recently (5.5 or 5.6?) did they actually take away the ability to use register global variables.

 

If your version of osC is so old that it's using register globals, you've got a lot of editing ahead of you to not use register globals (e.g., add $catID = $_GET['catID']; instead of simply using $catID from the URL Query String). On top of that, you will probably have a lot of session issues and other PHP problems. Maybe this will be the thing to kick you into upgrading to 2.3.4 (install new code, migrate the database and images).

 

I'm not sure that the inability to include a file is related to register global variables, but it might be something else. I don't think the syntax has changed for includes, and your include_path appears to include ".", so at the moment I'm stumped. I have no experience with PLESK.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...