Is it possible to include a header and footer file using HTML? I have my file as a .html and need to be able to include the HTML for the header and footer. Anyone know how I can do this?

You need to use a server-side language for this as HTML is static and cannot perform dynamic actions.

All you need to do is save you page as "mypage.php" and put this piece of code in for your header and footer:

<?php
 
include ("includes/header.php");
 
?>

Hope this helps

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.