Parse error: parse error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home/john5115/public_html/site3/includes/include.php on line 35
im basically rebuilding my website and i am striping it down from about 100000 php files to about 5 or 6 just to make it easier for me to keep tabs on and update/change design.
i get the above error with the script below from my include file. it worked fine when it ran directly from the index.php but now its causing problems with it being in the include ?
[code=php]
<?php require_once “includes/connection.php”; ?>
<?
//Diary entrys for the home page:
$home = <<<HOMEDIARY
<table style=”width:100%; border:0; padding:0;” cellpadding=”0″ cellspacing=”0″>
<tr>
<td style=”height:37px; width:300px; background-image: url(images/left_top.gif);” colspan=”3″></td>
<td style=”height:37px; width:397px; background-image: url(images/right_top.gif);” colspan=”3″></td>
</tr>
<tr>
<td style=”height:235px; width:11px; background-image: url(images/line_left.gif); background-repeat:repeat-y”></td>
<!– beginning of text left –>
<td style=”width:284px;” valign=”top”>
$query = ‘SELECT * FROM diary ORDER BY diary_no DESC’;
$result = mysql_query($query, $link);
while ($row = mysql_fetch_array($result, MYSQL_ASSOC))
{
echo(‘<p>’ . {$row[“diary_date”]} . ‘</p> <p>’ . {$row[“diary_text”]} . ‘</p>’);
}
</td>
<!– end of text left –>
<td style=”height:235px; width:6px; background-image: url(images/line_center_left.gif); background-repeat:repeat-y”></td>
<td style=”height:235px; width:5px; background-image: url(images/line_center_right.gif); background-repeat:repeat-y”></td>
<!– beginning of text right –>
<td style=”width:381px;” valign=”top”>
$query = ‘SELECT * FROM cpg135_pictures ORDER BY RAND() LIMIT 1’;
$result = mysql_query($query, $link);
$row = mysql_fetch_array($result, MYSQL_ASSOC);
<a href=”../coppermine/” title=”knowj.com gallery”>
<img src=”http://www.knowj.com/coppermine/albums/ echo {$row[‘filepath’]}; if (!$row[‘filepath’]==’mobile’) {echo ‘normal_’;} echo $row[‘filename’]” width=”377″ style=”border:2px solid”> //line 35
</a>
</td>
<!– end of text right –>
<td style=”height:235px; width:11px; background-image: url(images/line_right.gif); background-repeat:repeat-y”></td>
</tr>
<tr>
<td style=”height:22px; width:303px; background-image: url(images/line_bottom_left.gif);” colspan=”3″ ></td>
<td style=”height:22px; width:397px; background-image: url(images/line_bottom_right.gif);” colspan=”3″></td>
</tr>
</table>
HOMEDIARY;
?>
thanks in advance