简体   繁体   English

工具提示有效。 现在:TypeError:$('。tooltip')。tooltipster不是函数

[英]Tooltipster worked. Now : TypeError: $('.tooltip').tooltipster is not a function

I'm rebuilding a simple html/css website meant to be available in 2 languages. 我正在重建一个简单的html / css网站,该网站打算以2种语言提供。 French and english. 法语和英语。 Both need tooltipster. 两者都需要工具提示。 It is working perfectly on the french page. 它在法语页面上运行良好。 But not at all on the english page. 但英文页面上根本没有。

Error : 错误:

TypeError: $('.tooltip').tooltipster is not a function. TypeError:$('。tooltip')。tooltipster不是函数。 (In '$('.tooltip').tooltipster( )', '$('.tooltip').tooltipster' is undefined) (在'$('。tooltip')。tooltipster()'中,'$('。tooltip')。tooltipster'未定义)

The function is define this way in the html. 该函数在html中以这种方式定义。

$(document).ready(function() {
    $('.tooltip').tooltipster();
});

Why is it not working when the english page is the exact copy of the french page ? 如果英文页面与法语页面完全相同,为什么它不起作用?

Visible at : www.krypton.fr/krypton3/index.html ( for the french page ) www.krypton.fr/krypton3/index-en.html ( for the english page ) 在以下网址可见: www.krypton.fr/krypton3/index.html (法语页面) www.krypton.fr/krypton3/index-en.html (英语页面)

It is not an exact copy, you have two scripts included twice on english page, which probably causes the error: 它不是完全相同的副本,您在英文页面上两次包含两个脚本,这可能会导致错误:

在此处输入图片说明

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM