Theme to Darthanian a render_header wygląda tak:
function render_header($header_content) {
global $theme_width,$settings;
echo "<table width='$theme_width' table align='center' cellpadding='0' cellspacing='0'>";
echo "<tr><td class='header-left'><img src='".THEME."images/blank.gif' width='18' height='20' alt='' style='display:block'></td>";
echo "<td width='100%' background='".THEME."images/header-main.gif'></td>";
echo "<td class='header-right'><img src='".THEME."images/blank.gif' width='18' height='20' alt='' style='display:block'></td>";
echo "</tr></table>";
echo "<table width='800' table align='center' cellpadding='0' cellspacing='0'><tr>";
echo "<td class='border-left'><img src='".THEME."images/blank.gif' height='1' alt='' style='display:block'></td>";
echo "<td align='left' class='header'>$header_content</td>";
echo "<td class='border-right'><img src='".THEME."images/blank.gif' width='18' height='1' alt='' style='display:block'></td></tr>";
echo "<table width='800' table align='center' cellpadding='0' cellspacing='0'><tr>";
echo "<td align='left' background='".THEME."images/border-bleft.gif' width='18'></td>";
echo "<td class='border-bmain'><img src='".THEME."images/blank.gif' width='1' height='20' alt='' style='display:block'></td>";
echo "<td class='border-bright'><img src='".THEME."images/blank.gif' width='18' height='20' alt='' style='display:block'></td>";
echo "</tr></table>\n";
//Nav links begin
echo "<table border='0' cellspacing='0' width='800' table align='center' cellpadding='0'><tr>";
echo "<td class='nav-left'><img src='".THEME."images/blank.gif' width='10' height='39' alt='' style='display:block'></td>";
echo "<td width='70%' class='nav-main'>";
$result = dbquery("SELECT * FROM ".DB_PREFIX."site_links WHERE link_position>='2' ORDER BY link_order");
if (dbrows($result) != 0) {
$i = 0;
while($data = dbarray($result)) {
if (checkgroup($data['link_visibility'])) {
if ($data['link_url']!="---") {
if ($i != 0) { echo " <img border='0' vspace='1' src='".THEME."images/divider.gif'>\n"; } else { echo "\n"; }
$link_target = ($data['link_window'] == "1" ? " target='_blank'" : "");
if (strstr($data['link_url'], "http://") || strstr($data['link_url'], "https://")) {
echo "<a href='".$data['link_url']."'".$link_target." class='white'>".$data['link_name']."</a>";
} else {
echo "<a href='".BASEDIR.$data['link_url']."'".$link_target." class='white'>".$data['link_name']."</a>";
}
}
$i++;
}
}
}
echo ($i == 0 ? " " : "")."</td>";
echo "<td align='right' width='30%' class='datetime'>".ucwords(showdate($settings['subheaderdate'], time()))."</td>";
echo "<td class='nav-right'><img src='".THEME."images/blank.gif' width='10' height='39' alt='' style='display:block'>";
echo "</td></tr></table>";
echo "<table width='800' table align='center' cellspacing='0' cellpadding='0'>\n<tr>\n";
}
|