Reputation: 103
I need to redirect;
http://video.domain.com/date/videoid
to
http://www.domain.com/video/video.php?date=$date&videoid=$id
Thanks a lot...
Upvotes: 0
Views: 34
Reputation: 80649
RewriteEngine On
RewriteCond %{HTTP_HOST} ^video\.domain\.com$ [NC]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^/]+)/([^/]+)/?$ video/video.php?date=$1&videoid=$2 [L]
Do note that the above would work if both domain.com
and video.domain.com
are hosted on the same server.
Upvotes: 1