Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

Coding Forum


You are currently viewing our Coding Forum as a guest. Please register to participate.
Login



Reply
Prefix "www" htaccess error
Old 01-03-2010, 01:06 PM Prefix "www" htaccess error
Average Talker

Posts: 28
Name: Jimmy
Location: India
Trades: 0
Good Day Friends,

I have a problem in htaccess "www" prefix code.

My code is like this

RewriteEngine On
Options +FollowSymlinks

# This is the code for the subdirectory.
# My actual code is placed is subdirectory named "doman"
# This code is working fine

RewriteCond %{HTTP_HOST} ^domain\.com$ [OR]
RewriteCond %{HTTP_HOST} ^www\.domain\.com$
RewriteCond %{REQUEST_URI} !^/domain/
RewriteRule (.*) /domain/$1

#When i added this code for automatic www prefix
#my url becomes http://www.domain.com//domain
# i want it to be like www.domain.com

RewriteCond %{http_host} ^domain.com [NC]
RewriteRule ^(.*)$ http://www.domain.com/$1 [R=301,L]
jimahuja is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Reply     « Reply to Prefix "www" htaccess error
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.11502 seconds with 12 queries