Welcome to MobyThreads.com!
FAQFAQ      ProfileProfile    Private MessagesPrivate Messages   Log inLog in
All support for the MobyThreads Threaded phpBB MOD can now be found on welsolutions at this forum

mapping two files in same directory using Alias directive

 
   Web Hosting and Web Master Forums (Home) -> Apache RSS
Next:  ANN: Adding Security to Web Hosting Service  
Author Message
vkaivallya

External


Since: Jan 18, 2005
Posts: 1



(Msg. 1) Posted: Tue Jan 18, 2005 11:51 pm
Post subject: mapping two files in same directory using Alias directive
Archived from groups: alt>apache>configuration (more info?)

Hi group!!
I have a problem configuring apache

i want to map to two diffrent files in the same directory according to
Alias provided
So if the the user types the url as http://zz.zz.zzz.zzz/tt
i must go to file first.html ie ie http://zz.zz.zzz.zzz/pp/first.html

and if the user types the url as http://zz.zz.zzz.zzz/pp
i must go to file second.html ie http://zz.zz.zzz.zzz/pp/second.html

what is happening in current situation is that whatever be the URL of
the above two i am directed to second.html

I assume that DirectoryIndex property is causing it but i am not sure
I havent touched httpd.conf file and all the default settings are
maintained so DocumentRoot has not been changed its still
/var/www/html


My query is
with above scenarion what am i supposed to do to my conf file in
/etc/conf.d/ so that everything works right ?

I have tried using Redirect permanent and it works fine but i dont
want to pass the absolute url which is the case in Redirect
like
Redirect permanent /tt http://localhost:9001/system/first.html
Redirect permanent /pp http://localhost:9001/system/second.html


Can mapping to two different files which are in the same directory can
be done using aliases?


Following is my conf file in /etc/conf.d/ direcory

Alias /tt "/home/site/"

<Directory "/home/site/">
DirectoryIndex first.html
Options Indexes MultiViews
AllowOverride None
Order allow,deny
Allow from all
</Directory>


Alias /pp "/home/site/"

<Directory "/home/site/">
DirectoryIndex second.html
Options Indexes MultiViews
AllowOverride None
Order allow,deny
Allow from all
</Directory>

thanks
in advance
Ramesh

 >> Stay informed about: mapping two files in same directory using Alias directive 
Back to top
Login to vote
Display posts from previous:   
Related Topics:
Alias directive - When I use an alias directive in httpd.conf such as: Alias /mp3 "d:/Media/Music" .... should I also have a suitable Directoty directive, suchs as: <Directory "d:/Media/Music"> Options All Order allow,deny Allow fr...

Trying to alias directory paths? - I'm in the process of switching from a shared FreeBSD server to a dedicated RedHat server running Plesk v7.02 control panel. I have many PHP and perl scripts that use the server path to files and directories. Since the paths differ between servers I woul...

Mapping Files Outside the DocumentRoot from a Linux 9.0 bo.. - Hello, I'm trying to map files outside the DocumentRoot from a Linux 9.0 box to a WinXP client on local LAN. I believe an alias directive is the way to go, but i'm a bit rusty on the nomenclature to use between the boxes. For example: Alias /directory...

pdf files from the cgi-bin directory - Im using the perl modules PDF::Create and PDF::Reuse to add some form input fields to a pdf. I then want to be able to download into the browser the created pdf file. I seem to be able only to create the file in the cgi-bin directory ( prDocDir('/tmp/'...

See files in my directory - I have apache as web server but I would like to see the files in a directory. by exemple if I have http://192.168.1.105/~philippe/files/ I would like to see all directory in files in this folder but I can not how to configure apache to do it. please..
   Web Hosting and Web Master Forums (Home) -> Apache All times are: Pacific Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



[ Contact us | Terms of Service/Privacy Policy ]