Witam 
Zaczynam ponownie zabaw? z PHP-FUSION i chc? stworzy? fajny design wi?c pytanie jest nast?puj?ce: 
 
Posiadam THEMA Zone_Red i chcia? bym stworzy? nag?ówki paneli tak jak w THEMIE Anime_Dream  
lecz nie wiem co mam zmieni? w pliku theme.php Zone_Red-a aby stworzy? takie nag?ówki, wi?c jak by mnie kto? móg? z lekka naprowadzi? to by? bym wdzi?czny.  
Poni?ej przedstawiam cody obu theme.php 
Zone_Red 
<?php 
// theme settings 
$body_text = "#000000"; 
$body_bg = "#660000"; 
$theme_width = "80%"; 
$theme_width_l = "160"; 
$theme_width_r = "160"; 
 
function render_header($header_content) { 
 
global $theme_width,$settings; 
 
echo "<table align='center' width='$theme_width' cellspacing='0' cellpadding='0'> 
<tr> 
<td><img src='".THEME."images/ol.gif' alt='oben links'></td> 
<td style='background-image: url(".THEME."images/o.gif); width: 100%;'></td> 
<td><img src='".THEME."images/or.gif' alt='oben rechts'></td> 
</tr> 
<tr> 
<td style='background-image:url(".THEME."images/l.gif); width:10px;'><img src='".THEME."images/l.gif' alt='left border'></td> 
<td> 
<table width='100%' cellspacing='0' cellpadding='0'> 
<tr> 
<td class='full-header'> 
<table width='100%' cellspacing='0' cellpadding='0'> 
<tr> 
<td><center><img src='".THEME."images/banner.gif' alt=''' title='".$settings[sitename]."'></center></td> 
</tr> 
</table> 
</td> 
</tr> 
</table>\n"; 
 
echo "<table width='100%' cellspacing='0' cellpadding='0'>\n<tr> 
<td class='white-header'>\n"; 
$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 " ·\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><td align='right' class='white-header'>".ucwords(showdate($settings['subheaderdate'], time()))."</td> 
</tr> 
</table>\n"; 
 
echo "<table width='100%' cellspacing='0' cellpadding='0'>\n<tr>\n"; 
 
} 
 
function render_footer($license=false) { 
 
global $theme_width,$settings,$locale; 
 
echo "</tr>\n</table>\n"; 
 
echo " 
<td style='background-image:url(".THEME."images/r.gif); width:10px;'><img src='".THEME."images/r.gif' alt='right border'></td> 
</tr> 
<tr> 
<td><img src='".THEME."images/ul.gif' alt='unten links'></td> 
<td style='background-image: url(".THEME."images/u.gif); width: 100%;'></td> 
<td><img src='".THEME."images/ur.gif' alt='unten rechts'></td> 
</tr> 
</table> 
<br> 
<table cellpadding='0' cellspacing='0' width='100%'> 
<tr> 
<td class='footer'>".stripslashes($settings['footer'])."</td> 
</tr> 
</table> 
<table cellpadding='0' cellspacing='0' width='100%'> 
<tr> 
<td align='center' class='footer2'><br> 
".$settings['counter']." ".($settings['counter'] == 1 ? $locale['140']."<br><br>\n" : $locale['141']."<br><br>\n"); 
if ($license == false) { 
   echo "Powered by <a target='_blank' href='http://www.php-fusion.co.uk'><img src='".THEME."images/fusion.gif' style='vertical-align:top;' alt='powered by php-fusion'></a>".$settings['']."\n 
           |   \n 
         Theme by <a target='_blank' href='http://www.uctxs.com'><img src='".THEME."images/fusionthemes.gif' style='vertical-align:top;' alt='Moded By: UCTXs Themes'></a> <br><br>\n"; 
   echo " Based on greeny by: <a target='_blank' href='http://matonor.de/fusion/news.php'><img src='".THEME."images/matonor.gif' style='vertical-align:top;' alt='Design by Matonor'>\n"; 
} 
echo "</td> 
</tr> 
</table> 
\n"; 
 
} 
 
function render_news($subject, $news, $info) { 
 
global $locale; 
 
echo "<table width='100%' cellpadding='0' cellspacing='0'> 
<tr> 
<td> 
<table width='100%' cellpadding='0' cellspacing='0'> 
<tr> 
<td class='capmain'>$subject</td> 
</tr> 
<tr> 
<td class='main-body'> 
$news 
</td> 
</tr> 
<tr> 
<td align='right' class='news-footer'><img src='".THEME."images/bullet.gif' alt='>'> 
".$locale['040']."<a href='profile.php?lookup=".$info['user_id']."'>".$info['user_name']."</a> 
".$locale['041'].showdate("longdate", $info['news_date'])." · 
".($info['news_ext'] == "y" ? "<a href='news.php?readmore=".$info['news_id']."'>".$locale['042']."</a> ·\n" : ""); 
if ($info['news_allow_comments'] == "1") echo "<a href='news.php?readmore=".$info['news_id']."'>".$info['news_comments'].$locale['043']."</a> ·\n"; 
echo $info['news_reads'].$locale['044']." 
<a href='print.php?type=N&item_id=".$info['news_id']."'><img src='".THEME."images/printer.gif' alt='".$locale['045']."' border='0' style='vertical-align:middle;'></a> 
</td> 
</tr> 
</table> 
</td> 
</tr> 
</table>\n"; 
 
} 
 
function render_article($subject, $article, $info) { 
 
global $locale; 
 
echo "<table width='100%' cellpadding='0' cellspacing='0'> 
<tr> 
<td> 
<table width='100%' cellpadding='0' cellspacing='0'> 
<tr> 
<td class='capmain'>$subject</td> 
</tr> 
<tr> 
<td class='main-body'> 
".($info['article_breaks'] == "y" ? nl2br($article) : $article)." 
</td> 
</tr> 
<tr> 
<td class='news-footer'><img src='".THEME."images/bullet.gif'> 
".$locale['040']."<a href='profile.php?lookup=".$info['user_id']."'>".$info['user_name']."</a> 
".$locale['041'].showdate("longdate", $info['article_date'])." · 
<a href='articlecomments.php?article_id=".$info['article_id']."'>".$info['article_comments'].$locale['043']."</a> · 
".$info['article_reads'].$locale['044']." 
<a href='print.php?type=A&item_id=".$info['article_id']."'><img src='".THEME."images/printer.gif' alt='".$locale['045']."' border='0' style='vertical-align:middle;'></a> 
</td> 
</tr> 
</table> 
</td> 
</tr> 
</table>\n"; 
 
} 
 
[color=red]function opentable($title) { 
 
echo "<table width='100%' cellpadding='0' cellspacing='0'> 
<tr> 
<td> 
<table width='100%' cellpadding='0' cellspacing='0'> 
<tr> 
<td class='capmain'>$title</td> 
</tr> 
<tr> 
<td class='main-body'>\n"; 
 
} 
 
function closetable() { 
 
echo "</td> 
</tr> 
</table> 
</td> 
</tr> 
</table>\n"; 
 
} 
 
function openside($title) { 
 
echo "<table width='100%' cellpadding='0' cellspacing='0' class='border'> 
<tr> 
<td> 
<table width='100%' cellpadding='0' cellspacing='0'> 
<tr> 
<td class='scapmain'>$title</td> 
</tr> 
<tr> 
<td class='side-body'>\n"; 
 
} 
 
function closeside() { 
 
echo "</td> 
</tr> 
</table> 
</td> 
</tr> 
</table>\n"; 
tablebreak(); 
 
} 
 
function opensidex($title,$open="on") { 
 
if($open=="on"){$box_img="off";}else{$box_img="on";} 
echo "<table width='100%' cellpadding='0' cellspacing='0' class='border'> 
<tr> 
<td> 
<table width='100%' cellpadding='0' cellspacing='0'> 
<tr> 
<td class='scapmain'>$title</td> 
<td class='scapmain' align='right'> 
<img onclick=\"javascript:flipBox('$title')\" name='b_$title' border='0' src='".THEME."images/panel_$box_img.gif' alt='b_$title'> 
</td> 
</tr> 
<tr> 
<td colspan='2' class='side-body'> 
<div id='box_$title'"; if($open=="off"){ echo "style='display:none'"; } echo ">\n"; 
 
} 
 
function closesidex() { 
 
echo "</div> 
</td> 
</tr> 
</table> 
</td> 
</tr> 
</table>\n"; 
tablebreak(); 
 
} 
 
function tablebreak() { 
 
echo "<table width='100%' cellspacing='0' cellpadding='0'> 
<tr><td height='8'></td></tr> 
</table>\n"; 
 
}[/color] 
?>
  
 
Anime_Dream 
<?php 
if (!defined("IN_FUSION")) { header("Location: ../../index.php"); exit; } 
require_once INCLUDES."theme_functions_include.php"; 
 
// theme settings 
$body_text = "#000000"; 
$body_bg = "#000000"; 
$theme_width = "820"; 
$theme_width_l = "160"; 
$theme_width_r = "160"; 
 
function render_header($header_content) { 
 
global $theme_width; 
 
echo "<table align='center' cellspacing='0' cellpadding='0' width='$theme_width' class='outer-border'> 
<tr> 
<td> 
<table cellpadding='0' cellspacing='0' width='100%'> 
<tr> 
<td class='full-header'> 
<table cellpadding='0' cellspacing='0' width='100%'> 
<tr> 
</tr> 
</table> 
</td> 
</tr> 
</table>\n"; 
 
 
 
echo "<center><img src='".THEME."images/header.jpg'></center>"; 
echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n"; 
 
} 
 
function render_footer($license=false) { 
 
global $theme_width,$settings; 
 
echo "</tr>\n</table>\n"; 
echo "<table cellpadding='0' cellspacing='0' width='100%'> 
<tr> 
<td height='29' background='".THEME."images/fbc.jpg' align='center' class='footer'>".stripslashes($settings['footer'])." 
<a href='http://www.php-fusion.co.uk/' target='_blank'>PHP fusion</a> | <a href='http://www.wtfthemes.failai.lt/' target='_blank'>WTF Themes</a><br> 
</td> 
</tr> 
</table> 
</td> 
</tr> 
</table>\n"; 
 
} 
 
function render_news($subject, $news, $info) { 
 
echo "<table cellpadding='0' cellspacing='0' width='100%'> 
<tr> 
<td class='capmain'>$subject</td> 
</tr> 
<tr> 
<td class='main-body'>$news</td> 
</tr> 
<tr> 
<td align='center' class='news-footer'>\n"; 
echo openform("N",$info['news_id']).newsposter($info," ·").newsopts($info,"·").closeform("N",$info['news_id']); 
echo "</td> 
</tr> 
</table>\n"; 
 
} 
 
function render_article($subject, $article, $info) { 
    
echo "<table width='100%' cellpadding='0' cellspacing='0'> 
<tr> 
<td class='capmain'>$subject</td> 
</tr> 
<tr> 
<td class='main-body'> 
".($info['article_breaks'] == "y" ? nl2br($article) : $article)." 
</td> 
</tr> 
<tr> 
<td align='center' class='news-footer'>\n"; 
echo openform("A",$info['article_id']).articleposter($info," ·").articleopts($info,"·").closeform("A",$info['article_id']); 
echo "</td> 
</tr> 
</table>\n"; 
 
} 
 
[color=red]function opentable($title) { 
 
echo "<table cellpadding='0' cellspacing='0' width='100%'> 
<tr> 
<td class='capmain'>$title</td> 
</tr> 
<tr> 
<td class='main-body'>\n"; 
 
} 
 
function closetable() { 
 
echo "</td> 
</tr> 
</table>\n"; 
 
} 
 
function openside($title) { 
    
echo "<table cellpadding='0' cellspacing='0' width='100%' class='border'> 
<tr> 
<td background='".THEME."images/sbc.jpg' height='35' class='scapmain'>   $title</td> 
</tr> 
<tr> 
<td class='side-body'>\n"; 
 
} 
 
function closeside() { 
 
echo "</td> 
</tr> 
</table>\n"; 
tablebreak(); 
 
} 
 
function opensidex($title,$state="on") { 
 
$boxname = str_replace(" ", "", $title); 
echo "<table cellpadding='0' cellspacing='0' width='100%' class='border'> 
<tr> 
<td class='scapmain'>$title</td> 
<td class='scapmain' align='right'>".panelbutton($state,$boxname)."</td> 
</tr> 
<tr> 
<td colspan='2' class='side-body'> 
<div id='box_$boxname'".($state=="off"?" style='display:none'":"").">\n"; 
 
} 
 
function closesidex() { 
 
echo "</div> 
</td> 
</tr> 
</table>\n"; 
tablebreak(); 
 
} 
 
function tablebreak() { 
 
echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n<td height='5'></td>\n</tr>\n</table>\n"; 
 
}[/color] 
?> 
 
 
Edytowane przez Piotrroger dnia 02.08.2007 00:07:45
 __________________________________________ 
Jestem g??boko wierz?cym ateist?.(Albert Einstein) 
Kto wie, ile trzeba wiedzie?, aby wiedzie?, ?e si? jeszcze wszystkiego nie wie? 
 |