Something broke - I had these functions working and now suddenly something is causing it to not parse. You can have more than one function between php tags right? I get the following error:
Parse error: syntax error, unexpected $end in /home/omgma/public_html/Fresh_start/includes/output_fns.php5 on line 31
When I include the following as an include file:
<?php
// function to generate the start of a new html page
function do_html_header($title) //adds title and 1st part of html file
{
//use a heredoc variable for the page head section
$hdrstring = <<<EOT
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title> $title</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
EOT;
echo $hdrstring; //echo out the page head
}
// function to convert css and java arrays into links
function do_html_scripts($css, $java)
{
foreach ($css as $css_file)
{
echo "<link rel='stylesheet' type='text/css' href='".$css_file ."'>\n";
}
foreach ($java as $js_file)
{
echo "<script type='text/javascript' src='".$js_file ."'></script>\n";
}
}
?>
Any ideas on what I have mucked up?
SIGH! 😕