Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Let's assume that I have 2 virtualhosts running for the domains and For these domains I set the documentroot to c:\server\htdocs\user\domains\ and c:\server\htdocs\user\domains\ From these documentroot locations I want to be able to call perl or python scripts in a cgi-bin folder located 2 folders down from the documentroot (so c:\server\htdocs\user\cgi-bin) by using ../../cgi-bin/ This doesn't work, however, it does work when I call the script by using c:/server/htdocs/user/cgi-bin/

I have set up my server using xampp, and I have created a virtualhost containing ScriptAlias /cgi-bin/ "c:/server/htdocs/user/cgi-bin/", but this will not work for me. How do I go about this? I've tried looking on google for the answer, but all it comes up with is the default settings for a server without virtualhosts.

Any help would be greatly appreciated.


Note that I run my server on windows 7.

share|improve this question
you should just be able to use that script alias as it, map it into the the domain at /cgi-bin/ and just call your script as /cgi-bin/ . you can't call scripts outside the docroot without using the alias. from the web. – Doon Jun 20 '13 at 23:57
also tried calling it with /cgi-bin/, but that does nothing either. And I really don't want to put my cgi-bin folder inside my documentroot itself for obvious reasons. – Gabi Barrientos Jun 21 '13 at 0:01
what is the error message when calling at as /cgi-bin/ ? Also are you sure you have the vhosts working? IE can you see domain1 vs domain2 based on host headers? – Doon Jun 21 '13 at 11:45

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.