Great – here's the update for PHP 5.5
-
With PHP 5.5+ you can’t upload any files properly, or do various other things. It’s because a function used by the script produces an error…
Here’s how to update it – and I’m sorry that this is a direct hack of files.
There are (at least) two files to change, both in this directory:
wp-content/plugins/sermon-browser/sb-includesThe files are: admin.php and ajax.php
You have to replace every occurence of mysql_real_escape_string with esc_sql
So, for example, line 437:
$name = mysql_real_escape_string($_POST[‘name’]);
becomes:
$name = esc_sql($_POST[‘name’]);Why?
Because the mysql_… function is deprecated and produces an error, stopping the script from working. WordPress provides the esc_sql function, and it is up to date.Really there should be a whole re-write of the scripts to use $wpdb->prepare, but that’s another story.
- The topic ‘Great – here's the update for PHP 5.5’ is closed to new replies.