Actions
Bug #201
closedHost parsing in mod_rewrite
Status:
Invalid
Priority:
High
Category:
mod_rewrite
Target version:
-
ASK QUESTIONS IN Forums:
Description
Hi, is there any ways to parse Host in mod_rewrite rules? I need to rewrite username.site.com to www.site.com?un=username. Any ideas?
-- valent
Updated by Anonymous over 19 years ago
why not just match "^.*\.site\.com$" (except www.) and rewrite / to /?un=username
and handle "/?un=username" (unless your script care about www. hostname)
-- Xuefer <xuefer
Updated by jan over 19 years ago
- Status changed from New to Fixed
- Resolution set to invalid
You can just match on HTTP_HOST in your script.
Actions
Also available in: Atom