I've got a simple few lines of code that I use regularly for the boxing around some menus.
The code looks like this:
Code: Select all
<tr>
<td width="20" align="left" valign="top" class="td2"><img src="images/news_bar_end_left.gif"></td>
<td width="100%" align="center" valign="top" class="td2">
<?
//get the variable from the page that will call this code
$boxtoptext = $_GET['boxtop'];
print "$boxtoptext";
?>
</td>
<td width="20" align="right" valign="top" class="td2"><img src="images/news_bar_end_right.gif"></td>
</tr>In all the other files that call this file, I want this kind of thing to happen (without a form I presume)
Code: Select all
<? include("box_top.php?boxtop=News Options"); ?>Is there such a way to do this? I know it sounds a bit to good to be true, I'm sure it's going to be more complicated....
Thanks for reading, I hope somebody out there knows the answer!