Mod Rewrite question ...

Discussion in 'Apache' started by LaCabra, Jan 9, 2006.

  1. #1
    Hey guys ...
    My appologies but I am not a programmer and had a brain fart about optimizing certain aspects of my site. I have this quick question:

    Can I use a mod rewrite or other tool to modify a dynamic URL:

    Url spits out like this: www.abc.com/inq.php?terms=cows

    Url I would prefer it spits out: www.abc.com/infoabout-cows.htm

    Is this possible? Please excuse my ignorance.
    thanks
    Frank
     
    LaCabra, Jan 9, 2006 IP
  2. Nintendo

    Nintendo ♬ King of da Wackos ♬

    Messages:
    12,890
    Likes Received:
    1,064
    Best Answers:
    0
    Trophy Points:
    430
    #2
    Options +Indexes
    Options +FollowSymlinks
    RewriteEngine on
    RewriteBase /
    RewriteRule ^infoabout\-([^.]+)\.htm$ inq.php?terms=$1 [L]
     
    Nintendo, Jan 9, 2006 IP
    bentong likes this.
  3. LaCabra

    LaCabra Goats R Us

    Messages:
    1,954
    Likes Received:
    241
    Best Answers:
    0
    Trophy Points:
    0
    #3
    ninooooooooo you're confusing meeee! I assume that the answer is Yes and thats the syntax for it!?!?!! ;)

    Thanks Nino!
    :)
     
    LaCabra, Jan 9, 2006 IP