Morpheus Posted January 3, 2007 Report Share Posted January 3, 2007 Hi everyone - happy new year! I am replacing a PC webserver for a local business who were operating a Mambo site but I'm running into a small issue.... The previous IT guy has done some very weird stuff so to save some time I have used Uniform server. Getting the Mambo site up and running took almost 5 minutes but I have hit a snag! The website serves up documents (PDFs) that are located on their network but are not within the scope of the W drive or the webroot so I need to invoke some kind of alias or redirection but I just can't make it work. I found a post on the web suggesting that I map a network drive i.e. G: to the folder on the workstation containing the files and then access them using an alias entry as below but for testing purposes I have tried using the root of the local C drive: The virtual host part is working great but the redirect / alias is driving me nuts! An example of a link is "http://office.english-mutual.co.uk/files/EMW.pdf" <VirtualHost *>ServerName office.english-mutual.co.ukServerAlias english-mutual.co.uk *.english-mutual.co.uk DocumentRoot /www/Intranet/html #<Directory "/www/Intranet/html">#Allow from all#Options +Indexes#Options Indexes FollowSymLinks ExecCGI#</Directory> Alias /files/ "C:/"<Directory "C:/"> Options Indexes Includes AllowOverride All Order allow,deny Allow from all</Directory> ServerAdmin webmaster@english-mutual.co.ukErrorLog logs/english-mutual.co.uk.com-error_logCustomLog logs/english-mutual.co.uk.com-access_log common</VirtualHost> Regards, Adam Quote Link to comment Share on other sites More sharing options...
olajideolaolorun Posted January 4, 2007 Report Share Posted January 4, 2007 Wow, if you think you took a short cut.. lol... all that is not needed. You can get the files by using alias itself... something like this should work: Alias /cfiles/ "C:\" <Directory "C:\"> Options Indexes Includes AllowOverride All Order allow, deny Allow from all </Directory> Notice the C:'\' That \ matters cause it goes a different way for Windows.... / is for *nix based. Quote Best Regards Olajide Olaolorun The Uniform Server Development Team Link to comment Share on other sites More sharing options...
Morpheus Posted January 4, 2007 Author Report Share Posted January 4, 2007 Still no luck I've tried placing that code inside and outside of the virtualhost section but it makes no difference - still getting a 404 error when I click the link. Any other ideas? Adam Quote Link to comment Share on other sites More sharing options...
Morpheus Posted January 4, 2007 Author Report Share Posted January 4, 2007 I have also tried from the UniformServer machine using http://localhost/files/EMW.pdf but that gives a 404 error too Quote Link to comment Share on other sites More sharing options...
olajideolaolorun Posted January 4, 2007 Report Share Posted January 4, 2007 A, I did not say put it in a virtual host, just put it in the conf file around where the other alias are... that would be better. B, notice the change, the address is now cfile not file.... Quote Best Regards Olajide Olaolorun The Uniform Server Development Team Link to comment Share on other sites More sharing options...
Morpheus Posted January 5, 2007 Author Report Share Posted January 5, 2007 Sorry if I confused you.... a) I did notice the change for /CFile/ and changed it back in my copy I tried adding the code within the virtualhost section but, when that didn't work, I moved it outside to the bottom of the .conf file. I didn't think positioning would make any difference as there were no obvious enclosure statements around the other alias entries. Quote Link to comment Share on other sites More sharing options...
olajideolaolorun Posted January 6, 2007 Report Share Posted January 6, 2007 If you are trying to use virtual host, you have to search the forum and look at every post that deals with virtual host. Some methods dont work and some do on some PC and some codes needs to be added sometimes.... Good Luck. Thanks. Quote Best Regards Olajide Olaolorun The Uniform Server Development Team Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.