Example:
String url = "http://www.google.com/abcd.jpg";
String url2 = "http://www.google.com/abcd.jpg_xxx.jpg";
I want to match "http://www.google.com/abcd" whatever url or url2.
I write a regex:
(http://.*\.com/[^(.jpg)]*).jpg
But [^(.jpg)]*
doesn't like correct. What the regex should be?