,
 

PHP: Reuire() Function :-

Techno PHP

The require () function is used to the attach (get) all the data from the file . If you want to use another file data on a page so you can use the requre () function. If there is any problem in loading a file, then the require() function generates a fatal error and hold the execution of the script.

. It is recommended to use the require() function instead of include(), because scripts should not continue executing if files are missing or misnamed.
If we have created three file of index page .
1.header.php

2.content.php

3.footer.php

Now we will include these files in index.php page .

Example

<html>
<body>
<?php require("header.php"); ?>
<?php require("header.php"); ?>
<?php require("header.php"); ?>
</body>
</html>
<
If any error occurred, you will get plain warning messages or fatal error messages or nothing at all.This depends on your PHP Server configuration.