How can I refresh a page with jQuery?

后端 未结 28 2464
刺人心
刺人心 2020-11-22 07:00

How can I refresh a page with jQuery?

28条回答
  •  清酒与你
    2020-11-22 07:14

    All the answers here are good. Since the question specifies about reloading the page with jquery, I just thought adding something more for future readers.

    jQuery is a cross-platform JavaScript library designed to simplify the client-side scripting of HTML.

    ~ Wikipedia ~

    So you'll understand that the foundation of jquery, or jquery is based on javascript. So going with pure javascript is way better when it comes to simple things.

    But if you need a jquery solution, here's one.

    $(location).attr('href', '');
    

提交回复
热议问题