Home  >  Article  >  Backend Development  >  pjax问题

pjax问题

WBOY
WBOYOriginal
2016-06-06 20:15:131019browse

pjax问题

我如果先点击除了相册之外的导航栏都是刷新的 倘若我先点击相册展示就可以实现全部都是PJAX 请问这是怎么还是呢

<code>$(function() {
    $(document).pjax('a[target!=_blank]', '#content', {fragment:'#content', timeout:6000}); //这是a标签的pjax。#content 表示执行pjax后会发生变化的id,改成你主题的内容主体id或class。timeout是pjax响应时间限制,如果在设定时间内未响应就执行页面转跳,可自由设置。             
    });</code>

回复内容:

pjax问题

我如果先点击除了相册之外的导航栏都是刷新的 倘若我先点击相册展示就可以实现全部都是PJAX 请问这是怎么还是呢

<code>$(function() {
    $(document).pjax('a[target!=_blank]', '#content', {fragment:'#content', timeout:6000}); //这是a标签的pjax。#content 表示执行pjax后会发生变化的id,改成你主题的内容主体id或class。timeout是pjax响应时间限制,如果在设定时间内未响应就执行页面转跳,可自由设置。             
    });</code>

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn