www.domain.com & domain.com - don't work

fairwind@drupal.ru - July 13, 2007 - 11:20
Project:Multiple Domains
Version:5.x-1.x-dev
Component:url rewrite functionality
Category:bug report
Priority:normal
Assigned:Unassigned
Status:patch (code needs work)
Description

When secondary domain can be accessed by both www.domain.com & domain.com, and set in multidomain taxonomy as domain.com, we a in trouble. Go to www.domain.com leads to default cite, but with path - surprise! www.domain.com!

#1

fairwind@drupal.ru - July 13, 2007 - 12:57
Status:active» patch (code needs work)

Quick and dirty hack. Seems to work with "all but default domain" rewrite mode.

AttachmentSize
multidomain.www-rewrite.patch2.01 KB

#2

shadyman@errora... - September 14, 2007 - 19:27

Could you not just use the .htaccess lines such as these to force a www. or force without? I uncommented the second set of lines to remove the www., personally.

# Various rewrite rules.
<IfModule mod_rewrite.c>
  RewriteEngine on

  # If your site can be accessed both with and without the prefix www. you
  # can use one of the following settings to force user to use only one option:
  #
  # If you want the site to be accessed WITH the www. only, adapt and
  # uncomment the following:
  # RewriteCond %{HTTP_HOST} ^example\.com$ [NC]
  # RewriteRule .* http://www.example.com/ [L,R=301]
  #
  # If you want the site to be accessed only WITHOUT the www. prefix, adapt
  # and uncomment the following:
  # RewriteCond %{HTTP_HOST} ^www\.example\.com$ [NC]
  # RewriteRule .* http://example.com/ [L,R=301]
</IfModule>

#3

wayland76 - January 16, 2008 - 03:22
Priority:critical» normal

Downgrading from critical to normal, as there's a workaround.

 
 

Drupal is a registered trademark of Dries Buytaert.