• I’ve built a content slider that works perfectly on my local computer but within wordpress it’s stumbling on the following:

    var begin_position = jQuery(“#individual_story_wrapper”).position().top;

    I’m getting the follow error:
    : jQuery(…).position(…) is undefined

    Yet locally, the slideshow runs fine and I can see the position being changed as I animate the individual_story_wrapper up and down.

    The only difference that I can see is the link to the google hosted jquery. Otherwise, everything is the same.

Viewing 1 replies (of 1 total)
  • Moderator bcworkz

    (@bcworkz)

    I’m sorry no one responded to your question. You’ve probably figured this out by now, but for anyone else finding this via search, one should not reference external jQuery libraries in WordPress. WP has its own local version that will be loaded when it’s referenced as a dependency when you enqueue your script. In WP, one should always enqueue scripts. More information can be found in Function Reference/wp enqueue script.

Viewing 1 replies (of 1 total)
  • The topic ‘jquery .position().top undefined when in wordpress’ is closed to new replies.