Miscellaneous

  Home arrow Miscellaneous arrow Page 5 - Controlling PHP
MISCELLANEOUS

Controlling PHP
By: bluephoenix
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 1
    2004-06-15

    Table of Contents:
  • Controlling PHP
  • php.ini
  • httpd.conf
  • Window's Registry
  • PHP Scripts
  • Conclusion

  •  
     

    SEARCH CODEWALKERS

    TOOLS YOU CAN USE

    advertisement

    Controlling PHP - PHP Scripts


    (Page 5 of 6 )

    The final way one can control the behavior of PHP is by using the function ini_set function that sets the value of a configuration option. The ini_set function accepts two arguments: the first is the option name, the second is the option's value. The new value is kept throughout the execution of the current script, after which PHP reverts back to its original configuration.

    Options which are boolean in nature are set to either 1 (on) or 0 (off). Other options are set with quoted/string values.

    This method of configuration can be especially useful for satisfying per-script needs, such as specifying the include path for files, the maximum allowed execution time for a script and error reporting. Here's an example usage:

    <?php
    ini_set
    ("max_execution_time""60");
    ini_set("display_errors"1);
    ?>

    In this example, ini_set is used to extend the maximum allowed execution time of the script to 60 seconds. The display errors option has been set to override a production environment's suppression of errors.

    More Miscellaneous Articles
    More By bluephoenix

    blog comments powered by Disqus

    MISCELLANEOUS ARTICLES

    - Oracle Database XE: Indexes and Sequences
    - Modifying Tables in Oracle Database XE
    - Oracle Database XE: Tables and Constraints
    - More on Oracle Databases and Datatypes
    - Oracle Database XE Datatypes: Datetime and L...
    - Oracle Database XE Datatypes: Character and ...
    - From Databases to Datatypes
    - Firefox 3.6.6 Released with Improved Plug-in...
    - Attention Bloggers: WordPress 3.0 Now Releas...
    - Reflection in PHP 5
    - Inheritance and Other Advanced OOP Features
    - Advanced OOP Features
    - Linux from Scratch V.6.6 Review
    - Linux Gaining in Strength
    - Install Slackware on Your Old PC


    © 2003-2012 by Developer Shed. All rights reserved. DS Cluster 5 - Follow our Sitemap