Mobile Menu Breaks In Zurb Foundation WordPress Theme

I have been using Zurb’s Foundation framework for a while now, and it seems like every time I create a WordPress theme out of it, I run into issues with the mobile top bar menu breaking.

It turns out the issue has to do with the fact that Zurb doesn’t like the version of jQuery that ships with WordPress.  To fix the problem, two steps need to happen:

  1. Fix the jQuery noConflict issues with foundation.min.js.
  2. Load a different version of jQuery as outlined below.
wp_deregister_script('jquery');
wp_register_script('jquery', 'http://ajax.googleapis.com/ajax/libs/jquery/1.10.1/jquery.min.js');
wp_enqueue_script('jquery');

More detailed instructions can be found here.  I hope this saves you some headache!

Posted in ,

Toby Cryns

Toby Cryns is a freelance CTO, expert WordPress consultant, and teacher.

He offers free advice to improve your freelance biz.

He also publishes small droppings every now and then to twitter.com/tobycryns and twitter.com/themightymo

Follow Toby's contributions on Github and WP.org.