Blog Image

How to configure the symfony project directory

Your symfony project derectory is “/var/www/html/sf_sandbox” so in the browser you can acess this by this URL : “http://localhost/sf_sandbox/web/frontend.php/”

So if you want to map the symfony project directoy to your web root directory ie i mean to say you just want to acess it my using the URL :”http://localhost/” then you have to add the below line in the httpd.conf file and then restart your apache server.After that you can directly acess the symfony project from localhost url.

<VirtualHost *:80>
ServerName http://localhost/
DocumentRoot “/var/www/html/sf_sandbox/web”
DirectoryIndex index.php
<Directory “/var/www/html/sf_sandbox/web”>
AllowOverride All
Allow from All
</Directory>
</VirtualHost>

Rest of the things will be handled by symfony itself.



Author: admin

Vinod Ram has been in Software Industry since 2006 and has experience of over 16 years in Software Development & Project Management domain specialised majorly in LAMP stack & Open Source Technology, building enterprise level Web based Application, Large Database driven and huge traffic Websites and Project Management. He loves to write information articles and blog to share his knowledge and experience with the outside world and help people to find solution for their problems.