•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the Linux Servers and Apache section within the Tech Talk category of DaniWeb, a massive community of 427,339 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,133 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Linux Servers and Apache advertiser: Programming Forums
Views: 7411 | Replies: 12
![]() |
•
•
Join Date: Feb 2002
Location: Lawn Guylen, NY
Posts: 10,943
Reputation:
Rep Power: 32
Solved Threads: 117
I have mod_rewrite enabled and I am currently using it so that my forums and threads have .html exensions
i.e. to redirect to the real php pages.
i.e. to redirect to the real php pages. Dani the Computer Science Gal
Do you run a computer-related website? Feature it in our niche link directory!
Do you run a computer-related website? Feature it in our niche link directory!
•
•
Join Date: Mar 2005
Location: South Africa
Posts: 4
Reputation:
Rep Power: 0
Solved Threads: 0
Hi, I am new to your forum, but if I understand your query correctly,
I think you can try the following:
Here goes....
Providing that your DNS is correctly pointed
and both url's point to the same server, you need to add the following to httpd.conf
#
# UseCanonicalName: Determines how Apache constructs self-referencing
# URLs and the SERVER_NAME and SERVER_PORT variables.
# When set "Off", Apache will use the Hostname and Port supplied
# by the client. When set "On", Apache will use the value of the
# ServerName directive.
#
UseCanonicalName Off
NameVirtualHost *:80 # if it doesnt exist already
and then in the Virtualhost Container
<VirtualHost *:80>
ServerName www.somedomain.com
ServerAlias somedomain.com
## Some other stuff
</VirtualHost>
This will tell Apache to redirect all requests to any of the above url's to the specified virtual host.
Hope it helps...
I think you can try the following:
Here goes....
Providing that your DNS is correctly pointed
and both url's point to the same server, you need to add the following to httpd.conf#
# UseCanonicalName: Determines how Apache constructs self-referencing
# URLs and the SERVER_NAME and SERVER_PORT variables.
# When set "Off", Apache will use the Hostname and Port supplied
# by the client. When set "On", Apache will use the value of the
# ServerName directive.
#
UseCanonicalName Off
NameVirtualHost *:80 # if it doesnt exist already
and then in the Virtualhost Container
<VirtualHost *:80>
ServerName www.somedomain.com
ServerAlias somedomain.com
## Some other stuff
</VirtualHost>
This will tell Apache to redirect all requests to any of the above url's to the specified virtual host.
Hope it helps...
![]() |
•
•
•
•
•
•
•
•
DaniWeb Linux Servers and Apache Marketplace
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
apple bbc cd cellphone choose code computer core debian dell desktop development drivers enterprise fedora fiji games gentoo gpl hardware ibm infrastructure install kernel laptop linux marketing microsoft mobile news novell open open source openoffice operating os palm preinstall red hat rhel security server source sun system ubuntu unix vista web windows
- Previous Thread: please help a newbie out with apache
- Next Thread: no website configured at this adress



Linear Mode