我已经使用url hash为ajax搜索做了回复功能。它工作正常,但问题是滑块和一些其他动画,滑块冻结,我无法移动爬虫。
var hashState = false;
var historyState = false;
var historyArr = new Array();
// back content with specific hash
window.onhashchange = function(){
var hash = location.hash;
if( ! hashState && hash && historyArr[hash])
{
$('.diamond-filter').html(historyArr[hash]);
historyState = true;
$('#diamond_search').ajaxForm(diamonds_options);
$('#diamond_search').submit();
}
hashState = false;
return false;
};
function logSearch(hash)
{
historyArr[hash] = $('.diamond-filter').html();
}
我想它失去了一些联系。如何在不重新启动的情况下保留或恢复?