This is a verbatim copy of the script makepages that is also present in this directory. Unfortunately, some browsers (at least Netscape) try to guess the content of the page and trip over the HTML fragments in it, creating a real mess. I'd be interested to hear if this happens to you. Here's the script formatted for HTML so that it can be unformatted again. If you want to copy it, use makepages; it will possibly have been updated, and it should store properly.
#!/bin/sh
#
echo $0 $*
PREV=""
while [ $# -gt 0 ]; do
PAGENO=`echo $1 | sed 's:.jpeg::'`
NEXT=`echo $2 | sed 's:.jpeg::'`
echo PAGE $PAGENO NEXT $NEXT
cat <<EOF > $PAGENO.html
<!-- Hey, emacs! Edit this file in -*- html-fill -*- mode! -->
<!-- $Id: makepages.html,v 1.2 2004/08/16 00:56:18 grog Exp $ -->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title></title>
</head>
<body>
<center>
<h1>Yvonne's recipe book, page $PAGENO</h1>
</center>
<center>
<font size="-1">Last update: $Date: 2004/08/16 00:56:18 $</font>
</center>
<table summary="footings" width="100%">
<tr>
EOF
if [ "$PREV" != "" ]; then
echo >> $PAGENO.html "<td width="25%"><a href="$PREV.html">Previous page ($PREV)</a></td>"
fi
echo >> $PAGENO.html "<td width="25%"><a href="/grog/recipes/yvonne/">Overview page</a></td>"
echo >> $PAGENO.html "<td width="25%"><a href="88.html">Index</a></td>"
if [ "$NEXT" != "" ]; then
echo >> $PAGENO.html "<td width="25%"><a href="$NEXT.html">Next page ($NEXT)</a></td>"
fi
cat <<EOF >> $PAGENO.html
</tr>
</table>
<br/>
<img alt="Recipe book page $PAGENO" src="$PAGENO.jpeg">
<br/>
<hr/>
<table summary="footings" width="100%">
<tr>
EOF
if [ "$PREV" != "" ]; then
echo >> $PAGENO.html "<td width="25%"><a href="$PREV.html">Previous page ($PREV)</a></td>"
fi
echo >> $PAGENO.html "<td width="25%"><a href="/grog/recipes/yvonne/">Overview page</a></td>"
echo >> $PAGENO.html "<td width="25%"><a href="88.html">Index</a></td>"
if [ "$NEXT" != "" ]; then
echo >> $PAGENO.html "<td width="25%"><a href="$NEXT.html">Next page ($NEXT)</a></td>"
fi
cat <<EOF >> $PAGENO.html
</tr>
</table>
<p>
<a href="http://validator.w3.org/check/referer"><img
src="http://www.w3.org/Icons/valid-xhtml10" alt="Valid XHTML 1.0!" height="31"
width="88" /></a>
<center>
<font size="-1">\$Id: makepages.html,v 1.2 2004/08/16 00:56:18 grog Exp $</font>
</center>
</body>
</html>
EOF
tidy -m -asxhtml $PAGENO.html
PREV=$PAGENO
shift
done