Failu ievietošana PHP

Pieņemsim, ka mums ir viens fails:

index.php<?php
  echo 'index';
?>

Pieņemsim, ka ir arī otrs fails:

test.php<?php
  echo 'test';
?>

Ievietosim otrā faila saturu pirmajā. To var izdarīt ar operatoru include:

index.php<?php
  include 'test.php';
  echo 'index';
?>

To pašu failu var ievietot jebkuru reižu skaitu:

index.php<?php
  include 'test.php';
  include 'test.php';
  include 'test.php';
  
  echo 'index';
?>
Задание 1

Izveidojiet failus file1.php, file2.php, file3.php. Pievienojiet tos savam pamata failam.