php progress bar through database
I need to run long (mintues to hours) matlab code on server side and send the user its progress status (0-100%). I can't send the data directly to client-side because the client may disconnect and check the status hours later.
What should I do? by the way, its an internal network, dozenes of users, no more.
You did not mention the kind of database you are using. If it is mysql and since you are only in an internal network with some dozens users: yes you can use the database. If you want to keep read/write-operations low, you can use the MEMORY-Database-Engine for that purpose.
Also, you can use Memcache for interprocess-communication. One process writes into memcache, and another process reads the value out.