Link to home
Start Free TrialLog in
Avatar of trg_dk
trg_dkFlag for Denmark

asked on

Helicon Ape - mod_rewrite

I a previous question, I got the following code - and it works...

RewriteEngine on
RewriteBase /
rewritecond %{http_host} ^domain.com [NC]
rewriterule ^(.*)$ http://www.domain.com/$1 [NC,R=301]

But I really wnat it to be generic - so it can be deployed on the generel .HTAccess tab in APE.

So please help me out here - instead of domain.com - I need the generic term for the current site. I have almost 300 sites on the server and dont want to do this for each and every one of them :)
ASKER CERTIFIED SOLUTION
Avatar of Brad Howe
Brad Howe
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of trg_dk

ASKER

Works brilliantly :) Thanks!!