751 posts
  • Bought between 10 and 49 items
  • Exclusive Author
  • Has been a member for 5-6 years
  • Referred between 1 and 9 users
  • United States
CyberShot says

you need to try the code they posted. There is a reason to deregister the jquery

439 posts
  • Bought between 50 and 99 items
  • Europe
  • Exclusive Author
  • Has been a member for 2-3 years
  • Sold between 5 000 and 10 000 dollars
Pixelous says

function my_scripts_method() {
    wp_register_script( 'my_script', get_template_directory_uri() . '/js/my_script'.js', array( 'jquery' ) );

    wp_enqueue_script( 'my_script' );
}
add_action( 'wp_enqueue_scripts', 'my_scripts_method', 1 );

What does number one means?

3202 posts
  • Sold between 5 000 and 10 000 dollars
  • United States
  • Bought between 10 and 49 items
  • Has been a member for 4-5 years
  • Exclusive Author
organicbee says


function my_scripts_method() {
    wp_register_script( 'my_script', get_template_directory_uri() . '/js/my_script'.js', array( 'jquery' ) );

    wp_enqueue_script( 'my_script' );
}
add_action( 'wp_enqueue_scripts', 'my_scripts_method', 1 );

What does number one means?

sets the priority

http://codex.wordpress.org/Function_Reference/add_action
439 posts
  • Bought between 50 and 99 items
  • Europe
  • Exclusive Author
  • Has been a member for 2-3 years
  • Sold between 5 000 and 10 000 dollars
Pixelous says

Thanks, OrganicBeeMedia, i’ll try it.

by
by
by
by
by
by