我想通過drupal 7中的theme.info添加foundation.js和foundation-topbar.js版本4到page.tpl.php。我可以看到jquery和正確添加基礎js文件-jquery上述基礎js文件 - 但我得到這個錯誤:
TypeError: $ is undefined
(Foundation.zj, this, this.document)); // foundation-topbar.js line 206
ReferenceError: Foundation is not defined
(Foundation.zj, this, this.document)); // foundation-topbar.js line 206
可能是衝突。可能值得在這裏尋找:http://api.jquery.com/jQuery.noConflict/或使用'jQuery'而不是'$' – jchapa 2013-03-03 07:51:15
請參閱[在Drupal 7中管理JavaScript](http://drupal.org/node/ 756722)爲Drupal的具體信息(雖然它是相同的東西) – Clive 2013-03-03 16:13:32