SECURITY UPDATE: Removed usage of mysql_real_escape_string and replaced ...

...it with Moodle's sql_like_escape

Use of mysql_real_escape_string may result in errors, depending on the character encoding specified in php.ini. Since PHP 5+, mysql_real_escape_string has been deprecated.