Deep linking using BBQ plugin

删除回忆录丶 提交于 2019-12-24 20:43:37

问题


I'm not sure what it is that I am doing wrong here. When I open the HTML code for it, it just crashes. Does anyone have any idea if my syntax is wrong, or I'm just fundamentally not understanding how the BBQ plugin works? Thanks so much!

$.bbq.pushState({ 
    lat: pointArray[0][0].lat(), 
    lng: pointArray[0][0].lng()
});

$(window).bind('hashchange', function(e) {
    var searchParams= e.getState();
    pointArray[0][0] = new google.maps.LatLng(searchParams.lat, searchParams.lng);    
    mapSearch(); 
}); 

$(window).trigger('hashchange');

In Chrome, it says that I am calling method pushState of undefined. Am I suppose to declare lat/lng outside before?

来源:https://stackoverflow.com/questions/11597631/deep-linking-using-bbq-plugin

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!