I just installed ssl on my apache/centos server.

Php works fine over the regular http connection but when I try to reach php files over the https connection for some reason they do not get parsed and delivered directly as text files.

Below is the virtualhost section from my ssl.conf. I'm thinking this is where the problem should be since php does not work only over https.


# General setup for the virtual host, inherited from global configuration
DocumentRoot "/var/www/vhosts/default/httpsdocs"
ServerName www.testserver.com:443
AddType application/x-httpd-php .php
AddHandler php5-script .php
AddType text/html .php
# Use separate log files for the SSL virtual host; note that LogLevel
# is not inherited from httpd.conf.
ErrorLog logs/ssl_error_log
TransferLog logs/ssl_access_log
LogLevel warn

#   SSL Engine Switch:
#   Enable/Disable SSL for this virtual host.
SSLEngine on

Let me know if you have any ideas.

8 Years
Discussion Span
Last Post by halukakin

The problem was somehow with Plesk. This dedicated server came with plesk pre-installed. I never used it so far but it turns out it was overriding my ssl.conf somehow.

So the solution was creating my domain under plesk. Moving all files to the new directory created by plesk. Embedding my ssl certificate to plesk and associating the certificate with the domain.


I see, my server also has Plesk. The problem is that i want to use a self generated certificate but my hosting's control panel (1&1) doesn't have that option. It only allows me to generate a CA trusted certificate and then proceed with the rest of the configuration and i don't want to generate it yet.

I'll ask 1&1 support guys and if i find a solution, post it.

Thank you for your quick reply


Just for your information. I'm on 1&1 too. But I'm using the SSL certificate they provide for the dedicated server account over GeoTrust.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.