Setup cron job on local server

Go to Startmenu->All Programs->Accessories->System Tools->Task Scheduler->create Task

In the new window we having 4 options

1. General (Give the Task name and for testing you can select “Run when User is logged in“)

2. Trigger (You can Select the running interval as “daily,weekly,monthly”. )

3. Action (This is most important part.Select a Mozilla firefox as the “program/script” and in the Argument provide the URL to fire with Mozilla firefox like http://www.waytocode.com/mycron.php).

To DO:
Create a task give Running time in Trigger setting.Then in Action setting option in the “Program/Script” command textbox type
C:\xampp\php\php.exe
and in the “Add arguments (optional)” type
-f c:/xampp/htdocs/mycron.php

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s