+ Reply to Thread
Results 1 to 5 of 5

Thread: Cron job refresh?

  1. #1
    learning_brain is offline x10 Sophmore learning_brain is an unknown quantity at this point
    Join Date
    Apr 2010
    Location
    UK, Midlands
    Posts
    170

    Cron job refresh?

    I've set up a cron job on a php file, which is reporting as being run correctly...

    However, I have a refresh <META HTTP-EQUIV=Refresh CONTENT="1"> normally when browsing manually.

    Does this refresh continue after it's first been run as a cron job, or does it stop after one page load, or does it over-write the previous loops?

    I don't want thousands of the same php file running as crons!

  2. #2
    misson is offline x10 Spammer misson is a jewel in the rough
    Join Date
    Mar 2008
    Location
    Libertatia
    Posts
    2,506

    Re: Cron job refresh?

    The meta refresh is equivalent to the HTTP Refresh header, which only HTTP user agents pay any attention to. Cron doesn't process HTML and it doesn't load pages, it runs commands. The most processing it ever does with output is e-mail it.

    Which loop are you referring to in "over-write the previous loops?" Each time cron runs a job, it's separate from the other runs.
    Last edited by misson; 07-21-2010 at 05:57 PM.
    Be sure to read all pages linked in this post; they have further information that should prove useful. When asking for help, make sure you follow Eric Raymond's and Jon Skeet's guidelines for prompt, accurate responses. Please answer any questions I ask; they're not rhetorical (probably). Any posted code is intended as illustrative example, rather than a solution to your problem to be copied without alteration. Study it to learn how to write your own solution.
    Misson, not Mission.

  3. #3
    learning_brain is offline x10 Sophmore learning_brain is an unknown quantity at this point
    Join Date
    Apr 2010
    Location
    UK, Midlands
    Posts
    170

    Re: Cron job refresh?

    Welcome back Misson!

    Below is an e-mail report of one cron job

    HTML Code:
    X-Powered-By: PHP/5.2.6
    Content-type: text/html
    
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <META HTTP-EQUIV=Refresh CONTENT="1">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Real Time High Quality Image Crawler.  High Definition Photograph
    Crawler</title>
    <style type="text/css">
    <!--
    
    body {
            font-family: "Courier New", Courier, monospace;
            font-size: 13px;
            color: #EEEEEE;
            background-color: #000000;
    }
    -->
    </style>
    </head>
    
    <body>
    
    <p><a href='index.php'>Home</a></p>
    
    
    <!-- ******************************************* CRAWL FOR IMAGES
    ************************************************-->
            
            
                <hr/><a target = 'blank'
    href='http://www.lbpcentral.com/forums/search.php?do%3Dfinduser%26userid%3D9236%26contenttype%3DvBForum_Post%26showposts%3D1'>http://www.lbpcentral.com/forums/search.php?do%3Dfinduser%26userid%3D9236%26contenttype%3DvBForum_Post%26showposts%3D1</a>
    is being tested.<br/>URL is an html page.  Crawling  for images.<hr/>| |
    | | | | <hr/>Page crawl complete at : 22/07/2010 00:27:01    
            <!--*************************************************** END IMAGE CRAWL
    ****************************************-->
    </body>
    </html>
    
    Which means it looks like it has processed the php correctly
    The "loop" I was referring to was the loop of the refresh only, which is limitless, but if cron doesn't process the html, it won't refresh internally so my (* * * * *) setting should run it once every minute then die.

    Am I right?

  4. #4
    leafypiggy's Avatar
    leafypiggy is offline Community Advocate leafypiggy is on a distinguished road
    Join Date
    Aug 2007
    Location
    Massachusetts
    Posts
    2,228
    It will run the cron until it's finished it's output, or the max execution time is reached, as far as I know.
    Neil Hanlon | x10Hosting Support Representative
    Neil[at]x10hosting.com
    █ I'm always happy to help. Just ask a question in Free Hosting
    Terms of Service IRC

  5. #5
    learning_brain is offline x10 Sophmore learning_brain is an unknown quantity at this point
    Join Date
    Apr 2010
    Location
    UK, Midlands
    Posts
    170

    Re: Cron job refresh?

    Well, it's been running now for over 24 hours and doing what it's supposed to so I guess it's doing what it should!

    Rich

+ Reply to Thread

Similar Threads

  1. Site refresh
    By lemon-tree in forum Review My Site
    Replies: 11
    Last Post: 05-05-2010, 12:37 PM
  2. Ads and refresh
    By mossow in forum Free Hosting
    Replies: 1
    Last Post: 08-27-2008, 04:47 AM
  3. Account refresh
    By n3v3rl0v3 in forum Free Hosting
    Replies: 8
    Last Post: 04-10-2008, 07:15 PM
  4. Any way to refresh the Webdisk?
    By jimmytop in forum Free Hosting
    Replies: 2
    Last Post: 12-23-2007, 12:34 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers