Many times, while making web pages, we want to repeat certain part of pages in other pages. CakePHP has such facility by which one can extend view in another view and for this, we need not repeat the code again. The  extend()  method is used to extend views in  View  file. This method takes one argument, i.e., the name of the view file with path. Don’t use extension .ctp while providing the name of the View file.   Example   Make changes in the  config/routes.php  file as shown in the following program.   config/routes.php  <? php    use  Cake \Core\Plugin ;     use  Cake \Routing\RouteBuilder ;     use  Cake \Routing\Router ;      Router :: defaultRouteClass ( 'DashedRoute' );     Router :: scope ( '/' ,  function  ( RouteBuilder  $routes )  {        $routes -> connect ( 'extend' ,[ 'controller' => 'Extends' , 'action' => 'index' ]);        $routes -> fallbacks ( 'DashedRoute' );     });     Plugin :: rout...