PHP function that enables runtime execution of a script? Please help!!!

He has: 71 posts

Joined: Nov 2006

I need to know if there is a script that enables execution of a php script at runtime! For example I have a script that reads a .CSV file and loads it into the database and then deletes the contents of the .csv file. Next time when new data is written into the file, the php code has to be executed again manually. I want it to be don't automatically at runtime!!!! or atleast after some time intervals for example after every 10 miuntes the code should get executed!!!

He has: 1,758 posts

Joined: Jul 2002

You could use cron if you're on a *nix server (if your host supports it). Cron allows you to run a script at predefined intervals from every second to up to once a week and everything in between.

Andy

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.