Location: PHPKode > projects > The Easy and Free PHP guestbook > include/html/mix_html.php
<?php
$powered_by="<center><a href=\"http://www.cellbiol.com/scripts/free_php_guestbook/free_php_guestbook.html\" target=\"_Blank\" class=\"powered\">Powered by the Easy PHP Guestbook</a></center>\n";
$nocache_header= "
// Date in the past 
header(\"expires: Mon, 26 Jul 1997 05:00:00 GMT\")
// HTTP/1.1 
header(\"Cache-Control: no-store, no-cache, must-revalidate\") 
header(\"Cache-Control: post-check=0, pre-check=0\", false)
// HTTP/1.0 
header(\"Pragma: no-cache\")
"; 

$nocache_meta="<meta http-equiv=\"cache-control\" content=\"no-store\">\n<meta http-equiv=\"cache-control\" content=\"no-cache\">\n<meta http-equiv=\"cache-control\" content=\"must-revalidate\">\n<meta http-equiv=\"pragma\" content=\"no-cache\"><meta http-equiv=\"expires\" content=\"tue, 26-oct-1965 12:00:00\">\n<meta http-equiv=\"expires\" content=\"now\"><meta http-equiv=\"last modified\" content=\"now\">\n";
$task_show_redir='<META HTTP-EQUIV="refresh" CONTENT="0; url=php_guestbook.php?task=show" >';
$admin_pag_style='<style type="text/css"> 
    h1 { font-family:verdana; font-size:20px; line-height:150%}
    h2 { font-family:verdana; font-size:18px; line-height:150%}
    .splink { cursor:pointer;  font-family:verdana; font-size:10px; font-weight:bold; line-height:150%; color:blue}
     * {  font-family:verdana; font-size:11px; line-height:150%}
    a {text-decoration:none}     
    </style>';

$admin_page_style2='<style type="text/css"> 
    h1 { font-family:verdana; font-size:20px; line-height:150%}
    h2 { font-family:verdana; font-size:18px; line-height:150%}
    .splink { cursor:pointer;  font-family:verdana; font-size:10px; font-weight:bold; line-height:150%; color:blue}
    .admin_style {  font-family:verdana; font-size:11px; line-height:150%}
    </style>';

$login_style="<style type=\"text/css\"> 
    .powby{font-size:10px;font-family:verdana;}
    a.powby{font-size:10px;font-family:verdana:}
    </style>";

# Template for the administration page. Do not edit unless you know what you are doing    

$doctype_header="<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\n\"http://www.w3.org/TR/html4/loose.dtd\">\n";
$open_html_and_head="<html>\n<head>\n";
$add_doctype_open_html_and_head=$doctype_header.$open_html_and_head;
$admin_title="<title>The Easy PHP Guestbook admin section</title>\n";
$login_title="<title>The Easy PHP Guestbook admin login page</title>\n";
$captcha_title="<title>The Easy PHP Guestbook captcha validation page</title>\n";
$configuration_page_title="<title>The Easy PHP Guestbook configuration page</title>\n";
$del_edit_title="<title>The Easy PHP Guestbook delete/edit messages page</title>\n";
$link_admin_css="<link rel=StyleSheet href=\"styles/admin1.css\" type=\"text/css\">\n";
$link_javascript="<script type=\"text/javascript\" src=\"javascript/gb_javascript.js\"></script>";
$close_head_open_body="</head>\n<body>\n";
$close_head_open_body_admin="</head>\n<body class=\"adminbody\">\n";
$close_head_open_body_captcha_page="</head>\n<body OnLoad=\"document.captchaform.random.focus();\" class=\"captchabody\">\n";
$close_head_open_body_session_expired_page='
</head>
<body OnLoad="document.adminlogin.adpass.focus();">'.
"\n";

$link_admin_css_close_head_open_body=$link_admin_css.$close_head_open_body;
$link_admin_css_close_head_open_body_session_exp_page=$link_admin_css.$close_head_open_body_session_expired_page;
$link_admin_css_close_head_open_body_captcha_page=$link_admin_css.$close_head_open_body_captcha_page;

$session_expired_header=$add_doctype_open_html_and_head.$login_title.$link_admin_css_close_head_open_body_session_exp_page;

$captcha_header=$add_doctype_open_html_and_head.$nocache_meta.$captcha_title.$link_admin_css_close_head_open_body_captcha_page;

$general_admin_header=$add_doctype_open_html_and_head.$admin_title.$link_admin_css_close_head_open_body;

$admin_home_line_1="<center>\n<h1>Welcome to the guestbook admin section</h1>\n<hr class=\"adminhome\">\n</center>\n<p align=\"center\">";
$admin_home_line_2="<p>\n<hr class=\"adminhome\">\n".$powered_by."\n";
$close_body_and_html="</body>\n</html>";



$admin_template='<tr><td valign=top>
<form action=\"\" method=post>
<input type=hidden name=post_id value=$post_id>'.
#<input type=hidden name=adpass value=$posted_pass>
'<input type=hidden name=task value=delete>
<input type=submit value=delete>
</form>
</td>
<td valign=top><font color=red><b>$post_id</b></font></td><td valign=top>$date <br>From IP: $ip_addr<p> <br></td>
<td valign=top width=60%><b>Name: </b>$name &nbsp;&nbsp;&nbsp;&nbsp;<b>E-mail: </b>$email<p>$message</td>
<td valign=top>
<form action=\"\" method=\"post\">
<input type=hidden name=adpass value=$posted_pass>
<input type=hidden name=task value=edit>
<input type=hidden name=post_id value=$post_id>
<input type=submit value=\"edit message number $post_id \">
</form></td></tr>\n'; # THIS IS THE ADMIN TEMPLATE FOR THE POSTS

# Template for the administration page. Do not edit unless you know what you are doing    
$show_pending_line='<tr><td valign=\"top\">
<form action=\"\" method=\"post\">
<input type=\"hidden\" name=\"post_id\" value=$post_id>
<input type=\"hidden\" name=\"adpass\" value=$posted_pass>
<input type=\"hidden\" name=\"task\" value=\"delete\">
<input type=\"submit\" value=\"delete\">
</form>
</td>
<td valign=\"top\"><font color=\"red\"><B>$post_id</b></font></td><td valign=top>$date <BR>From IP: $ip_addr<P> <BR></td>
<td valign=\"top\" width=\"60%\"><B>Name: </B>$name &nbsp;&nbsp;&nbsp;&nbsp;<B>E-mail: </B>$email<P>$message</td>
<td valign=top>
<FORM action=\"\" method=post>
<input type=\"hidden\" name=\"adpass\" value=$posted_pass>
<input type=\"hidden\" name=\"task\" value=\"approve\">
<input type=\"hidden\" name=\"post_id\" value=$post_id>
<input type=\"submit\" value=\"approve message number $post_id \">
</form></td></tr>\n'; # THIS IS THE ADMIN TEMPLATE FOR THE POSTS TO BE APPROVED

$pwb2="<a class=\"powby\" href=\"http://www.cellbiol.com/scripts/free_php_guestbook/free_php_guestbook.html\" target=\"_blank\">Powered by the The Easy PHP Guestbook ®</a>";
$admin_navigation="<span class=\"admin_style\"><center> \n<a href=\"php_guestbook.php?task=show\">Admin home</a> | \n<a href=\"php_guestbook.php?task=configure\">Configure</a> | \n<a href=\"php_guestbook.php?task=del_edit\">Edit/Delete</a> | \n<a href=\"php_guestbook.php?task=ShowPendingMessages\">Pending</a> | \n<a href=\"".$gbook_url."\"target=\"_blank\">Guestbook</a> | \n<a href=\"http://www.cellbiol.com/scripts/free_php_guestbook/free_php_guestbook.html\" target=\"_blank\">Check for updates</a> | \n<a href=\"php_guestbook.php?task=adm_logout\">Logout</a>\n</center></span>";
$del_edit_header1= $add_doctype_open_html_and_head.$del_edit_title.$link_admin_css.$close_head_open_body_admin;
$del_edit_header2="\n<center><h1>Edit/Delete guestbook messages</h1></center>
<p><center><table width=\"1024\" cellpadding=\"5\" cellspacing=\"2\" border=\"0\" bordercolor=\"red\" style=\"text-align:left;\">
<tr style=\"background-color:#B0F05E;\"><td><b><font color=\"white\">Delete</font></b></td>
<td><b><font color=\"white\"> Id </font></b></td>
<td><b><font color=\"white\">Date/IP</font></b></td>
<td><b><font color=\"white\">Message</font></b></td>
<td><center><B><font color=\"white\">Edit Posts</font></b></center></td></tr>\n";

$del_edit_footer="</table><p><hr class=\"admin_footer\">
<br>".$powered_by.$close_body_and_html;

$show_pending_redir='<meta http-equiv="refresh" content="0; url="php_guestbook.php?task=ShowPendingMessages">';
$deledit_redir='<meta http-equiv="refresh" content="1; url="php_guestbook.php?task=del_edit">';

$powered_by_close_page=$powered_by.$close_body_and_html;
?>
Return current item: The Easy and Free PHP guestbook