?
Solved

How can I redirect a page?

Posted on 2001-08-28
6
Medium Priority
?
196 Views
Last Modified: 2010-03-04
hi
if i had a server and for eg www.mydomain.com is running in that server under apache and tomcat and I 'm using java servlets.so now the index.html under apache is mydomain's home page.If I need to add one more site in that server, foe eg www.yourdomain.com what all things I have to do?
I have some more question?
Whether I can keep index.html and do something inside that or Do I have to change some configuration in httpd config?

Thanks

Harish
0
Comment
Question by:hkg
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
6 Comments
 
LVL 1

Accepted Solution

by:
larry718 earned 200 total points
ID: 6436803
You need to set up a virtual host to have 2 or more domain names in one server.

http://httpd.apache.org/docs/vhosts/index.html

check out "Using name-based virtual hosts"


...
    NameVirtualHost 111.22.33.44

    <VirtualHost 111.22.33.44>
    ServerName www.domain.tld
    DocumentRoot /www/domain
    </VirtualHost>

    <VirtualHost 111.22.33.44>
    ServerName www.otherdomain.tld
    DocumentRoot /www/otherdomain
    </VirtualHost>
...

if this doesn't work, substitute


    NameVirtualHost *
    <VirtualHost *>
    ServerName www.domain.tld
    DocumentRoot /usr/local/apache/htdocs/www/domain
    </VirtualHost>

    <VirtualHost *>
    ServerName www.otherdomain.tld
    DocumentRoot /usr/local/apache/htdocs/www/otherdomain
    </VirtualHost>


Have fun!

0
 

Author Comment

by:hkg
ID: 6468243
hi
I didn't get a perfect answer

Harish
0
 

Author Comment

by:hkg
ID: 6468244
hi
I didn't get a perfect answer

Harish
0
 
LVL 15

Expert Comment

by:samri
ID: 7250973
Harish,

The question is pending delete since you are not getting a good answer.

TO me what has been suggested by Larry is kinda good enough -- maybe do you prefer must detailed explanation?

DO you still need assistance on this?

SHould you insist on the delete to proceed, you can drop a 0-pts question in Community Support, and request for a deletion.

If you still require assistance, please respond.

cheers.
0

Featured Post

Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It is possible to boost certain documents at query time in Solr. Query time boosting can be a powerful resource for finding the most relevant and "best" content. Of course the more information you index, the more fields you will be able to use for y…
In Solr 4.0 it is possible to atomically (or partially) update individual fields in a document. This article will show the operations possible for atomic updating as well as setting up your Solr instance to be able to perform the actions. One major …
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Suggested Courses

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question