WP update to 3.6 – Missing argument 2 for wpdb::prepare()
-
Hello!
I’ve updated my wp and I’ve got 2 errors:
Missing argument 2 for wpdb::prepare() in /home/…./public_html/wp-content/themes/piano black/sidebar.php on line 75 and defined in /home/…/public_html/wp-includes/wp-db.php on line 992
line 75 of siderbar.php:
$post_datetimes = $wpdb->get_row($wpdb->prepare(“SELECT YEAR(min(post_date_gmt)) AS firstyear, YEAR(max(post_date_gmt)) AS lastyear FROM $wpdb->posts WHERE post_date_gmt > 2000”));
and line 992 of wp-db.php:
function prepare( $query, $args ) {I’ve read on the forum and I think I should add a new argument to WHERE post_date_gmt > 2000 but I haven’t foumd arguments for date expression.
Could somebody help me?
Thanks
- The topic ‘WP update to 3.6 – Missing argument 2 for wpdb::prepare()’ is closed to new replies.