PHP
  Home arrow PHP arrow Page 3 - PHP CLI and Cron
IBM developerWorks
Dev Articles Forums 
ADO.NET  
Apache  
ASP  
ASP.NET  
C#  
C++  
ColdFusion  
COM/COM+  
Delphi-Kylix  
Design Usability  
Development Cycles  
DHTML  
Embedded Tools  
Flash  
Graphic Design  
HTML  
IIS  
Interviews  
Java  
JavaScript  
MySQL  
Oracle  
Photoshop  
PHP  
Reviews  
Ruby-on-Rails  
SQL  
SQL Server  
Style Sheets  
VB.Net  
Visual Basic  
Web Authoring  
Web Services  
Web Standards  
XML  
Dedicated Servers  
Actuate Whitepapers 
VeriSign Whitepapers 
IBM® developerWorks 
Sun Developer Network 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
PHP

PHP CLI and Cron
By: Jason Lam
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 52
    2003-04-05

    Table of Contents:
  • PHP CLI and Cron
  • Cron
  • Final Words

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT

    Stay one step ahead of the competition. Evaluate and give feedback on some of the hottest web development tools on the market today. Make your opinion heard! Click Here

    PHP CLI and Cron - Final Words


    (Page 3 of 3 )

    Future of PHP

    PHP CLI and how PHP CGI will be invoked maybe changed in the future and possible can affect your use of PHP. It has been said php CGI binary will be renamed to php-cgi and the php CLI will be just php. There has been talk as well just to leave the way is or even merge the both CLI and CGI into one.

    The main reason why CLI needs to be included into PHP by default is because PEAR requires the PHP binary to run. For more information visit the PHP website, http://www.php.net.

    Tips

    When making entries into Cron make a note of what user you doing this with. The Cron job may not run properly if the right permission is not assigned. As well make sure if your PHP script is accessing any external programs such as Sendmail that I has the proper permissions as well.

    Other things to look out for are the environment settings. For example, if the PHP script is accessing Java classes you may have to wrap the PHP script with a shell script. Where the shell script includes the appropriate settings for both the Java Path and Classpath.

    If accessing $_SERVER["argv"] and $_SERVER["argc"] do not work for you may want to try simply accessing the variables $argv and $argc, register globals need to be set on. This mostly like the case for older version of PHP.


    DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware.

       · This is obviously an old article, but even so there is no excuse for recommending...
     

    PHP ARTICLES

    - Making Usage Statistics in PHP
    - Installing PHP under Windows: Further Config...
    - File Version Management in PHP
    - Statistical View of Data in a Clustered Bar ...
    - Creating a Multi-File Upload Script in PHP
    - Executing Microsoft SQL Server Stored Proced...
    - Code 10x More Efficiently Using Data Access ...
    - A Few Tips for Speeding Up PHP Code
    - The Modular Web Page
    - Quick E-Commerce with PHP and PayPal
    - Regression Testing With JMeter
    - Building an Iterator with PHP
    - PHP Frontend to ImageMagick
    - Using PEAR's mimeDecode Module
    - Incoming Mail and PHP







    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway