homepage Welcome to WebmasterWorld Guest from
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / Content Management
Forum Library, Charter, Moderators: ergophobe

Content Management Forum

How to Redirect Sub-Domain URLs in MOSS?
Can clicks for test.example.com/page?id=1 be redirected?

 3:59 pm on Aug 26, 2010 (gmt 0)

I work as an content author on a site that is administered by a MOSS team in another country (Microsoft Office(?) Sharepoint Server).

That site (example.com) links to another CMS whose pages are like test.example.com/page?id=1 (etc).

Now people want that test.example.com to go away and be replaced with test2.example.com pages.

Does MOSS work with the domains? Can MOSS redirect traffic headed for test.example.com/page?id=1 to test2.example.com/whatever.html?

If not, what would I need to know about to do that? Unfortunately, the old CMS is going to die and won't help us.



 4:13 pm on Aug 26, 2010 (gmt 0)

Does test.example.com need to stay live?

If not, all you need is to redirect on that server to test2. The redirects should be on the old target server... or maybe I'm just not following.


 4:33 pm on Aug 26, 2010 (gmt 0)

Thanks for the question. test.example.com does not need to stay alive.

However, the many pages will not match up with the new page URLs if you mean to switch "test" with "test2" ... but I maybe I don't understand.


 10:00 pm on Aug 27, 2010 (gmt 0)

If test.example.com is not staying alive, then there's no worries. You just create all the rewrite rules you need on test.example.com to rewrite to test2.example.com

So if you've got requests coming in on test for page?id=1 and that needs to be rewritten to come in on test2 for, I don't know, index.php?n=1 that can be captured with a single condition + rule like

RewriteCond %{HTTP_HOST} ^test\.example\.com [NC]
RewriteRule ^page\?id=(.\d+)$ [test2.example.com...] [R=301,L]

That's an Apache rewrite of course, but I know you can do similar on MS servers as well with certain modules added on. If the mappings are less precise, you'd need to do a rewrite rule for each page that didn't match the general rule or some such.

But in any case, you would want to both
- update the links on your Sharepoint server (update, not redirect - a link isn't redirected on the outbound server). Eventually, these should be pointing to the right places without redirecting. I have no idea how MOSS works, but for this sort of thing, I usually grep for the URL in question and change it where needed and then reupload the database (or use sed to change the files if that's more appropriate). I have no idea what the Microsoft equivalent would be to do doing that, but things like PowerGREP can handle that sort of text manipulation on a Windows machine. But maybe it's just a setting (like I say, I don't know MOSS).

- redirect the target links on test.example.com so that old links around the web to your test.example.com domain don't go bad. Ideally, you'd try some general rule that would handle most cases and you'd look at your sever logs and at least get the top 100 pages redirected to their equivalent on the new site.

Global Options:
 top home search open messages active posts  

Home / Forums Index / Code, Content, and Presentation / Content Management
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved