【发布时间】:2019-08-26 11:57:51
【问题描述】:
我在我的页面上使用 jQuery 1.4.5 并在 ajax 请求之前使用加载器:
$.mobile.loading('show', {theme:"e", text:"", textonly:false, textVisible: false});
完成请求后,我将其隐藏:
$.mobile.loading('hide');
这可行,但它会在文本所在的页面末尾生成一个标签。
<div class="ui-loader ui-corner-all ui-body-e ui-loader-default">
<span class="ui-icon-loading"></span>
<h1></h1>
</div>
由于第二个 h1 标签,一些 SEO 工具现在发出警告。
如何从加载器中删除标签?
【问题讨论】:
-
你试过jQuery的
remove()方法吗? -
@PirateofMarmara 在回答之前我还没有看到你的评论,你问我什么时候挂掉的。不客气。
-
不,它是如何工作的?你的意思是 .loading.remove() ?
-
@Arfeo,没问题。你可以在他尝试后回答,这很有效。
-
@merlin,检查this。
标签: jquery jquery-mobile