If you need to call a webpage url automatically in every minutes/hours/daily/monthly or a schedule trigger, you can do this by using Task Scheduler in Microsoft Windows or Cronjob in Linux(Unix) system.
This tutorial below will help to setup the scheduled task on both Windows and Linux:
1. Task Scheduler in Windows
- Write a VBS script, ex: schedule.vbs
- Schedule the VBS script
Below the schedule.vbs content:
Call LogEntry() Sub LogEntry() On Error Resume Next Dim objRequest Dim URL Set objRequest = CreateObject("Microsoft.XMLHTTP") URL = "http://www.your_website.com/filename.aspx" objRequest.open "POST", URL , false objRequest.Send Set objRequest = Nothing End Sub |
Just replace the URL variable by your url you want to call and then setup the Scheduled Tasks to run the VBS script at the time specified.
2. Cronjob in Linux (Unix) system
In Linux, the setting up the schedule task to call a webpage url is much easier than Windows.
Just use the command below when you setup your crontab:
curl -sS http://www.your_website.com/filename.aspx |
Just replace http://www.your_website.com/filename.aspx by your full webpage url and that’s all.