Web Hosting
January 31, 2004 7:04 PM   Subscribe

1&1 Web Hosting has consistently failed to answer what I think should be a very simple question: given that they do not use per-account httpd.conf files, how do I set the my Alias and ScriptAlias variables so that the web application I want to use can work without my having to go in and re-script them? Thanks eversomuch -- I've been waiting months for a quality reply from them!
posted by five fresh fish to Computers & Internet (8 answers total)
 
I'd like to use 1&1, but they also never answered my question, which was why wasn't SetEnv in a .htaccess working. Unfortunately, I think I recall finding out myself that they use suexec (to run as my user), and so I can't set them, which would make running a bunch of my stuff a pain in the ass.

Anyway, do Alias and ScriptAlias work in .htaccess files?
posted by thebabelfish at 7:41 PM on January 31, 2004


I would have to double-check, but I don't think Alias is allowed in .htaccess.
posted by tranquileye at 8:37 PM on January 31, 2004


I don't think Alias and ScriptAlias work in .htaccess files -- only the kinds of directives that you can set AllowOverride for do.

What you can do with .htaccess files, if I recall correctly, is use FileInfo directives (AddType, AddHandler) to make scripts execute anywhere below a given .htaccess file. I'll look that up if I can and post it.
posted by weston at 8:40 PM on January 31, 2004


What about mod rewrite?
posted by machaus at 8:51 PM on January 31, 2004


mod_rewrite is supposed to work inside .htaccess, but I've yet to figure out how to get it running on servers I don't control, especially when you can't restart the server.
posted by yerfatma at 9:36 AM on February 1, 2004


yerfatma, I've gotten it working on servers I don't control. Do you include the RewriteEngine on line before any other mod_rewrite directives?
posted by thebabelfish at 5:40 PM on February 1, 2004


I'm no longer sure if we're talking about my Alias/ScriptAlias question, or something else now...
posted by five fresh fish at 9:14 AM on February 2, 2004


fff, the upshot of my post is: you can't set Alias/ScriptAlias. However, if you have shell access on a UNIX system you can do something like it: use the ln -s command to create a symbolic link for the directories. Something like ln -s /home/fff/www/foobarbilltype/cgi-bin/blah/ /home/fff/www/blah, I guess.

You can also make a directory CGI-script aware by placing the following lines in a .htaccess file in that directory (assuming AllowOverride is on!):

Options +ExecCGI
AddHandler cgi-script .cgi
posted by weston at 12:00 AM on February 3, 2004


« Older Vacation Suggestions   |   Does Vodka really have Zero Carbs? Newer »
This thread is closed to new comments.