Something like this will probably work for you:

  <cfquery([[:space:]]+[[:alnum:]]+=("[^"]+"|[^[:space:]]+))+[[:space:]]*>

This will deal with the case of having non-alphanumeric tag attributes in
random order.

-Rick

-----Original Message-----
From: Christopher S Martin [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, October 24, 2000 12:25
To: CF-Talk
Subject: Finding a query in a file


Hi everyone, i have written a regex that should (i think) return an instance
of any <cfquery name=blah datasource=foo>  in a page.

I read a page into meory first, and call it page_buffer. The regex looks
like this:

ReFindNoCase("<cfquery +name=[a-z]+[0-9]* +datasource=[a-z]+",
#page_buffer#)

For some reason, however, this does not turn up any mathces.  Could any of
you regex wiards out there tell me why?

Chris Martin

------------------------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send a message 
with 'unsubscribe' in the body to [EMAIL PROTECTED]

Reply via email to