require in php
snippet in php

include and require in php

user4837

// Include a file, if it can't be found: continue.
<?php
include 'mainfile.php';
?>
  
// Alternatively: Require a file to be imported or quit if it can't be found
<?php
 require 'requiredfile.php';
?>

require in php

user9566

// Require a file to be imported or quit if it can't be found
<?php
 require 'requiredfile.php';
?>

php require

user3206

// Require a file to be imported or quit if it can't be found
<?php
 require 'somefile.php';
?>
  
// Alternatively: Include a file, if it can't be found: continue.
<?php
include 'vars.php';
?>