Solved

Convert ISAPI Rewrite to .htaccess

Posted on 2009-04-06
1
1,609 Views
Last Modified: 2012-05-06
How do I convert this Helicon ISAPI Rewrite file into Apache .htaccess?
[ISAPI_Rewrite]
 
RewriteCond %HTTPS (on)|.*
RewriteCond Host: (?!(?:www|mail)\.)(.*)
RewriteRule (.*) http(?1s:)\://www.$2$3 [I,RP]
 
RewriteRule     /index.html                             /index.cgi                                      [I,L]
RewriteRule     /golf-apparel-details/(.*).html         /index.cgi\?pid=$1                              [I,L]
RewriteRule     /team-btl/(.*).html                     /index.cgi\?page=$1.html                        [I,L]
RewriteRule     /golf-directory/(.*).html               /index.cgi\?page=$1.html                        [I,L]
RewriteRule     /golf-apparel/polos.html                /index.cgi\?exact_match=yes&product=polos       [I,L]
RewriteRule     /golf-apparel/mocks.html                /index.cgi\?exact_match=yes&product=mocks       [I,L]
RewriteRule     /golf-apparel/limited.html              /index.cgi\?exact_match=yes&product=limited     [I,L]
RewriteRule     /golf-apparel/hats.html                 /index.cgi\?exact_match=yes&product=hats        [I,L]
RewriteRule     /golf-apparel/tees.html                 /index.cgi\?exact_match=yes&product=tee         [I,L]
RewriteRule     /golf-apparel/accessories.html          /index.cgi\?exact_match=yes&product=accessories [I,L]
RewriteRule     /golf-apparel/ladies.html               /index.cgi\?exact_match=yes&product=ladies      [I,L]
RewriteRule     /customer-service/(.*).html             /index.cgi\?page=$1.html                        [I,L]
RewriteRule     /sponsorships/(.*).html                 /index.cgi\?page=$1.html                        [I,L]
RewriteRule     /school-discounts/(.*).html             /index.cgi\?page=$1.html                        [I,L]
RewriteRule     /corporate-discounts/(.*).html          /index.cgi\?page=$1.html                        [I,L]
RewriteRule     /wholesale-center/(.*).html             /index.cgi\?page=$1.html                        [I,L]

Open in new window

0
Comment
Question by:comeran
[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
1 Comment
 
LVL 5

Accepted Solution

by:
comeran earned 0 total points
ID: 24084812
Ok I figured it out. In case others need to do this look at what it was above and what it now is below
Options +FollowSymlinks
RewriteEngine on
 
RewriteCond %{HTTP_HOST} ^domain\.com [NC]
RewriteRule ^(.*) http://www.domain.com/$1 [R,L]
 
RewriteRule     ^index.html$                                    index.cgi                                               [L]
 
RewriteRule     ^golf-apparel-details/(.*).html$                index.cgi?pid=$1                                        [L]
 
RewriteRule     ^team-btl/(.*).html$                            index.cgi?page=$1.html                                  [L]
 
RewriteRule     ^golf-directory/(.*).html$                      index.cgi?page=$1.html                                  [L]
 
RewriteRule     ^golf-apparel/polos.html$                       index.cgi?exact_match=yes&product=polos                 [L]
RewriteRule     ^golf-apparel/mocks.html$                       index.cgi?exact_match=yes&product=mocks                 [L]
RewriteRule     ^golf-apparel/limited.html$                     index.cgi?exact_match=yes&product=limited               [L]
RewriteRule     ^golf-apparel/hats.html$                        index.cgi?exact_match=yes&product=hats                  [L]
RewriteRule     ^golf-apparel/tees.html$                        index.cgi?exact_match=yes&product=tee                   [L]
RewriteRule     ^golf-apparel/accessories.html$                 index.cgi?exact_match=yes&product=accessories           [L]
RewriteRule     ^golf-apparel/ladies.html$                      index.cgi?exact_match=yes&product=ladies                [L]
 
RewriteRule     ^customer-service/(.*).html$                    index.cgi?page=$1.html                                  [L]
RewriteRule     ^sponsorships/(.*).html$                        index.cgi?page=$1.html                                  [L]
RewriteRule     ^school-discounts/(.*).html$                    index.cgi?page=$1.html                                  [L]
RewriteRule     ^corporate-discounts/(.*).html$                 index.cgi?page=$1.html                                  [L]
RewriteRule     ^wholesale-center/(.*).html$                    index.cgi?page=$1.html                                  [L]

Open in new window

0

Featured Post

NEW Veeam Agent for Microsoft Windows

Backup and recover physical and cloud-based servers and workstations, as well as endpoint devices that belong to remote users. Avoid downtime and data loss quickly and easily for Windows-based physical or public cloud-based workloads!

Question has a verified solution.

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

In my time as an SEO for the last 2 years and in the questions I have assisted with on here I have always seen the need to redirect from non-www urls to their www versions. For instance redirecting http://domain.com (http://domain.com) to http…
Over the last year I have answered a couple of basic URL rewriting questions several times so I thought I might as well have a stab at: explaining the basics, providing a few useful links and consolidating some of the most common queries into a sing…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …

696 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