I don't know what I am doing wrong here. I am pretty new at this and want to basically use css and php for a project. So I have been creating this template. I have everything working the way I want it and will start to develop content and rearrange after my understanding is a bit better... now the only hting I can't seem to get right is the active section and Topic highlighting. The a:hover is right the css is right... somewhere I am not doing something right. here is the site page:
http://www.clubinfinite.comhere is the code:
CODE
<?php $thisSection="Home"; ?>
<?php
$thisWebsite="Illustrating in CSS & php";
$page1="Home";
$page2="About";
$page3="Portfolio";
$page4="Recent News";
$page5="Contact";
$topic1="Welcome";
$topic2="Topic Two";
$topic3="Topic Three";
$topic4="Topic Four";
$topic5="Topic Five";
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<div id="container">
<title><?php echo "$thisWebsite"; ?><?php echo " | $thisSection"; ?><?php echo " | $thisTopic"; ?></title>
<link rel="stylesheet" type="text/css" href="default.css"
</head>
<body class="topic-1">
<div id="masthead"><h1><?php echo "$thisWebsite"; ?></h1></div>
<div id="main-menu">
<ul>
<li<?php if ($thisSection=="Home") echo " id=\"active-selection\""; ?>><a href="#" title="Home">Home</a></li>
<li<?php if ($thisSection=="About") echo " id=\"active-selection\""; ?>><a href="#" title="About">About</a></li>
<li<?php if ($thisSection=="Portfolio") echo " id=\"active-selection\""; ?>><a href="#" title="Portfolio">Portfolio</a></li>
<li<?php if ($thisSection=="Recent News") echo " id=\"active-selection\""; ?>><a href="#" title="Process">Process</a></li>
<li<?php if ($thisSection=="Contact") echo " id=\"active-selection\""; ?>><a href="#" title="Contact">Contact</a></li>
</ul>
</div>
<div id="page-column">
<ul>
<li<?php if ($thisTopic=="Welcome") echo " id=\"active-topic\""; ?>><a href="#" title="Welcome"><?php echo "$topic1"; ?></a></li>
<li<?php if ($thisTopic=="topic2") echo " id=\"active-topic\""; ?>><a href="#" title="topic2"><?php echo "$topic2"; ?></a></li>
<li<?php if ($thisTopic=="topic3") echo " id=\"active-topic\""; ?>><a href="#" title="topic3"><?php echo "$topic3"; ?></a></li>
<li<?php if ($thisTopic=="topic4") echo " id=\"active-topic\""; ?>><a href="#" title="topic4"><?php echo "$topic4"; ?></a></li>
<li<?php if ($thisTopic=="topic5") echo " id=\"active-topic\""; ?>><a href="#" title="topic5"><?php echo "$topic5"; ?></a></li>
</ul>
</div>
<div id="page-contents">
<?php $thisTopic="Welcome"; ?>
<h2>Welcome to My Illustrations in CSS</h2>
<p>For years now, I have been illustrating and painting. I am now trying to find a way to do so in code and am totally passionate about it! This small web application is an exercise to illustrate a site with CSS and php.
</p>
</div>
<div id="footer"><p class="text-small"><?php echo "$thisWebsite"; ?> Copyright 2008 Michael Parenteau. All Rights Reserved.</p></div>
</body>
here is the stylesheet reference:
CODE
#main-menu ul li#active-selection a
{background: #521508;
}
#page-column ul li#active-topic a
{
background: #CCC;
}
Thanks in advance for any help you can spare!!! I appreciate it.
This post has been edited by parenteau: 3 Mar, 2008 - 10:46 PM