Home Answers Viewqa Regex Regular expression in c++{MFC}

 
 


Pravin
Regular expression in c++{MFC}
0 Answer(s)      2 years and a month ago
Posted in : Regex

Hi ALL,

I want to build a regular expression in c++{MFC} which validates the URL.

The regular expression must satisfy following conditions.

Valid URL:- http://cu-241.dell-tech.co.in/MyWebSite/ISAPIWEBSITE/Denypage.aspx/ http://www.google.com http://www.google.co.in

Invalid URL:- 1>http://cu-241.dell-tech.co.in/\MyWebSite/\ISAPIWEBSITE/\Denypage.aspx/ = Regx must check &

invalid URL as '\' character between "/\MyWebSite/\ISAPIWEBSITE/\Denypage.aspx/"

2>http://cu-241.dell-tech.co.in//////MyWebSite/ISAPIWEBSITE/Denypage.aspx/ = Regx must check

& invalidate URL due to multiple entries of "///////" in url.

3>http://news.google.co.in/%5Cnwshp?hl=en&tab=wn = Regex must check & invalidate URL for

additional insertion of %5C & %2F character.

How can we develop a generic Regular Expression satisfying above condition. Please, Help us by providing a regular expression that will handle above scenario's in

CPP{MFC}

Thnaks & Regards, Amit & Pravin

View Answers









Related Pages:

Ask Questions?

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.

Ask your questions, our development team will try to give answers to your questions.