Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/jquery/71.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Jquery $(…)。intercode不是一个函数Phone.js_Jquery_Wordpress_Plugins_Typeerror_Compatibility - Fatal编程技术网

Jquery $(…)。intercode不是一个函数Phone.js

Jquery $(…)。intercode不是一个函数Phone.js,jquery,wordpress,plugins,typeerror,compatibility,Jquery,Wordpress,Plugins,Typeerror,Compatibility,我在Wordpress网站上使用的JS插件called Phone.JS有问题。我在加载jQuery后包含了脚本。这是我用来触发添加phone字段的代码: <code><script type="text/javascript"> jQuery(document).ready(function( $ ) { $('.phone').intercode({ country: 'CA', selectClass: 'coun

我在Wordpress网站上使用的JS插件called Phone.JS有问题。我在加载jQuery后包含了脚本。这是我用来触发添加phone字段的代码:

<code><script type="text/javascript">
    jQuery(document).ready(function( $ ) {
    $('.phone').intercode({
    country: 'CA',
    selectClass: 'countryCodeselect left',
    intercodeFile: './js/countrycodes.json'
    });
    });
    </script></code>

jQuery(文档).ready(函数($){
$(“.phone”).intercode({
国家:'CA',
selectClass:'countryCodeselect left',
intercompile:“./js/countrycodes.json”
});
});
这是我在加载页面时收到的错误:

Uncaught TypeError: $(...).intercode is not a function 未捕获的TypeError:$(…)。intercode不是函数 这个问题发生在phone.js和intlTelInput.min.js上,因此它不是特定于一个插件的
任何建议都很好

感谢您回答我的问题,我发现我的集成出了什么问题。
文件正在加载,但顺序不正确,这使我的脚本无法使用加载的插件功能。
我设法解决了问题,现在电话字段显示正确。
谢谢