So, I am used to ASP, but was given a little issue to deal with and my attempts didn't quite pan out. I have an includes file for the menu which selects the proper style depending on which tab you are on. So, I am trying to define the section variable at the top of each page and then use it to determine whether or not to mark it as active. Here is the code that I have:
Before the opening HTML tag
then within the body of the menu.php include file
And that last bit of code gives me this error:
Any thoughts?
Willie
Before the opening HTML tag
Code:
<? php
$section="QA";
?>
then within the body of the menu.php include file
Code:
<? php if $section="Products" echo "<li id='active'>"; else echo "<li>"; ?>
And that last bit of code gives me this error:
Code:
Parse error: syntax error, unexpected T_IF in /mnt/w0310/d19/s05/b024806b/[URL unfurl="true"]www/canelonesfoods.cn/English/menu.php[/URL] on line 33
Any thoughts?
Willie