Reputation: 99
I have 2 php files. One which stores various xml files in a database and other php files takes those xml files as input, parse them and produces a another table having various information about the xml files.
I want this work to be scheduled for everynight. I want to do this via batch files but I have no idea how to use .bat files, and how to incoorporate the php script in it.
Need help/guidance.
Thanks. Yogesh
Upvotes: 0
Views: 785
Reputation: 106
OR
Upvotes: 0
Reputation: 330
I assume you are doing this on a windows machine as you mention a .bat file
PHP can be executed from a command line e.g. a dos shell
http://www.php.net/manual/en/features.commandline.introduction.php
Once you get it working manually just put what you are typing in a text file. (.bat)
You can execute the .bat file (a program file to windows) when you want using a scheduler, e.g. http://windows.microsoft.com/en-GB/windows7/schedule-a-task
Upvotes: 3