How can I refresh a page with jQuery?

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

How can I refresh a page with jQuery?

28条回答
  •  不知归路
    2020-11-22 07:38

    You can write it in two ways. 1st is the standard way of reloading the page also called as simple refresh

    location.reload(); //simple refresh
    

    And another is called the hard refresh. Here you pass the boolean expression and set it to true. This will reload the page destroying the older cache and displaying the contents from scratch.

    location.reload(true);//hard refresh
    

提交回复
热议问题