WordPress.org

Forums

WordPress MU Domain Mapping
[resolved] wpdb::escape is deprecated (3 posts)

  1. pepsiamir
    Member
    Posted 1 year ago #

    when I updated to version 3.6.1 I got this notification:
    wpdb::escape is deprecated since version 3.6! Use wpdb::prepare() or esc_sql() instead.
    I changed the all $wpdb->escape to esc_sql() but I don't know for some reason I get this error:

    Fatal error: Call to undefined function esc_sql() in www\wp-content\sunrise.php on line 11

    http://wordpress.org/plugins/wordpress-mu-domain-mapping/

  2. pepsiamir
    Member
    Posted 1 year ago #

    sorry, I found the answer :)

    Actually, it's already being escaped below so you should be able to replace

    $dm_domain = $wpdb->escape( $_SERVER[ 'HTTP_HOST' ] );

    with

    $dm_domain = $_SERVER[ 'HTTP_HOST' ];

    Ron Rennick
    MultiSite Guru
    Plugin Author

  3. pepsiamir
    Member
    Posted 1 year ago #


Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WordPress MU Domain Mapping
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic