我的主页使用 jQuery Mobile 样式,当我单击链接转到另一个页面 (print.php) 时,它会继续使用 jQuery Mobile 为我的 print.php 设置样式,尽管我没有将此样式添加到此页眉。
页面索引.php:
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.4.5/jquery.mobile-1.4.5.min.css">
<!--This button goes to print.php-->
<a class="btn" href="print.php?id=1">
页面打印.php:
<!-- I have also try to remove jQuery Mobile even if it's not added in the header-->
<div class="container" data-enhance="false">
但是,当我刷新页面时它会起作用。
你能帮我吗?
谢谢
凯文
最佳答案
查看 jQM 文档:
http://demos.jquerymobile.com/1.4.5/navigation-linking-pages/
默认情况下,页面通过 AJAX 加载到当前 DOM 中。要打败这个添加
data-ajax="false"
到您的链接。
关于css - jQuery Mobile 保持下一页的样式,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33261767/