Codeigniter escape_str() function

This function will escape all data, regardless of type.

$sql = " INSERT INTO table (name)
  VALUES(" . $this->db->escape_str( $name) . " ) " ;
$this->db- >query($sql) ;

Enjoyed this post? Share it!

 

Leave a comment

Your email address will not be published.