Thursday, February 16, 2012

Auto Refresh in PHP Script

Using the simple code below, you can auto refresh the output of your php script in a browser. Place the code on the first line of your php script.

<?php header('Refresh: 10'); ?>

**where 10 is the value in seconds, in the code above, your php page will refresh every 10sec regardless if there are changes in the data or none.



1 comment:

  1. thanks man
    please can u tell the code that run only script not entire page this code refresh also page

    ReplyDelete