Ghost21 Posted September 19, 2008 Share Posted September 19, 2008 When I and entry to an sql database and it has a character that sql doesn't like it seems to crash the program. How can I filter out ' " ; : < > !@#$%^&* | \ ~` <---- These characters,. Thanks Link to comment Share on other sites More sharing options...
oren Posted September 19, 2008 Share Posted September 19, 2008 I dont know much about sql but i guess can do _URLEncode and then send the text as it is , search it in the forum and redefine it so sot you. About removing that characters.. I think you can do StringReplace and i guess you can do it in one time by using StringRegExpReplace but i assume that it will be harder... Link to comment Share on other sites More sharing options...
jokke Posted September 19, 2008 Share Posted September 19, 2008 (edited) Here: $input = "; : < > !@#$%^&* | \ ~` Testing..." $output = StringRegExpReplace($input,"[ '; : < > !@#$%^&* | \\ ~`]","") ConsoleWrite( $output & @CRLF) Edited September 19, 2008 by jokke UDF:Crypter a file encrypt / decrypt tool with no need to remember a password again. Based on Caesar cipher using entire ASCII Table.Script's: PixelSearch Helper, quick and simple way to create a PixelSeach.Chatserver - simplified, not so complicated multi-socket server.AutoIT - Firewall, simple example on howto create a firewall with AutoIt. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now