Setting the cache in jQuery $.post() to be false?

前端 未结 4 517
难免孤独
难免孤独 2020-12-09 12:48

I have this code:

$.post(\"php/tagNotifUnsub.php\", $(\"#tagNotifUnsub\").serialize(), function(){ 
            $(\'#tagSubDiv\').load(\'tags.php #tagSubDiv\         


        
4条回答
  •  孤街浪徒
    2020-12-09 13:14

    You mention $.ajax

    You can turn caching off for ajax like this:

    $.ajax({
            url: "/myURL?",
            cache: false,
        });
    

提交回复
热议问题