Temos pavadinimas: WordPress, Shopify ir PHPFusion programuotojų bendruomenė :: Fecn klausimai

Parašė E01· 2009 Vas. 27 22:02:36
#23

Taigi noriu įdėti į dizaina mygutkus štai kur norėčiau kad būtų foto:




Themes.php kodas:
<?php
if (!defined("IN_FUSION")) { header("Location: ../../index.php"); exit; }
require_once INCLUDES."theme_functions_include.php";

// theme settings
$body_text = "#555555";
$body_bg = "#ffffff";
$theme_width = "100%";
$theme_width_l = "190";
$theme_width_r = "190";

function render_header($header_content) {

global $theme_width,$db_prefix,$aidlink,$userdata;

echo "<table align='center' cellspacing='0' cellpadding='0' width='$theme_width'>
<tr>
<td>
<table width='980' align='center' border='0' cellpadding='0' cellspacing='0' class='header'>

<tr><td width='980' height='47' colspan='8'><img src='".THEME."images/logo.gif'></td></tr>

<tr>

<td rowspan='2'><img src='".THEME."images/left.jpg' width='66' height='188'></td>

<td><img src='".THEME."images/new.jpg' width='231' height='28'></td>

<td rowspan='2'><img src='".THEME."images/space.jpg' width='44' height='188'></td>

<td><img src='".THEME."images/pop.jpg' width='232' height='28'></td>

<td rowspan='2'><img src='".THEME."images/spacer.jpg' width='109' height='188'></td>

<td background='".THEME."images/login.jpg' rowspan='2' width='233' height='188'>";

if (iMEMBER) {

$msg_count = dbcount("(message_id)", "messages", "message_to='".$userdata['user_id']."' AND message_read='0'AND message_folder='0'");


if ($userdata['user_avatar'] != "") {

echo "<img src='".BASEDIR."images/avatars/".$userdata['user_avatar']."' width='80' hight='80' style='margin:5px' align='left'>";
         
}

else {

echo "<img src='".THEME."images/avatar.png' width='80' hight='80' align='left'>";
         
}


if (iADMIN && (iUSER_RIGHTS != "" || iUSER_RIGHTS != "C")) {
echo "<a href='".ADMIN."index.php".$aidlink."' class='head'>(admin) </a>";
}

echo "<b>Sveiki, ".$userdata['user_name']."!</b><br>
<a href='".BASEDIR."profile.php?lookup=".$userdata['user_id']."' class='head'>Tavo profilis</a><br>
<a href='".BASEDIR."edit_profile.php' class='head'>Redaguoti profilį</a><br>
<a href='".BASEDIR."messages.php' class='head'>Asmeninės žinutės</a><br>
<a href='".BASEDIR."members.php' class='head'>Vartotojų sarašas</a><br>
<a href='".BASEDIR."setuser.php?logout=yes' class='head'>Atsijungti[x]</a>";



}

else {

echo "<div align='center'>".(isset($loginerror) ? $loginerror : "")."
<form name='loginform' method='post' action='".FUSION_SELF."'>
<input type='text' name='user_name' class='textbox' value='Slapyvardis' onBlur=\"if(this.value=='') this.value='Slapyvardis';\" onFocus=\"if(this.value=='Slapyvardis') this.value='';\" style='width:185px'><br><br>
<input type='password' name='user_pass' class='textbox' value='Slapyvardis' onBlur=\"if(this.value=='') this.value='Slapyvardis';\" onFocus=\"if(this.value=='Slapyvardis') this.value='';\" style='width:185px'>
<br><input type='submit' name='login' value='JUNGTIS' class='button'><input type='checkbox' name='remember_me' value='o' title='".$locale['063']."' style='vertical-align:middle;'> - Prisiminti mane<br><br>
<a href='".BASEDIR."register.php' class='head'>Registracija </a>|
<a href='".BASEDIR."lostpassword.php' class='head'>Priminimas</a>
</form>
</div>\n";

}

echo "</td>

<td rowspan='2'><img src='".THEME."images/right.jpg' width='66' height='188'></td>

</tr>

<tr><td background='".THEME."images/newbg.jpg' width='231' height='160'>";

$result = dbquery("SELECT * FROM ".$db_prefix."downloads ORDER BY download_datestamp DESC LIMIT 0,10");
if (dbrows($result) != 0) {
while($data = dbarray($result)) {
$itemsubject = trimlink($data['download_title'], 31);
echo "<a href='".BASEDIR."downloads.php?id=".$data['download_cat']."&download_id=".$data['download_id']."' title='".$data['download_title']."' class='head'>$itemsubject</a>
".$data['download_count']."<br>";
}
} else {
echo "<center>Siuntinių nėra !</center>\n";
}

echo "</td><td background='".THEME."images/popbg.jpg' width='232' height='160'>";

$result = dbquery("SELECT * FROM ".$db_prefix."downloads ORDER BY download_count DESC LIMIT 0,10");
if (dbrows($result) != 0) {
while($data = dbarray($result)) {
$itemsubject = trimlink($data['download_title'], 31);
echo "<a href='".BASEDIR."downloads.php?d_id=".$data['download_cat']."&download_id=".$data['download_id']."' title='".$data['download_title']."' class='head'>$itemsubject</a>
".$data['download_count']."<br>";
}
} else {
echo "<center>Siuntinių nėra !</center>\n";
}

echo "</td></tr>

</table>

</td>
</tr>
</table>\n";

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 align='left' class='footer'>".showsublinks()."</td>
<td align='right' class='footer'>TVS: <a href='http://www.php-fusion.co.uk'>Php-Fusion</a> | Dizainas: <a href='http://www.lite.xz.lt'>Lite</a></td>
</td>
</tr>
</table>
</td>
</tr>
</table>\n";

}

