PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

jQuery not defined? Empty jQuery function in wp_head();?

  1. Hey guys...I'm running into an odd JS error:

    Error: jQuery is not defined
    Source File:
    Line: 46

    Also here:

    But not, say, here (no GF form):

    This seems to be appearing on any page within our site that has an embedded GF's the rendered source code (empty function) that's triggering there firebug/JS error:


    Any thoughts as to why this function is printing out and/or why it is empty?

    Thanks in advance.

    Posted 4 years ago on Friday January 27, 2012 | Permalink
  2. Trying to bump this up again....I've circled back here, still trying to solve this issue. Turns out that Gravity was putting this empty function in before wp_head(), where I was previously including jQuery. I've remedied that part now, but when an AJAX form (that's key...the AJAX bit, "regular" forms now no longer trip an "undefined" error) is submitted with validation errors...I still get the nagging "jQuery is undefined" error...but the form still seems to perform correctly. Scratching my head here....anyone have an idea what's going on or how to fix it?

    Try submitting one of these forms with not data'll see the errors in Firebug and should see that jQuery is present just two lines ahead of the offending tags....

    Posted 4 years ago on Friday March 2, 2012 | Permalink
  3. gruvii

    You are probably making calls to jQuery before it has loaded. This might be happening if you are loading jQuery and other scripts in the footer/end of the body. What you can do is queue the calls to jQuery and then execute them once jQuery is loaded. Colin has a very good script for doing so here: .

    Posted 4 years ago on Tuesday March 20, 2012 | Permalink


Support Tickets

Open A New Support Ticket
 Open A New Priority Support Ticket *

* Developer license holders only