I have php file that is to be executed as cronjob, this php file contains some javascript.
I will explain the flow :
- the Php is used to retrive some data(A LIST OF URLS) from DB.
- For each URL Obtained, a Java script API is used.
- THe result Obj returned from API contains data for each url.
- The data is then sent back to as an AJAX Call for each url to a php file .
Can this be implemented Via CRON JOBS ?
OR
Is there any method to schedule javascript to run periodically, like cron for php?
UPDATE: i could manage the javascript call to API with PHP curl ,And the cron Job is getting executed perfectly. But i dont think it is the correct solution to this question may be Node.Js is the solution(i didnt test it yet).