424,294 Members | 1,891 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,294 IT Pros & Developers. It's quick & easy.

Run a remote script from a local server

code green
Expert 100+
P: 1,726
I have had 3 seperate procedures running happily for a couple of years that I now wish to merge into one.

1. Collect list of email addresses from Access on local server.
Write these addresses to a CSV file.
2. FTP the CSV file from local server to remote server using FTP program
3. Insert email addresses from CSV into MySql and send out an email.

Number one and two I can merge into one PHP script (subscribers.php), but the third (process.php) has to reside on the remote server - about 2000 miles away.
I have been running process.php by Schedule task on a local machine via a browser but for simplicity am now trying to call it from subscribers.php.

Via a browser process.php is simply a php web-page requiring no log-in or password.
How can I make this run from a local php script?
Sep 10 '09 #1
Share this Question
Share on Google+
1 Reply


code green
Expert 100+
P: 1,726
Solved it. Too simple really.
Expand|Select|Wrap|Line Numbers
  1. echo file_get_contents('http://www.web-site/path/to/scripts/process.php');
I just need to work on more efficient handling of script returns.
Thanks
Sep 10 '09 #2

Post your reply

Sign in to post your reply or Sign up for a free account.