Msg#: 4252164 posted 12:47 am on Jan 12, 2011 (gmt 0)
I have a site that has been moved from one server to another. The directory structure on the new server is different, and rather than change hundreds of files I would like to try to set up an alias for DocumentRoot.
The path contained in my files is: /home/httpd/vhosts/domain.com/httpdocs/
The DocumentRoot in the vhost.conf on my server is: DocumentRoot /srv/www/domain.com/public_html/
Is there a way to alias /home/httpd/vhosts/domain.com/httpdocs/ to /srv/www/domain.com/public_html/?
I have tried the Alias directive, but it didn't work, perhps I had the syntax wrong.
Msg#: 4252164 posted 8:03 am on Jan 12, 2011 (gmt 0)
Why not just change the DocumentRoot directive in the configuration so that it points to the right place?
What do you mean by "hundreds of files"? Have you "included" files and used the full path in the reference? An editor such as EditPlus3 could do a find and replace on all of your files in minutes. However, the server path for PHP includes (if that is what it is) should have been defined in a variable or set as a configuration line in the config file or in .htaccess.