• Home
  • jQuery
  • jQuery is not defined in WordPress admin

jQuery is not defined in WordPress admin

If you have a WordPress install with many different plugins, you may experience that some jQuery functionality will be lost in the admin panel (i.e. you won’t be able to move the content blocks around your Dashboard). When you open the console (press F12 in most browsers), you will see several errors that will read:
Uncaught ReferenceError: jQuery is not defined
You may also see something like:
Failed to load resource: the server responded with a status of 403 - https://www.yourdomain.com/wp-admin/load-scripts.php?c=1&load%5B%5D=sa…ry-ui-slider,jquery-touc&load%5B%5D=h-punch,iris,wp-color-picker&ver=4.3.1
Here is how you fix both of these with two easy steps…   1. Open the file:
and at the very last line of the file, add
(if it’s not already there) This will get rid of the 403 error.   2. Open the file:
and at the bottom of the file (just above the “require_once” line add
define('CONCATENATE_SCRIPTS', false );
In order to increase performance, WP concatenates scripts (links them together in a chain or series). Unfortunately some servers can’t cope with this, so you’ve just turned that feature off in WordPress. Save both files and enjoy fully-functional WordPress admin panel.