Jump to content

[SOLVED] require_once question


Shiny_Charizard

Recommended Posts

I wanted to know if there was anyway to find out if it required a file correctly?

Example 1:

<?php
$req = require_once 'file.php';

if ($req == false) {
echo "File not found!";
}
?>

 

Example 2:

<?php
require_once 'file.php' or exit ("File not found!"); 
?>

 

Thanks you.  :D

Link to comment
https://forums.phpfreaks.com/topic/138429-solved-require_once-question/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.