S
Superman859
Guest
I have one problem that hopefully isn't too difficult to solve. PEAR::Mail will work for me in http but not in https.
To get it to work in http, I had to add
to vhost.conf, as well as modifying the include_path in /etc/php.ini to include /usr/share/pear. It seemed to fix the problem, until I tried using it under https.
I have the domain setup to use a single directory for both HTTP and HTTPS (one of the settings under the SETUP tab for the domain - makes updating a lot easier), and I was under the assumption it would work fine. So far, https has worked fine until I added an include of "Mail.php" to them.
I have a feeling this is related to the vhost.conf somehow, although the error in the log is not the same as it was when first setting up PEAR to work in httpdocs. I used to get failed to open, and I added /usr/share/pear to include_path in php.ini for the server. Then I got open_basedir restriction errors, so I had to modify vhost.conf with the code posted above. Then it worked.
Now, http works, but when accessing a page via https, it provides
[phpBB Debug] PHP Notice: in file /var/www/vhosts/domain.net/httpdocs/adm/common.php on line 12: require_once(Mail.php) [function.require-once]: failed to open stream: No such file or directory
This is similar to the error I was getting the first time around with http, before modifying php.ini. However, looking at the log,
PHP Fatal error: require_once() [<a href='function.require'>function.require</a>]: Failed opening required 'Mail.php' (include_path='.:/usr/share/pear') in /var/www/vhosts/domain.net/httpdocs/adm/common.php on line 12, referer: https://www.domain.net/dir/index.php
The include path does indeed include /usr/share/pear, so the cause of the problem doesn't seem to be the same.
Does anyone know what the issue is and how to fix it?
To get it to work in http, I had to add
<Directory /var/www/vhosts/domain.net/httpdocs>
php_admin_value open_basedir "/var/www/vhosts/domain.net/httpdocs:/tmp:/usr/share/pear"
</Directory>
to vhost.conf, as well as modifying the include_path in /etc/php.ini to include /usr/share/pear. It seemed to fix the problem, until I tried using it under https.
I have the domain setup to use a single directory for both HTTP and HTTPS (one of the settings under the SETUP tab for the domain - makes updating a lot easier), and I was under the assumption it would work fine. So far, https has worked fine until I added an include of "Mail.php" to them.
I have a feeling this is related to the vhost.conf somehow, although the error in the log is not the same as it was when first setting up PEAR to work in httpdocs. I used to get failed to open, and I added /usr/share/pear to include_path in php.ini for the server. Then I got open_basedir restriction errors, so I had to modify vhost.conf with the code posted above. Then it worked.
Now, http works, but when accessing a page via https, it provides
[phpBB Debug] PHP Notice: in file /var/www/vhosts/domain.net/httpdocs/adm/common.php on line 12: require_once(Mail.php) [function.require-once]: failed to open stream: No such file or directory
This is similar to the error I was getting the first time around with http, before modifying php.ini. However, looking at the log,
PHP Fatal error: require_once() [<a href='function.require'>function.require</a>]: Failed opening required 'Mail.php' (include_path='.:/usr/share/pear') in /var/www/vhosts/domain.net/httpdocs/adm/common.php on line 12, referer: https://www.domain.net/dir/index.php
The include path does indeed include /usr/share/pear, so the cause of the problem doesn't seem to be the same.
Does anyone know what the issue is and how to fix it?