regex - I need php regular expression to allow the all leters, numbers, dollar sign, commas, double & single quotes -


i looking regular expression allows:

(a-za-z) letters, (0-9) numbers, ($) dollar sign,  (,) commas (") & (') double , single quotes  

so far have - '/[^a-za-z0-9,_ %\[$,\]\.\(\)%&-]/s'

the idea strip out special characters

/^[a-za-z0-9$,"']+$/

this not work reason allowing special characters show not supported page encoding. - bit.ly/gdiyc9 need use regex posted remove special characters , allow characters explained before. thanks

thanks

rather stripping special characters, can match required character, , smaller regex.

you can use this:

/^[a-za-z0-9$,"']+$/ 

Comments

Popular posts from this blog

c++ - CryptStringToBinary API behavior -

c++ - Correct method for redrawing a layered window -

java.util.scanner - How to read and add only numbers to array from a text file -