Little code refactoring and handle the case of going back to the first page visited. re #73
This commit is contained in:
parent
c96d629ad0
commit
e9065b9c29
|
@ -117,11 +117,8 @@
|
||||||
$.get('templates/default/frontpage.html', function(data){
|
$.get('templates/default/frontpage.html', function(data){
|
||||||
template = doT.template(data);
|
template = doT.template(data);
|
||||||
$.getJSON('<?php echo "getJSON.php?" . str_replace ("&", "&", $_SERVER["QUERY_STRING"]); ?>', function(data) {
|
$.getJSON('<?php echo "getJSON.php?" . str_replace ("&", "&", $_SERVER["QUERY_STRING"]); ?>', function(data) {
|
||||||
result = template (data);
|
updatePage (data);
|
||||||
document.title = data.title;
|
history.replaceState(data, "", window.location);
|
||||||
$(".container").html (result);
|
|
||||||
|
|
||||||
ajaxifyLinks ();
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue