Installing PEAR in Windows Server 2008, PLESK - php

I'm not one to normally reach out but I've found myself completely stumped by this one.
I have a new server and chose to go with Windows Server 2008 and Plesk. After importing my site, I find that my includes no longer work, coming up with this error message:
require_once(include/online_class.php) [function.require-once]: failed to open stream: Operation not permitted
Fatal error: require_once() [function.require]: Failed opening required 'include/online_class.php
I have disabled open_basedir to make sure that it isn't conflicting but I am still getting this message. I have tried doing a fresh install of PEAR via command line and have made sure include_path points to the correct directory -> C:\Program Files (x86)\Parallels\Plesk\Additional\PleskPHP5\PEAR
I have switched between both PHP 5.2 and 5.3 - 5.3 will just display a 500 error message without even reaching the php include errors.
Is there something I'm missing here? This is an issue I've never had with linux / cpanel builds and it's leaving a sour taste in my mouth with regards to Windows servers. What can I do to fix this problem?
Any help would be appreciated. Cheers!

Related

PHP fails on launch

I recently asked a question at Can't run PHP after a new installation of XAMPP but now I realise that I was wrongly blaming a new installation of XAMPP. I've now got the same problem on two computers with different versions of XAMPP, so the problem must be somewhere in my coding, but I can't find it.
XAMPP starts up OK with Apache and MySQL. But then running the simplest PHP script...
<?php echo "HELLO"; ?>
produces these error messages...
Warning: Unknown: failed to open stream: No such file or directory in Unknown on line 0
Fatal error: Unknown: Failed opening required 'F:/My Documents/OneDrive/Webs/htdocs/phpinfo.php' (include_path='.;C:/xampp/php/pear/PEAR') in Unknown on line 0
That path to PEAR is specified in php.ini and it DOES exist. I can change php.ini to show any include_path and it doesn't matter whether it exists or not, the same error message appears (showing whatever include_path I have put in).
Even phpinfo.php will not run, as shown in the above example, although phpMyAdmin runs OK.
I'm now convinced that my two XAMPP installations on two computers cannot be causing this, but the error messages are not helping me find the problem. I now have to develop code on remote hosts to get around this problem. Can anyone help?
Many thanks!

require(): Failed opening required php file

Recently, I formated my whole computer, and installed Windows 7 64-bit. Before doing that I saved all of my files on an external hard drive. One of the things I backed up was a PHP script which uses AWS DynamoDB Services.
Before I formated my computer, everything went perfect. After I formated it, I installed on it XAMPP, Visual Studio Code, and PHP 7.1.1 through Microsoft WebPI.
Currently when I'm trying to run my PHP script I get this error on my screen:
Warning: require(/zip/aws/aws-autoloader.php): failed to open stream: No such file or directory in D:\Users\Lenovo\xampp\htdocs\public_html\file.php on line 7
Fatal error: require(): Failed opening required '/zip/aws/aws-autoloader.php'(include_path='D:\Users\Lenovo\xampp\php\PEAR') in D:\Users\Lenovo\xampp\public_html\file.php on line 7
I'm calling the autoloader this way:
require '/zip/aws/aws-autoloader.php';
I'm trying to understand if I forgot to install another thing, or if it's something related to the system (I had Windows 10 before)...
Could you please help me figure it out? I'm pretty new to this topic of PHP...
You should specify the entire path, like this: require __DIR__ . '/zip/aws/aws-autoloader.php';

Fatal Error while setting up site on local

I have Drupal 7 Site. I am setting up a remote site on my local.
While setting up the site, getting the following error from Apache
Fatal error: require_once(): Failed opening required
'C:\wamp\www\mySite\mySite-website\usr\share\drupal7/sites/all/modules/isotope/plugins/export_ui/isotope_ctools_export_ui.inc'
(include_path='.;C:\wamp\bin\php\php5.5.12\PEAR') in
C:\wamp\www\mySite\mySite-website\usr\share\drupal7\sites\all\modules\ctools\includes\plugins.inc
on line 477-
I am definitely not an expert of Apache. I also tried navigating to a test.html page I placed in common/configs/ so I assume there are no rights issues going on.
PEAR is successfully installed.
Not sure what to do at this point
Any help highly appreciated.

Warning: require(./wp-blog-header.php) [function.require]: failed to open stream: No such file or directory in ......?

I moved wordpress from one server to other...home page is running fine but when I click to category pages/links it shows these errors
Warning: require(./wp-blog-header.php) [function.require]: failed to open stream: No such file or directory in /home/server/public_html/index.php on line 17
Warning: require(./wp-blog-header.php) [function.require]: failed to open stream: No such file or directory in /home/server/public_html/index.php on line 17
Fatal error: require() [function.require]: Failed opening required './wp-blog-header.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/server/public_html/index.php on line 17
I searched on google and tried accordingly but not solved. I tried wp-codex tech like http://codex.wordpress.org/Changing_The_Site_URL but also failed. I have the wp-blog-header file in my directory but still not working....any help ...thanx in advance
Change php version for 7. My tech.support make this and problem was done
I had a similar issue and the problem was with the PHP version used which in my case by default was PHP 5.2 and it was throwing the 500 status code error.
When upgrading the PHP version to 5.3 the 500 status code was gone but Wordpress returned this error:
Your server is running PHP version 5.3.29 but WordPress 5.4.2 requires at least 5.6.20.
Note to myself (and everyone else with this error): When moving Wordpress websites between different servers make sure you are running the minimum required PHP version.
Also remember:
Note: If you are in a legacy environment where you only have older PHP or MySQL versions, WordPress also works with PHP 5.6.20+ and MySQL 5.0+, but these versions have reached official End Of Life and as such may expose your site to security vulnerabilities.
According to WP docs the recommended PHP is version 7.3.
Try the default theme and see if you still have the error. If so the theme you are using is causing the error - as in my case. The page that had an error was calling a file in "pages" that was not there. When I changed what is to show on that page to something current - the error went

Joomla 3 is giving error after changing hosting company

I have developed new website in Joomla 3 and now want to transfer it to new hosting and domain.
I have copied all files and directories and created databases. Also changed configuration file.
The problem is that new hosting company runs PHP 5.2.17 version and I removed this string in index.php where it is checking for php version.
After that I have strange error
Warning: require_once(__DIR__/includes/defines.php) [function.require-once]: failed to open stream: No such file or directory in /usr/.../public_html/index.php on line 28
Fatal error: require_once() [function.require]: Failed opening required '__DIR__/includes/defines.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /usr/.../public_html/index.php on line 28
How can I fix it? Thanks in advance. I can not use php.ini and changing hosting company is big problem.
Minimum requirement of PHP version is PHP 5.3 for Joomla 3. So you should upgrade your PHP version otherwise use Joomla 2.5
You may get other issues also, if you use Joomla 3 on PHP 5.2. To fix this issue you need to replace __DIR__ with dirname(__FILE__)
The version check isn't just for show. Requirements for Joomla 3.* is PHP 5.3.1 or higher.
Even if you fix what bugs you find now, you will definitely encounter problems later if you do not upgrade the PHP version.
Just to get an idea of how ugly things can get - check the PHP changelog. There are a lot of changes in 5.3.0 and 5.3.1, and any of them can cause unexpected behavior.

Categories