我的wordpress加载整个jQuery UI库
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.core.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.widget.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.position.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.mouse.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.sortable.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.datepicker.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.menu.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.autocomplete.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.resizable.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.draggable.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.button.min.js?ver=1.9.2\'></script>
<script type=\'text/javascript\' src=\'http://example.com/wp-includes/js/jquery/ui/jquery.ui.dialog.min.js?ver=1.9.2\'></script>
这正常吗?我之前没有注意到同样的行为。
最合适的回答,由SO网友:Johannes Pille 整理而成
jQuery UI包含在每个默认WP安装中
是否加载取决于主题和/或插件。
三个选项:
一个接一个地禁用插件(并切换主题),找出谁负责以及是否需要手动禁用插件deregister 它(某个东西,例如插件,可能会断开)