This code does a pretty good job of preventing errors in a verity search
but it also obliterates quite a lot of the advanced functionality: 

<CFSET searchstring = trim(rereplacenocase(trim(searchstring),"^or |^and
|\|@|#chr(34)#|'|<|>|!|=|\(|\)|\[|\]|#chr(44)#","","all"))>

Does anyone have a re which is a bit more subtle?  In particular it
would be nice to allow characters eg '"[]() which are permissable, but
only in matching pairs.

--
Regards;

Richard Meredith-Hardy
-------------------------------------------------------------
[EMAIL PROTECTED]
Tel: + 44 (0)1462 834776 FAX: + 44 (0)1462 732668

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to