Fatal error: Call to undefined function mysql_real_escape_string() in /var/www/engine/database.php on line 38
I can still connect to the database however. Why is it not available?
I am using PHP version 7.1.4
The real_escape_string() / mysqli_real_escape_string() function escapes special characters in a string for use in an SQL query, taking into account the current character set of the connection.
This extension was deprecated in PHP 5.5. 0, and it was removed in PHP 7.0.
The aim of the function mysqli_real_escape_string is to try to ensure that the data that is sent to the mysql server is safe - it attempts to remove characters that are often used in sql injection.
mysql_
has been removed in php 7. try mysqli_real_escape_string
instead of mysql_real_escape_string
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With