javascript - How to simulate Click in cronjob? -
i'm using web service transfer files ftp dropbox. want update version in dropbox every week. right have go service , manually click 'transfer now' button every week.
i'd create cron job or other automated solution runs every week, logs service , clicks on set of buttons interval of 60s between each button (to give service enough time start action).
the buttons nothing div id , actual click on triggers js listener.
the way going approach write curl script in php loads page , tries action occurs when button pressed (i.e. triggers listener). it's not easy though , before spend time on it, i'd know if can think of simpler approach?
the basic structure of process should be:
- runs automatically every week (e.g. on lamp server or using web service)
- logs service (simple form triggering post request)
- clicks on buttons class 'buttonnow' , waits x amount of seconds between clicks
- ideally send kind of confirmation once task has been completed
Comments
Post a Comment