Post Types Order
[resolved] Getting error on page: Missing argument 2 for wpdb::prepare()... (2 posts)

  1. hop2us
    Posted 3 years ago #

    Warning: Missing argument 2 for wpdb::prepare(), called in /nfs/c04/h03/mnt/63027/domains/dreamtrampoline.com/html/sandbox/shibui/wp-content/plugins/post-types-order/post-types-order.php on line 191 and defined in /nfs/c04/h03/mnt/63027/domains/dreamtrampoline.com/html/sandbox/shibui/wp-includes/wp-db.php on line 990

    This error won't go away even if I disable all other plugins. Is there something I can do to fix the problem? My line 990 on the wp-db.php is the following:

    function prepare( $query, $args ) {
    if ( is_null( $query ) )

    $args = func_get_args();
    array_shift( $args );
    // If args were passed as an array (as in vsprintf), move them up
    if ( isset( $args[0] ) && is_array($args[0]) )
    $args = $args[0];
    $query = str_replace( "'%s'", '%s', $query ); // in case someone mistakenly already singlequoted it
    $query = str_replace( '"%s"', '%s', $query ); // doublequote unquoting
    $query = preg_replace( '|(?<!%)%f|' , '%F', $query ); // Force floats to be locale unaware
    $query = preg_replace( '|(?<!%)%s|', "'%s'", $query ); // quote the strings, avoiding escaped strings like %%s
    array_walk( $args, array( $this, 'escape_by_ref' ) );
    return @vsprintf( $query, $args );


  2. hop2us
    Posted 3 years ago #

    never mind! I just saw that I hadn't updated the plugin... it's all better now!!!!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic