我有一些 html 代码<div class="post">
里面。我想用 javascript 对它们进行分页。我怎样才能做到这一点? (我知道我可以用 PHP 来做,但我只想用 JS 来做)
我的 php 生成的 html 看起来像这样:
<body>
<div id="content">
<div class="post">
post content
</div>
<div class="post">
</div>
...
</div>
</body>
也许使用 jquery 是最好的? (我正在使用 jquery ajax 将 html 加载到内容中)
是的,有一个 jquery 插件可以很好地工作https://github.com/gbirke/jquery_pagination https://github.com/gbirke/jquery_pagination
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)