Ajax (1) Apex Class (12) Apex Trigger (2) Community (2) Home Page (1) HTML (4) Integration (3) JS (7) KB (1) Label (1) Licenses (1) Listing (1) Log (1) OOPs (5) Sharing (1) Static Resource (1) Test Class (3) URI (1) Visualforce (10)

Sunday 11 January 2015

How to Auto refresh a page one time.

<script type="text/javascript">  $(document).ready(function(){    //Check if the current URL contains '#'   if(document.URL.indexOf("#")==-1)  {  // Set the URL to whatever it was plus "#".  url = document.URL+"#";  location = "#";    //Reload the page  location.reload(true);    }  });  </script> 

No comments:

Post a Comment