Groups
Groups
Sign in
Groups
Groups
Regex
Conversations
Labels
About
Send feedback
Help
Matching query string for redirect
0 views
Skip to first unread message
Jesse
unread,
Oct 6, 2009, 4:01:39 PM
10/6/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Regex
Trying to write a redirect and need to use regular expressions...
From Url: "^~/test/test.aspx?CatID=1003"
To URL: "~/whatever.aspx"
The important components for the redirect are the directory "test" and
the number "1003"
Without the query string (?CatID=1003) everything works fine.
I tried ^~/Test/.*\b1003\b.*$ but that didn't get me anywhere...
little help?
Jesse
Accmailer
unread,
Oct 7, 2009, 4:04:40 AM
10/7/09
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Regex
I guess the problem was due to the fact that forward slashes should be
escaped with backslashes.
This one works OK:
^\s*\S+\/test\/.*\?\w+\=1003\b\S*\s*$
As a precaution, optional spaces added at the start and at the end of
the input.
Reply all
Reply to author
Forward
0 new messages