function render_news($subject, $news, $info) {

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='center' class='news-footer'>\n";
echo openform("N",$info['news_id']).newsposter($info," &nbsp;").newsopts($info,"&nbsp;").closeform("N",$info['news_id']);
echo "</td>
</tr>
</table>
</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," &middot;").articleopts($info,"&middot;").closeform("A",$info['article_id']);
echo "</td>
</tr>
</table>\n";

}

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 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";

}
?>



O noriu įterpti:
echo "</tr></table></td></tr></table>\n";
   // End banner code / Banerio kodo pabaiga
   echo "<table width='100%' cellspacing='0' cellpadding='0' class='sub-header' background='".THEME."images/side.gif'>\n<tr>";
   echo "<td>\n";
   echo "&nbsp;<a href='".BASEDIR."members.php'><span class='white'>Registruotų vartotojų - ".number_format(dbcount("(user_id)", "users", "user_status<='1'"))."</span></a>\n";
   if ($settings['admin_activation'] == "1") echo "<img src='".THEME."images/bullet.gif' alt=''> ".$locale['015'].dbcount("(user_id)", "users", "user_status='2'")."\n";
   echo ($i == 0 ? "&nbsp;" : "")."</td>";
   echo "</tr></table>\n";
   echo "<table width='100%' border='0' cellpadding='0' cellspacing='0' bgcolor='#FFFFFF'>
  <tr>
    <td><table border='0' align='center' cellpadding='0' cellspacing='0'>
      <tr>
        <td width='75' align='center'><a href='".BASEDIR."index.php'><img src='".THEME."images/Namai.png' border=0' alt='Pradinis'></a></td>
        <td width='75' align='center'><a href='".FORUM."index.php'><img src='".THEME."images/Forumas.png' border=0' alt='Diskusijos'></td>
        <td width='75' align='center'><a href='".BASEDIR."articles.php'><img src='".THEME."images/Straipsniai.png' border=0' alt='Turnyrai'></td>
        <td width='75' align='center'><a href='".BASEDIR."viewpage.php?page_id=1'><img src='".THEME."images/Turnyrai.png' border=0' alt='Straipsniai'></td>
        <td width='75' align='center'><a href='".BASEDIR."downloads.php'><img src='".THEME."images/Siuntiniai.png' border=0' alt='Siuntiniai'></td>
        <td width='75' align='center'><a href='".BASEDIR."reklama.php'><img src='".THEME."images/Reklama.png' border=0' alt='Reklama'></td>
        <td width='75' align='center'><a href='".BASEDIR."bus'><img src='".THEME."images/bus' border=0' alt='Serveriai'></td>
      </tr>
    </table></td>
  </tr>
</table>\n";
   echo "<table width='100%' cellpadding='4' bgcolor='#F8F8F8' cellspacing='0' border='0'><tr>";
}

function render_footer($license=false) {
global $theme_width,$locale,$settings;

   echo "</tr>\n</table>\n";
   echo "<table cellSpacing='0' cellPadding='2' width='100%' border='0' background='".THEME."images/footer.gif' style='padding-left: 50px;'><tr><td height='20' class='white' align='left'><b>Design by <a href='Ner'>Ner</a></b></td></tr></table>";



Bandžiau įdėti nieko neįšėjo.Gal kas įdėsit.
P.S Mygtuku kodas imtas iš EGP themes.php failo.

Redagavo E01· 2009 Vas. 27 22:02:50