0

I have a URL rewrite in IIS that's triggering on 3 URL's but I only want it to trigger on two URL's

http://www.example.com/resources/myresource
http://www.example.com/resources/myresource/
http://www.example.com/resources/myresourceKB

The first two urls' I want it trigger on but not the third one.

I was using resoucres/myresource as my regex pattern, but then I noticed the third URL got included in it.

How can I make the regex capture the first 2 url's but not the third?

1 Answer 1

2

Use negative look ahead (?!):

http://www.example.com/resources/myresource(?!KB)
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.