New to php and I screwed things up
Below is the code to a document called app_layout_home.php. Not realizing that you could edit a doc's text from a webhost's cpanel (first mistake), I downloaded the php file and edited it in Nvu portable. I changed ONE line of code (in the html of all places --> near the bottom, it is the copyright date). Then I reuploaded the file and the result is this:
http://www.ehaplanners.com/index.php
the html gets rendered, but the php is not parsed.
All of the other pages work correctly (they use separate app_layout_"pagename".php files). Here is a properly functioning one:
http://www.ehaplanners.com/index.php?fuseaction=AboutUs
Could someone please help me figure out the problem? I am such a novice. Any help would be greatly appreciated.
Kyle
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<?
$layout = "
<html>
<head>
<title>".$allsettings["setting_sitename"]."</title>
<script language='Javascript'>
startList = function() {
if (document.all&&document.getElementById) {
navRoot = document.getElementById('nav');
for (i=0; i<navRoot.childNodes.length; i++) {
node = navRoot.childNodes[i];
if (node.nodeName=='LI') {
node.onmouseover=function() {
this.className+=' over';
}
node.onmouseout=function() {
this.className=this.className.replace(' over', '');
}
}
}
navRoot2 = document.getElementById('nav2');
for (i=0; i<navRoot2.childNodes.length; i++) {
node = navRoot2.childNodes[i];
if (node.nodeName=='LI') {
node.onmouseover=function() {
this.className+=' over';
}
node.onmouseout=function() {
this.className=this.className.replace(' over', '');
}
}
}
}
}
window.onload=startList;
</script>
<style>
BODY{scrollbar-3dlight-color : #B4CDEC;
... boring CSS stuff......
</style>
</head>
<body topmargin="0" leftmargin="0" rightmargin="0">
<ul id="nav" style="margin: 0pt; padding: 0pt; list-style-type: none; position: absolute; top: 190px; left: 250px;">
<li><a href="%22.$site_url.%22Services"><img src="images/spacer.gif" border="0" height="20" width="95"></a>
<ul>
<li><a href="%22.$site_url.%22LandPlanningServices">Land
Planning Services</a></li>
<li><a href="%22.$site_url.%22ExpertWitnessTestimony">Expert
Witness Testimony</a></li>
<li><a href="%22.$site_url.%22UrbanDesignLandscapeArchitecture">Urban
Design & Landscape Architecture</a></li>
<li><a href="%22.$site_url.%22DevelopmentofRegionalImpact">Development
of Regional Impact</a></li>
<li><a href="%22.$site_url.%22SpecialStudies">Special
Studies</a></li>
<li><a href="%22.$site_url.%22RepresentativeClients">Representative
Clients</a></li>
</ul>
</li>
</ul>
<table bgcolor="white" border="0" cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td colspan="2" background="images/header_background.gif" height="92" width="100%">
<table cellpadding="0" cellspacing="0" width="100%">
<tbody>
<tr>
<td><a href="%22.$site_url.%22Home"><img src="images/header_left.gif" alt="" border="0" height="92" width="357"></a></td>
<td align="right"><a href="%22.$site_url.%22ContactUs"><img src="images/header_right.gif" alt="" border="0" height="92" width="364"></a></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td colspan="2" background="images/pic_top_background.gif" height="93" width="100%"><img src="images/pic_top.gif" alt="" border="0" height="93" width="750">
</td>
</tr>
<tr>
<td colspan="2" background="images/menu_top_background.gif" height="24" width="100%"><img src="images/menu_top.gif" alt="" usemap="#menu_top" border="0" height="24" width="750">
</td>
</tr>
<tr height="106">
<td valign="top" width="176"><img src="images/pic_menu.gif" alt="" border="0" height="106" width="176">
</td>
<td style="padding-right: 2px;" rowspan="2" valign="top">
<table border="0" cellpadding="0" cellspacing="0" height="100%" width="100%">
<tbody>
<tr>
<td height="25" width="8"><img src="images/content_topleft.gif" alt="" border="0" height="25" width="8"></td>
<td style="padding-bottom: 4px;" background="images/content_header.gif" height="25" valign="bottom"><img src="images/spacer.gif" alt="" border="0" height="1" width="1"><img src="images/title_%22.strtolower%28$fuseaction%29.%22.gif" alt="" border="0"></td>
<td height="25" width="8"><img src="images/content_topright.gif" alt="" border="0" height="25" width="8"></td>
</tr>
<tr>
<td background="images/content_left.gif"> <img src="images/spacer.gif" alt="" border="0" height="1" width="1"> </td>
<td style="padding-left: 5px;" padding-right:10="" padding-top:10="" padding-bottom:10="" bgcolor="#e9e9e9">
<div align="justify">".$bodycontent."</div>
</td>
<td background="images/content_right.gif"> <img src="images/spacer.gif" alt="" border="0" height="1" width="1"> </td>
</tr>
<tr>
<td height="14"><img src="images/content_bottomleft.gif" alt="" border="0" height="14" width="8"></td>
<td background="images/content_footer.gif" height="14" valign="top"><img src="images/spacer.gif" alt="" border="0" height="1" width="1"></td>
<td height="14"><img src="images/content_bottomright.gif" alt="" border="0" height="14" width="8"></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td background="images/leftmenu_background.gif" valign="top" width="176"> <input name="fuseaction" value="SearchNow" type="hidden">
<table border="0" cellpadding="0" cellspacing="0" height="100%" width="176">
<tbody>
<tr>
<td height="17"><img src="images/search_keywords.gif" alt="" border="0" height="18" width="176"></td>
</tr>
<form action="index.php" method="post"></form>
<tr>
<td style="padding-left: 5px; padding-top: 5px; padding-bottom: 5px;" background="images/leftmenu_background.gif"> <input name="keywords" maxlength="35" size="15" type="text"> <input src="images/button_search.gif" align="center" type="image"> </td>
</tr>
<tr>
<td height="16"><img src="images/latest_news.gif" alt="" border="0" height="16" width="176"></td>
</tr>
<tr>
<td style="padding-left: 10px; padding-right: 10px;" background="images/leftmenu_background.gif"> ".$news." </td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td colspan="2" background="images/menu_bottom_row_background.gif" height="12" width="100%"><img src="images/menu_bottom_row.gif" alt="" border="0" height="12" width="750"></td>
</tr>
<tr>
<td colspan="2" background="images/menu_bottom_background.gif" height="26" width="100%"><img src="images/menu_bottom.gif" alt="" usemap="#menu_bottom" border="0" height="26" width="750"></td>
</tr>
<tr>
<td colspan="2" align="center" background="images/footer.gif" height="53" valign="middle" width="100%">© 2007
Engelhardt, Hammer & Associates, Inc.</td>
</tr>
</tbody>
</table>
<ul id="nav2" style="margin: 0pt; padding: 0pt; list-style-type: none; position: relative; top: -75px; left: 260px;">
<li><a href="%22.$site_url.%22Services"><img src="images/spacer.gif" border="0" height="20" width="90"></a>
<ul>
<li><a href="%22.$site_url.%22LandPlanningServices">Land
Planning Services</a></li>
<li><a href="%22.$site_url.%22ExpertWitnessTestimony">Expert
Witness Testimony</a></li>
<li><a href="%22.$site_url.%22UrbanDesignLandscapeArchitecture">Urban
Design & Landscape Architecture</a></li>
<li><a href="%22.$site_url.%22DevelopmentofRegionalImpact">Development
of Regional Impact</a></li>
<li><a href="%22.$site_url.%22SpecialStudies">Special
Studies</a></li>
<li><a href="%22.$site_url.%22RepresentativeClients">Representative
Clients</a></li>
</ul>
</li>
</ul>
<map name="header">
<area alt="Home" coords="2,0,348,81" href="%22.$site_url.%22Home">
<area alt="Email Us!" coords="579,46,738,59" href="%22.$site_url.%22ContactUs">
</map>
<map name="menu_top">
<area shape="RECT" coords="101,0,101,0">
<area alt="Home" coords="102,0,172,24" href="index.php">
<area alt="About Us" coords="173,1,258,26" href="%22.$site_url.%22AboutUs">
<area alt="Services" coords="259,0,348,24" href="%22.$site_url.%22Services">
<area alt="Staff" coords="349,0,418,24" href="%22.$site_url.%22Staff">
<area alt="Careers" coords="419,0,497,25" href="%22.$site_url.%22Careers">
<area alt="Links" coords="498,0,565,24" href="%22.$site_url.%22Links">
<area alt="Contact Us" coords="566,1,661,25" href="%22.$site_url.%22ContactUs">
</map>
<map name="menu_bottom">
<!--same as map menu top>
</map>
</body>
</html>
";
print $layout;
?>