Пожалуйста, проверьте код ниже
$(document).ready(function(){
var href;
if(href!=null)
{
setContainerHtml($.cookie("activeElementHref"));
};
$('nav ul li a').click(function(e){
e.preventDefault();
href= $(this).attr('href');
$.cookie("activeElementHref", href)
setContainerHtml(href);
});
});
function setContainerHtml(href) {
$.ajax({
type: "POST",
url: "baker.php",
data:{send_txt: href},
success: function(data){
$('#aside-right, #intro').css('display','none');
$('#main-content').fadeOut('10', function (){
$('#main-content').css('width','700px');
$('#main-content').css('margin','-30px 0 0 100px');
$('#main-content').html(data);
$('#main-content').fadeIn('8000');
});
}
});
}
Файл cookie не работает, нажатие ссылки не сохраняется, когда я нажимаю кнопку Обновить индекс HTML-страница отображается