Cronjob for auto execute script url

Discussion in 'Site & Server Administration' started by digitcoder, Mar 6, 2010.

  1. #1
    Hi there,

    Have been searching for commands to setup cronjob for auto executing a script by url each day at 0:00 server time, but I only could find commands to do this for a file, not an url. Could anyone help me out?

    Currently my command for cronjob ( using cPanel if that matters ) is:

    
    0 0 * * * http://www.mywebsite.net/update_file.php?key=key
    
    Code (markup):
    And before the command I also configured to run this command daily.

    Thanks in advance.
     
    digitcoder, Mar 6, 2010 IP
  2. bseniuc

    bseniuc Peon

    Messages:
    4
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Try
    0 0 * * * wget -O /dev/null http://www.mywebsite.net/update_file.php?key=key
    Code (markup):
    This should work.
     
    bseniuc, Mar 6, 2010 IP
  3. digitcoder

    digitcoder Peon

    Messages:
    2
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Will try that out, thank you! :)
     
    digitcoder, Mar 6, 2010 IP