Friday, 30 January 2015

Include Vs Require

The only difference in Include & Require:


  • Include show warning if any problem in file loading and script will continue.
  • Require show fatal error and if any problem in file loading its stop the script.

Tips:

  • Use Include when file is not necessary in application so its continue script if there is any problem in file.
  • Use Require when file is important for an application so its stop the script if there is any problem in file.

No comments: