Jump to content

[SOLVED] syntax error, unexpected T_SL


ballhogjoni

Recommended Posts

Can someone help with this error?

 

syntax error, unexpected T_SL in /home/realfina/public_html/teest.php on line 5

 

<?php 
// Generates the top of the page 
function addHeader($page, $title) 
{ 
$page .= <<<EOD 
<html> 
<head> 
<title>$title</title> 
</head> 
<body> 
<h1 align="center">$title</h1> 
EOD; 
return $page; 
} 

// Generates the bottom of the page 
function addFooter($page, $year, $copyright) 
{ 
$page .= <<<EOD 
<div align="center">© $year $copyright</div> 
</body> 
</html> 
EOD; 
return $page; 
} 

// Initialize the page variable 
$page = ''; 

// Add the header to the page 
$page = addHeader($page, 'A Prodecural Script'); 

// Add something to the body of the page 
$page .= <<<EOD 
<p align="center">This page was generated with a procedural 
script</p> 
EOD; 

// Add the footer to the page 
$page = addFooter($page, date('Y'), 'Procedural Designs Inc.'); 

// Display the page 
echo $page; 
?>

Link to comment
https://forums.phpfreaks.com/topic/100377-solved-syntax-error-unexpected-t_sl/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.