Will show the collapse or expand button for panels which are collapsible.
Quote
panelbutton ( string $state , string $bname )
<?php
function openside($title, $collapse = false, $state = "on") {
global $panel_collapse; $panel_collapse = $collapse;
echo "<table cellpadding='0' cellspacing='0' width='100%'>n<tr>n";
echo "<td class='scapmain-left'></td>n";
echo "<td class='scapmain'>$title</td>n";
if ($collapse == true) {
$boxname = str_replace(" ", "", $title);
echo "<td class='scapmain' align='right'>".panelbutton($state, $boxname)."</td>n";
}
echo "<td class='scapmain-right'></td>n";
echo "</tr>n</table>n";
echo "<table cellpadding='0' cellspacing='0' width='100%' class='spacer'>n<tr>n";
echo "<td class='side-body'>n";
if ($collapse == true) { echo panelstate($state, $boxname); }
}
?>
<?php
// Panel button's state is "on"
panelbutton("on", "PanelName");
// Panel button's state is "off"
panelbutton("off", "PanelName");
?>
Quote
// Panel buttons state is "on"
<img src='themes/Gillette/images/panel_off.gif' id='b_PanelName' class='panelbutton' alt='' onclick="javascript:flipBox('PanelName')" />
// Panel buttons state is "off"
<img src='themes/Gillette/images/panel_on.gif' id='b_PanelName' class='panelbutton' alt='' onclick="javascript:flipBox('PanelName')" />