Results 1 to 3 of 3

Thread: ISAPI Rewrite

  1. #1
    Join Date
    Dec 2000

    ISAPI Rewrite

    I use a program called ISAPI Rewrite to standardize my websites as follows:

    If someone goes to http://MyDomain, they are given http://www.MyDomain instead.

    The code I am using for this is:

    RewriteCond Host: (?!www„.)(.*)
    RewriteRule (.*) http„://www.$1$2 [I,RP]

    I did not write this code to begin with and am not sure how it works. But can anyone tell me how to get it to do this:

    If someone goes to http://www.MySubdomain.MyDomain, they are given http://MySubdomain.MyDomain instead.

    I am using a windows 2003 server.

  2. #2
    Join Date
    Nov 2005
    try: .......

    RewriteEngine on

    RewriteCond %{HTTPS} (on)?
    RewriteCond %{HTTP:Host} ^(?!www\.)(.+)$ [NC]
    RewriteCond %{REQUEST_URI} (.+)
    RewriteRule .? http(?%1s)://www.%2%3 [R=301,L]

  3. #3
    Join Date
    Dec 2000
    It works like it would work if the httpd.ini file were not even there at all. What I am trying to do is redirect to http://MySubdomain.MyDomain if someone types http://www.MySubdomain.MyDomain in their browser.

Similar Threads

  1. Can a ISAPI Rewrite be used in place of 404 Error page?
    By Ron in forum Programming Discussion
    Replies: 0
    Last Post: 07-04-2008, 06:43 AM
  2. apache rewrite ==> lighttpd rewrite HELP
    By Woooo in forum Hosting Security and Technology
    Replies: 9
    Last Post: 06-24-2008, 01:07 PM
  3. Replies: 9
    Last Post: 04-04-2008, 09:41 AM
  4. Install PHP, ISAPI Rewrite, & Drupal on IIS / Win 2003 Server
    By JeremyL in forum Systems Management Requests
    Replies: 0
    Last Post: 02-01-2008, 11:57 AM
  5. help - Isapi-rewrite frienly (Win) host please.
    By tmax100 in forum Web Hosting
    Replies: 14
    Last Post: 07-09-2007, 10:00 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts