cfranco80
By:
cfranco80

How to configure PHP in Virtual Host?

October 12, 2013 1.6k views
I've installed the virtual host on my server and is working. mydomain.com is working perfectly, but, my problem is when I try in mydomain.com/info.php this is no work. if Itry with php: This not work. So . . . I need configure the PHP in my virtual host, someone has a solution for this?
3 Answers
Simply follow the steps outlined in either the LEMP or LAMP stack tutorials.
Hi Pablo!

Thank you for your prompt response.

I installed LAMP previously was running PHP, but stopped working when installing virtual host.
Do you know how to configure virtual host in php? something like this:



php_admin_flag engine on
php_admin_flag safe_mode on
php_admin_value open_basedir "/var/www/vhosts/vhost.com/httpsdocs:/tmp"


php_admin_flag engine on
php_admin_flag safe_mode on
php_admin_value open_basedir "/var/www/vhosts/vhost.com/httpsdocs:/tmp"



where I put it? which is the path that handles digital ocean?

by Etel Sverdlov
This tutorial shows you how to set up a new directory, how to grant the correct permissions, how to add content to a new page, how to turn on virtual hosting, and how to, if needed, set up local hosts. Virtual Hosts are used to run more than one domain off of a single IP address and allows you to run multiple sites off of a single DigitalOcean droplet. This tutorial describes how to set up virtual hosts with Apache.
Have another answer? Share your knowledge.