Header, Footer in WordPress -4

Header, Footer in WordPress -4

get_header() and get_footer() includes the header and footer template for a customize theme.


<!DOCTYPE html>



      <meta charset=”UTF-8″>

      <meta name=”viewport” content=”width=device-width, initial-scale=1.0″>

        <?php wp_head();?>



[HTML and PHP Code of Header]

Wp_head () prints scripts or data in the head tag of HTML


[HTML and PHP Code of  Footer ]

<?php wp_footer();?>


Wp_footer () prints scripts or data before the closing body tag of HTML


For new pages create new php file i.e. page-event[custom-name] in Visual studio

<? php

// Template Name: [page-name]

get_header ();

[HTML and PHP Code ]

get_footer ();


Now create a new page in wp-admin then choose template for specific page

Post Your Comments & Reviews

Your email address will not be published. Required fields are marked *