php parse error syntax error unexpected t

I'am getting the following error: "PHP Syntax Check: Parse error: syntax error, unexpected 'qtip' (T_STRING), expecting ')' in your code on line 14" in this code:

<?php
// Always use wp_enqueue_scripts action hook to both enqueue and register scripts
add_action( 'wp_enqueue_scripts', 'enqueue_and_register_qtip_scripts_and_style' );

function enqueue_and_register_qtip_scripts_and_style(){

    // Use `get_stylesheet_directoy_uri() if your script is inside your theme or child theme.
    wp_register_style( 'qtip', get_stylesheet_directory_uri() . '/qtip-js/jquery.qtip.min.css', 'all' );
    wp_register_script( 'imagesloaded', get_stylesheet_directory_uri() . '/qtip-js/imagesloaded.pkg.min.js', true );    
    wp_register_script( 'qtip', get_stylesheet_directory_uri() . '/qtip-js/jquery.qtip.min.js', array('jquery', 'imagesloaded'), false, true );
    wp_register_script( 'tooltip', get_stylesheet_directory_uri() . '/qtip-js/tooltip.js', array('jquery', 'imagesloaded', 'jquery-qtip-min), false, true );

// Add the styles first, in the <head> (last parameter false, true = bottom of page!)
   wp_enqueue_style( 'qtip', null, false, false );

// Using imagesLoaded? Do this.
wp_enqueue_script( 'imagesloaded', null, false, true );
wp_enqueue_script( 'qtip', false, true );
wp_enqueue_script( 'tooltip', false, true );
}
?>

The 14 line says: " wp_enqueue_style( 'qtip', null, false, false ); "

Your help is much appreciated.


Missing ' (single quote) in this line after jquery-qtip-min

 wp_register_script( 'tooltip', get_stylesheet_directory_uri() . '/qtip-js/tooltip.js', array('jquery', 'imagesloaded', 'jquery-qtip-min), false, true );

should be

wp_register_script( 'tooltip', get_stylesheet_directory_uri() . '/qtip-js/tooltip.js', array('jquery', 'imagesloaded', 'jquery-qtip-min'), false, true );

This line

    wp_register_script( 'tooltip', get_stylesheet_directory_uri() . '/qtip-js/tooltip.js',    array('jquery', 'imagesloaded', 'jquery-qtip-min), false, true );

is missing a quote on the jquery-qtip-min param


wp_register_script( 'tooltip', get_stylesheet_directory_uri() . '/qtip-js/tooltip.js', array('jquery', 'imagesloaded', 'jquery-qtip-min), false, true );

在这条线上的jquery-qtip-min之后丢失了一个'。

链接地址: http://www.djcxy.com/p/69888.html

上一篇: PHP邮件错误:第12行解析错误

下一篇: PHP解析错误语法错误意外吨