Tim and James,

I'm now using:
new Regex(@"(.*?)(url\()(?![""']?http|[""']?/)([""']?)(?<Url>.*?)[""']?
\)(.*?)", RegexOptions.Compiled | RegexOptions.IgnoreCase);
see 
https://svn.castleproject.org/svn/castle/MonoRail/trunk/src/Castle.MonoRail.Framework/ViewComponents/CombineJSViewComponent.cs

This seems to work for all the test cases we have in:
https://svn.castleproject.org/svn/castle/MonoRail/trunk/src/Castle.MonoRail.Framework.Tests/ViewComponents/CombineJSViewComponentTestCase.cs

Tim,
I tried your regex (?:.*?)(?:url)\((?!http|/|data:)(?<Url>.*?)\)
(?:.*?)  and this failed quite a few tests.
>Also I'm curious to know, did you guys just add in the data scheme today?
Yes

Cheers
John


On Dec 18, 9:36 am, James Curran <[email protected]> wrote:
> On Thu, Dec 17, 2009 at 5:26 PM, Tim Barcz <[email protected]> wrote:
> > fully qualified URLs are handled. John's initial version handled
>
> right, John's handled NON-quoted fully-qualified URL.  Adding the
> quote messes up the pattern so that they no longer match (or, to be
> exact, no longer fail to match)
>
> --
> Truth,
>     James

--

You received this message because you are subscribed to the Google Groups 
"Castle Project Development List" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/castle-project-devel?hl=en.


Reply via email to