php - Call a Controller in every 10 Seconds on CodeIgniter -


i made research on site couldn't find answer, decided yo ask this.

i'm getting data via xml , xml renews every 10 seconds. so, have re-run controller in every 10 seconds. can not make via cron know not allowing cron jobs under 1 minute.

thanks in advance.

use sleep , run script once.

while(true)  {   sleep(10);   // parse xml } 

or if wanna limit time, change true limit , increment in end of block. problem within solution if xml parsing takes 5 seconds, called in each 15 seconds, make arrangement according this.


Comments

Popular posts from this blog

powershell Start-Process exit code -1073741502 when used with Credential from a windows service environment -

twig - Using Twigbridge in a Laravel 5.1 Package -

c# - LINQ join Entities from HashSet's, Join vs Dictionary vs HashSet performance -