正确加载命令jQuery,Bootstrap和select2 .js文件(Correct loading order jQuery, Bootstrap and select2 .js files)
我想问一下,在你的网页中是否有一个特定的加载顺序应该用于jQuery,Bootstrap和Select2 JavaScript文件,以避免任何潜在的错误,以及是否应该有一个最合适的加载顺序。
I would like to ask if there is a specific loading order in your web pages that should be used for the jQuery, Bootstrap and Select2 JavaScript files in order to avoid any potential errors and if there should be one what would be the most appropriate one.
原文:https://stackoverflow.com/questions/47452357
最满意答案
你是对的,页面头部不允许
<p>
和<img>
标签。 当然HTML验证器应该抱怨。 它不知道您的访问者是否启用了脚本。我会在结束
</body>
标记之前移动整个<noscript>
部分。 该部分的工作方式是,如果某人禁用了JavaScript,则会加载一个小的不可见图像。 Piwik记录这个图像被作为访问加载(请注意,图像源是Piwik PHP脚本)。You are right that
<p>
and<img>
tags aren't allowed in the page head. Of course the HTML validator should complain. It doesn't know if your visitors will have scripting enabled or not.I would move the entire
<noscript>
section before the closing</body>
tag. The way that section works, is that if someone has JavaScript disabled, it loads a small invisible image instead. Piwik records this image being loaded as a visit (note that the image source is a Piwik PHP script).
相关问答
更多-
将HTML复制到.modal-body ,只复制HTML,需要Summernote的JavaScript事件。 我认为你在副本之后发布Summernote事件会更好,如下所示: $(".home-options a").click(function() { var _modal = $('#homeOptionModal'); var _this = $(this); var _header = _this.find("h1").text(); var _tcontent = ...
-
Angulartics不会干扰供应商库; 如果你愿意,你仍然可以直接使用它。 Angulartics does not interfere with the vendor library; you can still use it directly if you want.
-
好的,我自己找到了答案。 这是第六次尝试,最终我成功了。 我只需要改变过滤器代码的定义和用法。 其他一切都很好: FilterDeclare PIWIK_token FilterProvider PIWIK_token SUBSTITUTE resp=Content-Type $text/html SUBSTITUTE 's|