Szukaj w:
.

 Zobacz Temat

Strona Główna Forum | Themes, Style, Szablony, CSS | Themes, Style, Szablony, CSS
#112891 27.05.2010 16:49:16 - Problem z themem...
Avatar Użytkownika
Ostrzeżeń: 0
Postów: 26
Post napisano: 27.05.2010 16:49:16
Witam pobrałem sobie fajnego thema lecz niedziała mi panel admina sprawdźcie co z tym nie tak plz... To jest w 255 linijce...

To jest cały kod theme.php
<style type="text/css">

#dropmenudiv{
position:absolute;
border:1px solid #343434;
border-bottom-width: 0;
font:normal 12px Verdana;
line-height:14px;
z-index:100;
}

#dropmenudiv a{
width: 100%;

display:block;
text-indent: 3px;
border-bottom: 1px solid #343434;
padding: 1px 0;
text-decoration: none;
font-size:10px;

}

#dropmenudiv a:hover{ /*hover background color*/
background-color:#343434;
color:#aed819;
}

/* <![CDATA[ */
a { text-decoration: none }
/* ]]> */
}

</style>


<script type="text/javascript">

/***********************************************
* AnyLink Drop Down Menu- ˆ Dynamic Drive (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/

//Contents for menu 1
var menu1=new Array()
menu1[0]='<a href="/news.php">Strona Główna</a>'
menu1[1]='<a href="/news_cats.php">Kategorie newsów</a>'
menu1[2]='<a href="/photogallery.php">Galeria</a>'
menu1[3]='<a href="/weblinks.php">Linki</a>'
menu1[4]='<a href="/viewpage.php?page_id=81">Historia</a>'
menu1[5]='<a href="/contact.php">Kontakt</a>'
menu1[6]='<a href="/search.php">Szukaj</a>'


//Contents for menu 2
var menu2=new Array()
menu2[0]='<a href="http://swiathp.com/articles.php?cat_id=15">Aktorzy</a>'
menu2[1]='<a href="http://swiathp.com/articles.php?cat_id=14">Filmy</a>'
menu2[2]='<a href="http://swiathp.com/articles.php?cat_id=16">Gry</a>'
menu2[3]='<a href="http://swiathp.com/articles.php?cat_id=12">Hogwart</a>'
menu2[4]='<a href="http://swiathp.com/articles.php?cat_id=5">Inne</a>'
menu2[5]='<a href="http://swiathp.com/articles.php?cat_id=17">Ksi±żki</a>'
menu2[6]='<a href="http://swiathp.com/articles.php?cat_id=2">Miejsca</a>'
menu2[7]='<a href="http://swiathp.com/articles.php?cat_id=3">Przedmioty</a>'
menu2[8]='<a href="http://swiathp.com/articles.php?cat_id=7">Stworzenia</a>'
menu2[9]='<a href="http://swiathp.com/articles.php?cat_id=8">Postacie</a>'
menu2[10]='<a href="http://swiathp.com/articles.php?cat_id=13">Wywiady</a>'
menu2[11]='<a href="http://swiathp.com/articles.php?cat_id=9">¦wiat HP</a>'



//Contents for menu 3, and so on
var menu3=new Array()
menu3[0]='<a href="/faq?cat_id=1">Strona</a>'
menu3[1]='<a href="/faq?cat_id=2">Forum</a>'
menu3[2]='<a href="/faq?cat_id=3">Ostrzeżenia i Pochwały</a>'
menu3[3]='<a href="/faq?cat_id=4">Punkty i Rangi</a>'
menu3[4]='<a href="/faq?cat_id=5">Użytkownicy</a>'


   
var menuwidth='165px' //default menu width
var menubgcolor='#2a2a2a' //menu bgcolor
var disappeardelay=250 //menu disappear speed onMouseout (in miliseconds)
var hidemenu_onclick="yes" //hide menu when user clicks within menu?

/////No further editting needed

var ie4=document.all
var ns6=document.getElementById&&!document.all

if (ie4||ns6)
document.write('<div id="dropmenudiv" style="visibility:hidden;width:'+menuwidth+';background-color:'+menubgcolor+'" onMouseover="clearhidemenu()" onMouseout="dynamichide(event)"></div>')

function getposOffset(what, offsettype){
var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop;
var parentEl=what.offsetParent;
while (parentEl!=null){
totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;
parentEl=parentEl.offsetParent;
}
return totaloffset;
}


function showhide(obj, e, visible, hidden, menuwidth){
if (ie4||ns6)
dropmenuobj.style.left=dropmenuobj.style.top="-500px"
if (menuwidth!=""){
dropmenuobj.widthobj=dropmenuobj.style
dropmenuobj.widthobj.width=menuwidth
}
if (e.type=="click" && obj.visibility==hidden || e.type=="mouseover")
obj.visibility=visible
else if (e.type=="click")
obj.visibility=hidden
}

function iecompattest(){
return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
}

function clearbrowseredge(obj, whichedge){
var edgeoffset=0
if (whichedge=="rightedge"){
var windowedge=ie4 && !window.opera? iecompattest().scrollLeft+iecompattest().clientWidth-15 : window.pageXOffset+window.innerWidth-15
dropmenuobj.contentmeasure=dropmenuobj.offsetWidth
if (windowedge-dropmenuobj.x < dropmenuobj.contentmeasure)
edgeoffset=dropmenuobj.contentmeasure-obj.offsetWidth
}
else{
var topedge=ie4 && !window.opera? iecompattest().scrollTop : window.pageYOffset
var windowedge=ie4 && !window.opera? iecompattest().scrollTop+iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18
dropmenuobj.contentmeasure=dropmenuobj.offsetHeight
if (windowedge-dropmenuobj.y < dropmenuobj.contentmeasure){ //move up?
edgeoffset=dropmenuobj.contentmeasure+obj.offsetHeight
if ((dropmenuobj.y-topedge)<dropmenuobj.contentmeasure) //up no good either?
edgeoffset=dropmenuobj.y+obj.offsetHeight-topedge
}
}
return edgeoffset
}

function populatemenu(what){
if (ie4||ns6)
dropmenuobj.innerHTML=what.join("")
}


function dropdownmenu(obj, e, menucontents, menuwidth){
if (window.event) event.cancelBubble=true
else if (e.stopPropagation) e.stopPropagation()
clearhidemenu()
dropmenuobj=document.getElementById? document.getElementById("dropmenudiv") : dropmenudiv
populatemenu(menucontents)

if (ie4||ns6){
showhide(dropmenuobj.style, e, "visible", "hidden", menuwidth)

dropmenuobj.x=getposOffset(obj, "left")
dropmenuobj.y=getposOffset(obj, "top")
dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+"px"
dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+"px"
}

return clickreturnvalue()
}

function clickreturnvalue(){
if (ie4||ns6) return false
else return true
}

function contains_ns6(a, b) {
while (b.parentNode)
if ((b = b.parentNode) == a)
return true;
return false;
}

function dynamichide(e){
if (ie4&&!dropmenuobj.contains(e.toElement))
delayhidemenu()
else if (ns6&&e.currentTarget!= e.relatedTarget&& !contains_ns6(e.currentTarget, e.relatedTarget))
delayhidemenu()
}

function hidemenu(e){
if (typeof dropmenuobj!="undefined"){
if (ie4||ns6)
dropmenuobj.style.visibility="hidden"
}
}

function delayhidemenu(){
if (ie4||ns6)
delayhide=setTimeout("hidemenu()",disappeardelay)
}

function clearhidemenu(){
if (typeof delayhide!="undefined")
clearTimeout(delayhide)
}

if (hidemenu_onclick=="yes")
document.onclick=hidemenu

</script>



<?php
if (!defined("IN_FUSION")) { header("Location: ../../index.php"); exit; }
require_once INCLUDES."theme_functions_include.php";
$body_text = "#ffffff";
$body_bg = "#2c2c2c";
$theme_width = "955";
$theme_width_l = "207";
$theme_width_r = "207";

function render_header($header_content) {
global $theme_width, $userdata, $db_prefix;

echo"<table width='".$theme_width."' align='center' cellspacing='0' cellpadding='0'>
   <tr>

     <td colspan='3' background='".THEME."images/swiathp_02.gif' width='955' height='76'></td>
   </tr>
   <tr>
     <td background='".THEME."images/swiathp_06.gif' width='641' height='167'></td>
     <td background='".THEME."images/swiathp_05.gif' width='314' height='167' style='background-repeat: no-repeat' align='center'";
      if(iGUEST){
        echo">Wpisz <b>Login</b> i <b>Hasło</b>, a następnie kliknij <b>Loguj</b>.<br><br>
        <form name='loginform' method='POST' action='".FUSION_SELF."'>
         <input type='text' name='user_name' value='Login' class='textbox' onBlur=\"if(this.value=='') this.value='Login'\" onFocus=\"if(this.value=='Login') this.value='';\">
         <input type='password' name='user_pass' value='Hasło' class='textbox' onBlur=\"if(this.value=='') this.value='Hasło'\" onFocus=\"if(this.value=='Hasło') this.value='';\">
         <input type='checkbox' name='remember_me' value='y' title='Zapamiętaj mnie' class='textbox'><input type='submit' name='login' class='button' value='Loguj'>
        </form><br><a href='".BASEDIR."register.php'>Zarejestruj się</a> | <a href='".BASEDIR."lostpassword.php'>Przypomnij Hasło</a>";
      }else{
        $caution_r = dbquery("SELECT * from ".$db_prefix."cautions WHERE user_id=".$userdata['user_id']);
        $caution = dbarray($caution_r);
        $c_count = dbrows($caution_r);
        $pochwaly_r = dbquery("SELECT * from ".$db_prefix."pochwaly WHERE user_id=".$userdata['user_id']);
        $pochwaly = dbarray($pochwaly_r);
        $p_count = dbrows($pochwaly_r);
        $msg_count = dbcount("(message_id)", "messages", "message_to='".$userdata['user_id']."' AND message_read='0'AND message_folder='0'");
        echo"<div style='padding: 30px 0px 0px 0px'><a href='".BASEDIR."profile.php?lookup=".$userdata['user_id']."' style='color:#".$userdata['user_color']."'>".$userdata['user_prefix'].$userdata['user_name']."</a>, witaj na wT-Clan.pl!<br></div>
        <div style='float: left; padding: 5px 0px 0px 10px'>".($userdata['user_avatar'] ? "<img src='".IMAGES."avatars/".$userdata['user_avatar']."' width='50' height='50'>" : "<img src='".FORUM."images/brak.gif' width='50' height='50'>")."</div>
        <table align='center'>
        <tr>
        <td><a href='".BASEDIR."profile.php?lookup=".$userdata['user_id']."'>Mój Profil</a></td><td> - </td><td>";
        if (iADMIN && (iUSER_RIGHTS != "" || iUSER_RIGHTS != "C")) {

echo " <a href='".ADMIN."index.php$aidlink'>Panel Administratora</a></td></tr>";
}
echo "<tr><td><a href='".BASEDIR."edit_profile.php'>Edytuj Profil</a></td><td> - </td><td><a href='team2.php'>Admini</a></td></tr>
   <tr><td><a href='".BASEDIR."messages.php'>Wiadomoci</a>";
   if ($msg_count) echo "<a href='".BASEDIR."messages.php'>".sprintf('[<b>%u /20</b>]' , $msg_count)."</a>";
   echo "</td><td> - </td><td><a href='forum/my_followed_threads.php'>Powiadamianie</a></td></tr>
   <tr><td><a href='".BASEDIR."members.php'>Użytkownicy</a></td><td></tr>
   </table>
       <table align='center'>
        <tr>
        <td>Punktów: ".show_points($userdata['user_id'])." | <font color='red'>Ostrzeżeń: ".$c_count."</font></td>
        </tr>
        </table>
        <div style='clear: both; float: right; padding: 0px 10px 0px 0px'><a href='".BASEDIR."setuser.php?logout=yes'>Wyloguj [x]</a></div>";
      }
     echo"</td>
   </tr>
  </table>
  <table width='".$theme_width."' align='center' cellspacing='0' cellpadding='0' background='".THEME."images/swiathp_08.gif'>
   <tr>
     <td width='104' height='40'><a href='".BASEDIR."news.php' onClick=\"return clickreturnvalue()\" onMouseover=\"dropdownmenu(this, event, menu1, '150px')\" onMouseout=\"delayhidemenu()\"><img src='".THEME."images/swiathp_10.gif'</td>
     <td width='119' height='40'><a href='".FORUM."index.php'><img src='".THEME."images/swiathp_11.gif'></a></td>
     <td width='98' height='40'><a href='".BASEDIR."articles.php' onClick=\"return clickreturnvalue()\" onMouseover=\"dropdownmenu(this, event, menu2, '150px')\" onMouseout=\"delayhidemenu()\"><img src='".THEME."images/swiathp_12.gif'></a></td>
     <td width='107' height='40'><a href='".BASEDIR."faq.php' onClick=\"return clickreturnvalue()\" onMouseover=\"dropdownmenu(this, event, menu3, '150px')\" onMouseout=\"delayhidemenu()\"><img src='".THEME."images/swiathp_13.gif'></a></td>
     <td width='117' height='40'><a href='".BASEDIR."team2.php'><img src='".THEME."images/swiathp_14.gif'></a></td>
     <td width='97' height='40'><a href='".BASEDIR."contact.php'><img src='".THEME."images/swiathp_15.gif'></a></td>
     <td width='313' height='40' background='".THEME."images/swiathp_08.gif'></td>
   </tr>


  </table>
  <table width='".$theme_width."' align='center' cellspacing='0' cellpadding='0'><tr>";
}

function render_footer($license=false) {
  echo"</tr>
  </table>
  <table width='".$theme_width."' align='center' cellspacing='0' cellpadding='0'>
   <tr>
     <td background='".THEME."images/swiathp_32.gif' width='955' height='61'><div style='float: left; padding: 0px 15px 0px 20px'>Copyright ˆ 2010 by <a href='http://swiathp.com'>SwiatHP.com</a> || Design: eTek || Code: <a href='maito: andrzejster@o2.pl'>Andrzejster</a></div><div style='float: right; text-align: right; padding: 0px 20px 0px 0px'>CMS: <a href='http://extreme-fusion.pl' target='_blank'>eXtreme-Fusion</a></div></td>
   </tr>
  </table>";
}

function render_news($subject, $news, $info) {
  echo"<table width='540' align='center' cellspacing='0' cellpadding='0'>
   <tr>
     <td background='".THEME."images/swiathp_24.gif' width='540' height='42' style='background-repeat: no-repeat' class='center-panel-t'>".$subject."</td>
   </tr>
   <tr>
     <td background='".THEME."images/swiathp_27.gif' width='540' style='background-repeat: repeat-y' class='center-panel-c'>".$news."</td>
   </tr>
   <tr>
     <td background='".THEME."images/swiathp_28.gif' width='540' height='33' style='background-repeat: no-repeat' class='center-panel-c' align='center'>
     Dodane przez: <a href='".BASEDIR."profile.php?lookup=".$info['user_id']."'><b>".$info['user_name']."</b></a> dnia: ".showdate("%d.%m.%Y, %H:%M", $info['news_date'])."</td>
   </tr>
  </table>";
  tablebreak();
}

function render_article($subject, $article, $info) {
  echo"<table width='540' align='center' cellspacing='0' cellpadding='0'>
   <tr>
     <td background='".THEME."images/swiathp_24.gif' width='540' height='42' style='background-repeat: no-repeat' class='center-panel-t'>".$subject."</td>
   </tr>
   <tr>
     <td background='".THEME."images/swiathp_27.gif' width='540' style='background-repeat: repeat-y' class='center-panel-c'>".$article."</td>
   </tr>
   <tr>
     <td background='".THEME."images/swiathp_28.gif' width='540' height='33' style='background-repeat: no-repeat' class='center-panel-c' align='center'>
Dodał: <a href='profile.php?lookup=".$info['user_id']."'><b>".$info['user_name']."</b></a>
Data: ".showdate("longdate", $info['article_date'])."
Komentarzy: <a href='readarticle.php?article_id=".$info['article_id']."'>".$info['article_comments']."</a>
Czytań: ".$info['article_reads']."
<a href='print.php?type=A&item_id=".$info['article_id']."'><img src='".THEME."images/printer.gif' alt='Drukuj' border='0' style='vertical-align:middle;'></a></td>
   </tr>
  </table>";
  tablebreak();
}

function opentable($title) {
  echo"<table width='540' align='center' cellspacing='0' cellpadding='0'>
   <tr>
     <td background='".THEME."images/swiathp_24.gif' width='540' height='42' style='background-repeat: no-repeat' class='center-panel-t'>".$title."</td>
   </tr>
   <tr>
     <td background='".THEME."images/swiathp_27.gif' width='540' style='background-repeat: repeat-y' class='center-panel-c'>";
}

function closetable() {
     echo"</td>
   </tr>
   <tr>
     <td><img src='".THEME."images/swiathp_28.gif' width='540'></td>
   </tr>
  </table>";
  tablebreak();
}


function openside($title) {
global $theme_width_l;
  echo"<table width='".$theme_width_l."' align='center' cellspacing='0' cellpadding='0'>
   <tr>
     <td background='".THEME."images/swiathp_21.gif' width='207' height='48' style='background-repeat: no-repeat' class='side-panel-t'>".$title."</td>
   </tr>
   <tr>
     <td background='".THEME."images/swiathp_26.gif' width='207' style='background-repeat: repeat-y' class='side-panel-c'>";
}

function closeside() {
     echo"</td>
   </tr>
   <tr>
     <td></td>
   </tr>
  </table>";
  tablebreak();
}

function opensidex($title,$open="on") {
global $theme_width_l;
$boxname = str_replace(" ", "", $title);
  echo"<table width='".$theme_width_l."' align='center' cellspacing='0' cellpadding='0'>
   <tr>
     <td background='".THEME."images/swiathp_21.gif' width='207' height='48' style='background-repeat: no-repeat' class='side-panel-t'>".$title." ".panelbutton($state,$boxname)."</td>
   </tr>
   <tr>
     <td background='".THEME."images/swiathp_26.gif' width='207' style='background-repeat: repeat-y' class='side-panel-c'>
      <div id='box_$boxname'".($open=="off" ? "style='display:none'" : "").">";
}

function closesidex() {
      echo"</div>
     </td>
   </tr>
   <tr>
     <td></td>
   </tr>
  </table>";
  tablebreak();
}

function tablebreak() {
  echo"<div style='padding: 3px 0px 0px 0px'></div>";
}
?>

Wyślij Prywatną Wiadomość
#112892 27.05.2010 16:54:11 - RE: Problem z themem...
Avatar Użytkownika
Ostrzeżeń: 0
Postów: 1674
Post napisano: 27.05.2010 16:54:11
Wiedziałem, że czegoś w tym themie nie poprawiłem ;)

Linia ~223:
global $theme_width, $userdata, $db_prefix; 

Zamień na:
global $theme_width, $userdata, $db_prefix, $aidlink;

Wyślij Prywatną Wiadomość
#112894 27.05.2010 16:56:33 - RE: Problem z themem...
Avatar Użytkownika
Ostrzeżeń: 0
Postów: 26
Post napisano: 27.05.2010 16:56:33
Wielkie thx Andrzejster a no tak zapomniałem że to ty to robiłęś ^^
Wyślij Prywatną Wiadomość


Szybka Odpowiedź


Musisz się zalogować by móc zamieszczać posty w tym temacie.