>- see footer for list info -<
not quite, i have a site where there is a cfdump displaying on the front-end,
so want to track down what page is displaying it. not as easy as it seems cos
lots of files in this system use lots of includes, cfc, custom tags, etc, etc.
so just wanted to use homesite to search all coldfusion files for <cfdump, but
if i do this, it returns a few thousand results. 99.9% of these are in comment
tags, but wanted to avoid going through every single one of the 1000s of
occurrences found by homesite, just to find the 1 that is open (not surrounded
by comment tags). If I could search for just all <cfdump that are not
surrounded by comment tags, it would only return maybe 5 or so occurrences ...
much easier to check through than a few thousand!
==========================
>- see footer for list info -<
Not a direct answer...
2 pages, temp1.cfm and temp2.cfm
temp1.cfm
---------------------
<html>
<head>
<title>Untitled</title>
</head>
<body>
<cfdump var="#FORM#">
<!--- <cfdump var="Don't pick me"> --->
<cfdump var="#URL#">
</body>
</html>
temp2.cfm
---------------------
<cffile action="READ" file="#ExpandPath('.')#\temp1.cfm" variable="f">
<cfoutput>
<pre>#HTMLEditFormat(f)#</pre>
</cfoutput>
<!--- Find all cfdumps --->
<cfset regEx ="<cfdump.*?>">
<cfset pos = 1>
<cfset struct = REFindNoCase(regEx, f, pos, true)>
<cfloop condition="#struct.pos[1]#">
<cfdump var="#struct#">
<cfset pos = struct.pos[1] + 1>
<cfset struct = REFindNoCase(regEx, f, pos, true)>
</cfloop>
<hr />
<!--- Find commented out cfdumps --->
<cfset regEx ="<!---\s*?<cfdump.*?>\s*?--->">
<cfset pos = 1>
<cfset struct = REFindNoCase(regEx, f, pos, true)>
<cfloop condition="#struct.pos[1]#">
<cfdump var="#struct#">
<cfset pos = struct.pos[1] + 1>
<cfset struct = REFindNoCase(regEx, f, pos, true)>
</cfloop>
This will find all cfdumps and all commented out cfdumps. You could then
filter out the commented out cfdumps.
Any good?
Adrian
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Andrew Davidson
Sent: 12 April 2006 11:02
To: [email protected]
Subject: [CF-Dev] RegExp
>- see footer for list info -<
OK, I admit I am %*£% at RegExp. I am trying to search code for all
occurrences of <cfdump, but NOT when it surrounded by comment tags, so want
it to return ...
<cfdump var="#foo#">
... but NOT ...
<!--- <cfdump var="#foo#"> --->
... nothing I have tried works! does anyone have a good regexp builder
that they use?
---------------------------------
Yahoo! Messenger NEW - crystal clear PC to PC calling worldwide with
voicemail
_______________________________________________
For details on ALL mailing lists and for joining or leaving lists, go to
http://list.cfdeveloper.co.uk/mailman/listinfo
--
CFDeveloper Sponsors:-
>- Hosting provided by www.cfmxhosting.co.uk -<
>- Forum provided by www.fusetalk.com -<
>- DHTML Menus provided by www.APYCOM.com -<
>- Lists hosted by www.Gradwell.com -<
>- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -<
_______________________________________________
For details on ALL mailing lists and for joining or leaving lists, go to
http://list.cfdeveloper.co.uk/mailman/listinfo
--
CFDeveloper Sponsors:-
>- Hosting provided by www.cfmxhosting.co.uk -<
>- Forum provided by www.fusetalk.com -<
>- DHTML Menus provided by www.APYCOM.com -<
>- Lists hosted by www.Gradwell.com -<
>- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -<
Send instant messages to your online friends http://uk.messenger.yahoo.com
_______________________________________________
For details on ALL mailing lists and for joining or leaving lists, go to
http://list.cfdeveloper.co.uk/mailman/listinfo
--
CFDeveloper Sponsors:-
>- Hosting provided by www.cfmxhosting.co.uk -<
>- Forum provided by www.fusetalk.com -<
>- DHTML Menus provided by www.APYCOM.com -<
>- Lists hosted by www.Gradwell.com -<
>- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -<