php - Want to replace certain words using preg_replace -


hi i'm trying create database class runs queries. in sent condition parameter function like, id=$no , name='vig'. want replace values mysqli_real_escape_string, id=mysql_real_escape_string($no). this. how can using preg_replace.

i got regex when searching, don't know how use preg_replace. '/(["\'])([^"\']+)\1/'

please don't !

use prepared statements , parameterized queries using mysqli or pdo

how can prevent sql injection in php?


Comments

Popular posts from this blog

hibernate - How to load global settings frequently used in application in Java -

objective c - Ownership modifiers with manual reference counting -

python 3.x - Mapping specific letters onto a list of words -