SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Member
    Join Date
    Dec 2000
    Posts
    12
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi anyone out there !

    Basic problem : How can I start a php-File which doesn't produce any output ? I only want it to copy several files and manage some database-functions .

    I tried to send http-header204 : *No Content* but it didn't work (Server Error). Is this because php always begins with header 200 ?

    Thanks a lot
    pheidrias

  2. #2
    Your Lord and Master, Foamy gold trophy Hierophant's Avatar
    Join Date
    Aug 1999
    Location
    Lancaster, Ca. USA
    Posts
    12,305
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    After your done doing your work, use the Header Function to redirect the page to where you want it to go.

    header("Location: somepage.html");

    As long as there is no output before this, including any whitespace it should work.
    Wayne Luke
    ------------


  3. #3
    ********* wombat firepages's Avatar
    Join Date
    Jul 2000
    Location
    Perth Australia
    Posts
    1,717
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    or just include the script in an occaisionally run page, if it produces no output then it will not affect the page it is included on, or better still see if your host will set up a CRON job for you scheduling the script to run every x mins/hours whatever.

  4. #4
    SitePoint Member
    Join Date
    Dec 2000
    Posts
    12
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for your replies...

    So there's no real possibility to run a php as standalone program ? I don't want to cause any traffic or reload actions...

    firepages : Can you tell īme, how to configure such CRON-Jobs ? Is there any good web-source concerning this ?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •