This forum has been moved here:
Helicon Tech Community Forum

  Active TopicsActive Topics  Display List of Forum MembersMemberlist  HelpHelp   RegisterRegister  LoginLogin
ISAPI_Rewrite 2.x
 Helicon Tech : ISAPI_Rewrite 2.x
Subject Topic: Rewrite rule to match GUID? Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
earljj
Newbie
Newbie


Joined: 06 April 2010
Location: United States
Online Status: Offline
Posts: 18
Posted: 22 February 2011 at 8:24am | IP Logged Quote earljj

I'm having trouble figuring out how to match the following URL:

/_layouts/feed.aspx?xsl=1&web=%2FMediaRelations&page=b4a27b61-d4d0-4eee-8b0c-4e7d57d340a8&wp=1d1c481a-1cf2-4772-b664-481cf660c769

I tried just prefixing the whole string with a $, and I also tried escaping the ? % - = characters. Regextest.exe tells me I have a bad match.

What am I missing?

Back to Top View earljj's Profile Search for other posts by earljj
 
Anton
Admin Group
Admin Group


Joined: 30 January 2007
Location: Ukraine
Online Status: Offline
Posts: 10520
Posted: 23 February 2011 at 4:47am | IP Logged Quote Anton

Could you please show the rule you are trying to use.
And please confirm you are using ISAPI_Rewrite v2.

__________________
Regards,
Anton
Back to Top View Anton's Profile Search for other posts by Anton
 
earljj
Newbie
Newbie


Joined: 06 April 2010
Location: United States
Online Status: Offline
Posts: 18
Posted: 23 February 2011 at 7:02am | IP Logged Quote earljj

I've gone through several different versions of the rule at this point, but here's the base:

RewriteRule ^_layouts/feed.aspx?xsl=1&web=%2FMediaRelations&page=b4a27b61-d4d0-4eee-8b0c-4e7d57d340a8&wp=1d1c481a-1cf2-4772-b664-481cf660c769 http://mysite.com/_layouts/feed.aspx?xsl=1&web=%2FMediaRelations&page=bbbcf240-2214-4624-8e01-ddc75c6ae6a5&wp=1a0aad98-76eb-42c3-a830-b8b4efc322d9 [NC,I,O,R=301,L]

Back to Top View earljj's Profile Search for other posts by earljj
 
earljj
Newbie
Newbie


Joined: 06 April 2010
Location: United States
Online Status: Offline
Posts: 18
Posted: 23 February 2011 at 7:03am | IP Logged Quote earljj

I apologize--it turns out that we're using ISAPI Rewrite version 3.1.

Back to Top View earljj's Profile Search for other posts by earljj
 
Anton
Admin Group
Admin Group


Joined: 30 January 2007
Location: Ukraine
Online Status: Offline
Posts: 10520
Posted: 24 February 2011 at 2:54am | IP Logged Quote Anton

The rules for v3 will be as follows:

RewriteBase /
RewriteCond %{QUERY_STRING} ^xsl=1&web=\%2FMediaRelations&page=b4a27b61-d4d0-4eee-8b0c-4e7d57d340a8&wp=1d1c481a-1cf2-4772-b664-481cf660c769$ [NC]
RewriteRule ^_layouts/feed\.aspx$ http://mysite.com/_layouts/feed.aspx\?xsl=1&web=\%2FMediaRelations&page=bbbcf240-2214-4624-8e01-
ddc75c6ae6a5&wp=1a0aad98-76eb-42c3-a830-b8b4efc322d9 [NC,R=301,L]

Though I don't quite understand why are you trying to redirect to the same URL? What's the idea?

__________________
Regards,
Anton
Back to Top View Anton's Profile Search for other posts by Anton
 
earljj
Newbie
Newbie


Joined: 06 April 2010
Location: United States
Online Status: Offline
Posts: 18
Posted: 24 February 2011 at 7:40am | IP Logged Quote earljj

That worked--thank you very much!

As to what we're trying to do... Our site runs on SharePoint, and this page is an RSS feed of the content from our media relations page. SharePoint uses one .aspx page for all RSS feeds and just swaps out the GUIDs to display the appropriate content.

Due to some changes we made in the structure of our site, the GUID for the media relations page changed, but we want to make sure that people who were subscribed to the original feed continue to get updates. 

Thanks again for the help!

Back to Top View earljj's Profile Search for other posts by earljj
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum