0

I have a Cronjob which is done every ten minutes on my site, for example on the page http://www.example.com/example.php

Sometimes, in the administration panel of my website, when the admin have made some modification, i want to automatically launch the script on example.php.

So my question is : Is there a way to visit an url, without showing it ? My goal is that the server read the page, not the admin, because the example files can be very heavy.

I have read this thread, but it's not clear to me : How can I simulate a visit to a url?

Thanks you for your advice !

Community
  • 1
  • 1
Damien
  • 333
  • 1
  • 3
  • 17
  • wouldn't curl do the job? if not look at simplexml_load_file. read this http://stackoverflow.com/questions/14785735/need-equivalent-php-httpwebrequest-and-stream-or-curl-code-for-this-net-code – Liam Sorsby Oct 31 '13 at 11:03

2 Answers2

2

You can use wget/curl to silently grab the content of a page.

wget -O – -q http://example.com/urltofetch.html >/dev/null 2>&1
Anthony Sterling
  • 2,451
  • 16
  • 10
1

Use PHP - curl make a standard code and with the single you can upload data to server.. http://coderscult.com/php-curl-tutorial-and-example/

Dinesh Patil
  • 1,042
  • 10
  • 13