Rewriting a Subdomain with mod-rewrite
Posted
by resonantmedia
on Stack Overflow
See other posts from Stack Overflow
or by resonantmedia
Published on 2010-04-27T17:40:10Z
Indexed on
2010/04/27
17:43 UTC
Read the original article
Hit count: 454
mod-rewrite
|moodle
I have a project that uses the moodle library. I had to change the URL from moodle.example.com to learn.example.com, due to a client request.
I thought this would be an easy change, but alas moodle inserts all links and images in with the complete url instead of the relative url.
Is it possible using mod-rewrite to point all requests to moodle.example.com to learn.example.com and maintain the query string?
Example:
I want a request to: http://moodle.example.com/course/view.php?id=2&topic=1
to go to http://learn.example.com/course/view.php?id=2&topic=1
.
Is this possible?
Thanks,
Josh
© Stack Overflow or respective owner