javascript - cookie is not a function -


cookie plugin included , working fine on first click, when try click on link different data-id have error $.cookie not function, cookie can not updated new value

$(document).ready(function(){     $('#row').live('click',function(){         var msg_id = $(this).data('id');             $('#table_2').html('loading...');         $.cookie("chat_", msg_id, { expires: 1 });         $('#table_2').load('http://google.com/mail_ajax.php?id='+msg_id,function(){             $("#table_2").html();                  });     });   var chat_d = $.cookie('chat_'); var timeout = setinterval(reloadchat, 3000);     function reloadchat () {      $('#table_2').load('http://google.com/mail2ajax.php?id='+chat_d); } }); 

why can't update cookie on 2nd click, , can problem ?


Comments

Popular posts from this blog

node.js - Mongoose: Cast to ObjectId failed for value on newly created object after setting the value -

gradle error "Cannot convert the provided notation to a File or URI" -

python - NameError: name 'subprocess' is not defined -