tags:

views:

49

answers:

1

A gsm device sends data in each 3 seconds. 100 such devices are sending messages and there is a device to accept these messages. I want to insert these messages in mysql table in each 5 minutes using php.

+1  A: 

Use cronjob to execute each 5 minutes a php script that will introduce the date in your db. Php scripts are executed in the webserver without persistence and this is not a php job to execute itself at some intervals. Some things can be done in PHP and for others are other tools available.

Alternatively you could use javascript and setTimeout function to call for a php script but Js is client executed and is not reliable enough for what you want.

Elzo Valugi