It is definately a good idea to learn phplib and all such available tools, but sometimes it's kinda fun to make them yourself, even if only once. That way you can be sure you can create a site equally easily if phplib is unavailable for whatever reason.
Anyway, about that embedding.
There are a few things I particularly like.
One technique (the one I use) is to enclose anything you might want to change in php coding.
Here's a tiny example:
<?php
include("globals.php");
$page_title = "Shop";
echo $html_header;
// Content goes here
echo $html_footer;
?>
globals.php:
<?php
$bgcolor = "#E7D5A3";
$text_color = "#000000";
$html_header = "<head><title>$page_title</title></head><body bgcolor=$bgcolor text=$text_color>";
$html_footer = "</body>";
?>
I don't like .inc files for various security reasons, and the fact I don't have access to changing apache/php settings.
The idea here is say I wanted to totally change the background and text colors of the entire site. All I need to do is go into globals.php, and change 2 values (this can even be done dynamically upon user-input if you wish to make such an option available).
Another option is moving the entire <body> tag into a variable, allowing for you to also add background images and the like.
The simple concept is, if you may at any point need to change something that is used in multiple files, place that data in an included file.
With $html_footer, you could add in copyright information or a saying of the day, whatever you come up with.
I use $html_header incase I want to add metatags to all my pages at once, and it just saves me retyping the same old information in every single html file.
Note: using include_once() is prefered if you have PHP 4.
The general concensus that I've heard is do not embed your html inside your PHP, unless you have a very few amount of pages, or want to control each page in a totally seperate way.
Just one of the many reasons I love PHP is because you have so many options to choose from 😉