Przedszkolak
Postów: 62
Data rejestracji: 12.04.2008 10:47
|
Witam chciałbym w topie strony zmienić dwie rzeczy. Ostatnie artykuły i ostatnie komentarze zamienić (od lewej) na ostatnie tematy z forum i losowa fotka. Próbowałem podmieniać kody w ostatnich komentarzach z
if (!defined("IN_FUSION")) { die("Access Denied"); }
include INFUSIONS."latest_comments_panel/infusion_db.php";
if (file_exists(INFUSIONS."latest_comments_panel/locale/".$settings['locale'].".php")) {
include INFUSIONS."latest_comments_panel/locale/".$settings['locale'].".php";
} else {
include INFUSIONS."latest_comments_panel/locale/Polish.php";
}
na
if (!defined("IN_FUSION")) { die("Access Denied"); }
include INFUSIONS."slideshows_random_photo_panel/infusion_db.php";
if (file_exists(INFUSIONS."slideshows_random_photo_panel/locale/".$settings['locale'].".php")) {
include INFUSIONS."slideshows_random_photo_panel/locale/".$settings['locale'].".php";
} else {
include INFUSIONS."slideshows_random_photo_panel/locale/English.php";
}
ale ukazuje się błąd
Notice: Undefined index: lcp103 in /home/accounts_d/dimitris/public_html/themes/SF/theme.php on line 81
Notice: Undefined index: lcp200 in /home/accounts_d/dimitris/public_html/themes/SF/theme.php on line 96
Proszę o pomoc.
Mój theme.php
<?php
if (!defined("IN_FUSION")) { die("Access Denied"); }
define("THEME_WIDTH", "900");
define("THEME_BULLET", "<img src='".THEME."images/bullet.gif' alt='' border='0'/>");
require_once INCLUDES."theme_functions_include.php";
function render_page($license=false) {
global $settings, $main_style, $data, $itemsubject, $locale, $wsk;
//v7 sublinks function is a bit more for this, so taken from v6 and tweaked
function thesublinks($sep="·",$class="") {
$i = 0; $res = "";
$sres = dbquery("SELECT * FROM ".DB_PREFIX."site_links WHERE link_position>='2' AND ".groupaccess('link_visibility')." AND link_url!='---' ORDER BY link_order ASC");
if (dbrows($sres)) {
while($sdata = dbarray($sres)) {
if ($i != 0) { $res .= " ".$sep."\n"; } else { $res .= "\n"; }
$link_target = $sdata['link_window'] == "1" ? " target='_blank'" : "";
$link_class = $class ? " class='$class'" : "";
if (strstr($sdata['link_url'], "http://") || strstr($sdata['link_url'], "https://")) {
$res .= "<a href='".$sdata['link_url']."'".$link_target.$link_class.">".$sdata['link_name']."</a>";
} else {
$res .= "<a href='".BASEDIR.$sdata['link_url']."'".$link_target.$link_class.">".$sdata['link_name']."</a>";
}
$i++;
}
}
if ($i != 0) { return $res; } else { return " "; }
}
//Header
echo "<table align='center' cellspacing='0' cellpadding='0' width='".THEME_WIDTH."' class='outer-border'>\n<tr>\n";
echo "<td>\n";
echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n";
echo "<td class='full-header'>\n<img src='".THEME."images/top_02.png'></td>\n";
echo "</tr>\n<tr>\n";
echo "<td class='sub-header' width='697px'>\n";
echo thesublinks("<img border='0' src='".THEME."images/divider.gif'>","beyaz");
echo "</td>\n</tr>\n</table>\n";
echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>";
echo "<td class='under' background='".THEME."images/sub-top_05.png' width='352' height='183' alt='' valign='middle'> \n";
$result = dbquery("SELECT ta.article_id, ta.article_subject, tac.article_cat_name, tac.article_cat_id, ta.article_datestamp, tac.article_cat_access FROM ".DB_ARTICLES." ta
INNER JOIN ".DB_ARTICLE_CATS." tac ON ta.article_cat=tac.article_cat_id AND article_draft='0' ORDER BY article_id DESC LIMIT 0,5");
if (dbrows($result)) {
$k=0;
echo "<b>Ostatnio dodane artykuły: </b><br><br> ";
while($data = dbarray($result)) {
$itemsubject = trimlink($data['article_subject'], 25);
$k++;
echo " <table><tr><td style='padding-left: 10px' width='80%'><a href='".BASEDIR."articles.php?article_id=".$data['article_id']."' title='".$data['article_subject']."' class='side'><img src='http://127.0.0.1/~F2/themes/SF/images/arrow.png' width='8px' height='8px' /> $itemsubject </a></td><td>".$data['article_cat_name']."</td></tr></table>\n";
echo "<img src='".THEME."images/podkreslnik.png' width='300px' height='7px' />";
}
} else {
echo "<div style='text-align:center'>".$locale['global_031']."</div>\n";
}
echo "</td><td class='under' background='".THEME."images/sub-top_06.png' width='346' height='183' alt='' valign='middle'>";
if (!defined("IN_FUSION")) { die("Access Denied"); }
include INFUSIONS."latest_comments_panel/infusion_db.php";
if (file_exists(INFUSIONS."latest_comments_panel/locale/".$settings['locale'].".php")) {
include INFUSIONS."latest_comments_panel/locale/".$settings['locale'].".php";
} else {
include INFUSIONS."latest_comments_panel/locale/Polish.php";
}
//NEWSY
echo"<b><br>";
echo $locale['lcp103']."<br>";
echo"</b><p>";
$result = dbquery("SELECT * FROM ".DB_COMMENTS." WHERE comment_type='N' ORDER BY comment_datestamp DESC LIMIT 0,5");
if (dbrows($result) != 0) {
while ($data = dbarray($result)) {
echo '<table><tr><td style="padding-left: 10px" width="80%">';
echo "<img src='http://127.0.0.1/~F2/themes/SF/images/arrow.png' width='8px' height='8px' /> ";
echo '<a href="'.BASEDIR.'news.php?readmore='.$data['comment_item_id'].'" title="'.trimlink($data['comment_message'], 80).'">'.trimlink($data['comment_message'], 45).'</a></td></tr></table>';
echo "<img src='".THEME."images/podkreslnik2.png' width='330px' height='7px' />";
}
} else {
echo $locale['lcp200'];
}
echo "</p>";
//KONIEC NEWSÓW
echo "</td>
<td>
<img src='".THEME."images/sub-top_07.png' width='202' height='183' alt=''></td>
</tr>
<tr>
<td class='podkresl' colspan='3'>
</td>
</tr>
</table>
\n";
//Content
echo "<table cellpadding='0' cellspacing='0' width='900' class='$main_style'>\n<tr>\n";
echo "<td class='main-bg' valign='top' rowspan='2'>".U_CENTER.CONTENT.L_CENTER."</td></tr><tr>";
if (LEFT) { echo "<td class='side-border-left' valign='top' width='280'>".LEFT."</td>"; }
echo "</tr></table>\n";
//Footer
echo "<table cellpadding='0' cellspacing='0' width='".THEME_WIDTH."' align='center'>\n<tr>\n";
echo "<td height='150' background='".THEME."images/stopka.png' align='center' class='footer' valign='top'><br><br>\n";
echo stripslashes($settings['footer']);
echo "<a href='http://vero.[cenzura]/'>Vero</a> dla <a href='http://[cenzura]'>Szablony [cenzura]</a><br><font class='visits'>";
if (!$license) { echo showcopyright()."<br /><br />\n"; }
echo "<b>".showcounter()."</b></font></td>\n";
echo "</tr>\n";
echo "</table>\n</td>\n</tr>\n</table>\n";
}
function render_news($subject, $news, $info) {
echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n";
echo "<td height='26' class='capmain' style='padding-left: 20px'>".$subject."</td>\n";
echo "</tr>\n<tr>\n";
echo "<td align='right' style='padding-right: 10px' class='news-footer'>\n";
echo newsopts($info,"·").itemoptions("N",$info['news_id']);
echo "</td>\n";
echo "</tr>\n<tr>\n";
echo "<td class='main-body'>".$news."</td>\n";
echo "</tr></table>\n<br><br>\n";
}
function render_article($subject, $article, $info) {
echo "<table cellpadding='0' cellspacing='0' width='100%'>\n<tr>\n";
echo "<td class='capmain'>".$subject."</td>\n";
echo "</tr>\n<tr>\n";
echo "<td class='main-body'>".($info['article_breaks'] == "y" ? nl2br($article) : $article)."</td>\n";
echo "</tr>\n<tr>\n";
echo "<td align='center' class='news-footer'>\n";
echo articleposter($info," ·").articleopts($info,"·").itemoptions("A",$info['article_id']);
echo "</td>\n</tr>\n</table>\n";
}
function opentable($title) {
echo "<table cellpadding='0' cellspacing='0' width='100%' align='center'>\n<tr>\n";
echo "<td height='26' class='capmain'> ".$title."</td>\n";
echo "</tr>\n<tr>\n";
echo "<td class='main-body'>\n";
}
function closetable() {
echo "</td>\n</tr>\n</table>\n";
}
function openside($title, $collapse = false, $state = "on") {
global $panel_collapse; $panel_collapse = $collapse;
echo "<table cellpadding='0' cellspacing='0' width='100%' class='border'>\n<tr>\n";
echo "<td class='scapmain' background='".THEME."images/panel.png' height='30' style='padding-left: 15px'>".$title."</td>\n";
if ($collapse == true) {
$boxname = str_replace(" ", "", $title);
echo "<td class='scapmain' align='right'>".panelbutton($state,$boxname)."</td>\n";
}
echo "</tr>\n<tr>\n";
echo "<td".($collapse == true ? " colspan='2'" : "")." class='side-body'>\n";
if ($collapse == true) { echo panelstate($state, $boxname); }
}
function closeside($collapse = false) {
global $panel_collapse;
if ($panel_collapse == true) { echo "</div>\n"; }
echo "</td>\n</tr>\n</table>\n";
}
?>
style.css
a {
color : #737371;
text-decoration : none;
}
a:hover {
color : #fff;
text-decoration : none;
}
a.side {
color : #737371;
text-decoration : none;
}
a:hover.side {
color : #fff;
text-decoration : underline;
}
a.white {
color : #737371;
text-decoration : none;
}
.prawa {
text-align: right;
}
.beyaz {
font-family:Verdana,Tahoma,Arial,Sans-Serif;
font-size:11px;
font-weight : bold;
vertical-align:bottom;
color:#fff;
padding: 2px;
}
hr {
height: 1px;
background-image: url(images/hr-bg.png);
border: 0px;
}
a:hover.white {
color : #878781;
text-decoration : none;
}
body {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 11px;
color: #878781;
background-color : #000000;
background-image: url(images/bg.png);
background-position: top center;
background-repeat: repeat-x;
width: 100%;
}
form {
margin : 0px;
}
td {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 11px;
}
pre {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 11px;
}
.alt {
color : #878781;
}
.outer-border {
border : 0px solid #ffffff;
}
.sub-header {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 10px;
color : #fff;
padding : 0px 0px 0px 10px;
background-color : #ffffff;
background-image: url(images/top_04.png);
height: 30px;
width: 900px;
}
.under {
color : #737371;
text-decoration : none;
padding-right: 6px;
padding-left: 10px;
text-align: justify;
}
.podkresl {
color : #737371;
text-decoration : none;
background-image: url(images/hr.png);
height: 10px;
width: 900px;
}
.full-header {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 10px;
color : #878781;
border : 0px solid #000000;
}
.footer {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 10px;
color : #878781;
background-color : #ffffff;
padding : 0px 110px 0px 0px;
}
.button {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 10px;
color : #999999;
background-color : #474747;
height : 20px;
border : 0px solid #000000;
margin-top : 2px;
}
.textbox {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 10px;
color : #979797;
background-color : #353535;
border : 1px solid #444444;
}
.main-body {
font-size : 11px;
color : #878781;
background-color : #101010;
padding : 0px 10px 0px 10px;
}
.side-body {
font-size : 10px;
color : #777;
background-color : #121212;
padding : 10px;
}
.main-bg {
color : #555;
background-color : #101010;
padding : 0px 0px 0px 0px;
}
.border {
border : 0px solid #ffffff;
}
.side-border-left {
color : #878781;
background-color : #101010;
padding : 0px 5px 0px 0px;
}
.side-border-right {
color : #878781;
background-color : #101010;
padding : 0px 5px 0px 0px;
}
.news-footer {
font-size : 10px;
color : #ffffff;
background-color : #141616;
padding : 3px 4px 4px 4px;
}
.capmain {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 10px;
font-weight : bold;
color : #ffffff;
padding : 4px
}
.scapmain {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 10px;
font-weight : bold;
color : #ffffff;
background-color : #ffffff;
height: 30px;
}
.tbl-border {
color : #333333;
background-color : #333333;
}
.tbl {
font-size : 11px;
color : #878781;
background-color : #181818;
padding : 4px;
}
.tbl3 {
font-size : 11px;
color : #878781;
background-color : #101010;
padding : 4px;
}
.tbl1 {
font-size : 11px;
color : #878781;
background-color : #151515;
padding : 4px;
}
.tbl2 {
font-size : 11px;
color : #878781;
background-color : #222222;
padding : 4px;
}
.forum-caption {
font-size : 11px;
font-weight : bold;
height: 25px;
color : #898989;
background-color : #333333;
padding : 2px 4px 4px 4px;
}
.quote {
font-size : 11px;
color : #808080;
background-color : #333333;
padding : 4px;
margin : 0px 20px 0px 20px;
border : 1px solid #000;
}
.poll {
height : 12px;
border : 1px solid #000000;
}
.comment-name {
font-weight : bold;
color : #000;
}
.shoutboxname {
font-weight : bold;
color : #000;
}
.shoutbox {
color : #FFFFFF;
}
.shoutboxdate {
font-size : 10px;
color : #000;
}
.small {
font-size : 10px;
font-weight : normal;
}
.small2 {
font-size : 10px;
font-weight : normal;
color : #000000;
}
.side-small {
font-size : 10px;
font-weight : normal;
color : #000000;
background-color : #555555;
}
.side-label {
color : #000;
background-color : #555555;
padding : 2px 2px 3px 2px;
}
.admin-message {
font-family : Verdana, Arial, Helvetica, sans-serif;
font-size : 11px;
text-align : center;
color : #555;
background-color : #f6f6f6;
border : 1px solid #e1e1e1;
padding : 3px 4px 5px 4px;
margin-bottom : 5px;
}
.center {
margin : 0 auto;
}
Moja strona www.loong3d.pl
PW od moderatora:
- Odświeżenie Tematu - Pieka 10.01 - 12:30
Edytowane przez Drecha dnia 10.01.2011 18:03:27
|