Caldera Forms and The WP Variable


Caldera Forms 1.8 and later uses JavaScript libraries from WordPress core that will not be loaded properly if WordPress core embeds or emoji scripts are not loaded. In the JavaScript console the error “uncaught reference error, variable wp not defined.”

In Caldera Forms 1.8.5 or later, if the current logged in user can edit forms, the notice  “The variable wp is not defined, your forms can not function as expected.” displayed above your Caldera Forms. If you see this notice, its likely that you have had the JavaScript error and where not aware of it. This document will help you fix this issue.

Note, the JavaScript console error may be present, without the warning above the form on Caldera Forms 1.8.0-1.8.4. This document is useful for those situations as well.

Causes Of The Caldera Forms WP Not Defined Warning

The primary causes of this notice appearing are:

How To Fix The Caldera Forms WP Not Defined Error

If you see the Javascript error “uncaught reference error, variable wp not defined” when submitting forms or see the notice “The variable wp is not defined, your forms can not function as expected” these are the steps you can take to resolve this issue:

  • If you are using Disable Embeds plugin, please deactivate it.
  • If you are using WP Rocket, make sure the disable emoji and disable embeds settings are turned off.
  • Check for other ways you have disabled emojis or embeds and remove those.

If that does not work:

Other Notes