1 Sierpień 2010, 04:29
30269 Wiadomości - 5580 wątkach, - 3511 Użytkowników

Autor Wątek: Zmiana koloru działów oraz dodanie 1 dodatku  (Przeczytany 253 razy)

0 Użytkowników i 1 Gość przegląda ten wątek.

Offline Scania1994

  • Użytkownik
  • **
  • Wiadomości: 10
  • Pomógł: +0/-0
  • Wersja SMF: 1.1.1
Zmiana koloru działów oraz dodanie 1 dodatku
« dnia: 29 Styczeń 2010, 21:40 »
Witam
Dało by radę zrobić na forum smf 1.1.11 ( www.kissofdeath.cba.pl ) takiego pola jak na tej stronie http://www.cs-serwer.pl/ podpisane jest ogloszenia. Znajdują się tam serwery ilość graczy itp. Chciałbym się dowiedzieć czy jest możliwość zmiany kolory np. treści działu nr1 - regulamin dział 1 ogłoszenia każdy innym kolorem etc wiem że była taka możliwość w phpbb. Moje  theme gold moon

Offline cieplutki

  • -= Đ€VîĹ =-
  • Tysięcznik
  • ***
  • Wiadomości: 1021
  • Pomógł: +118/-29
  • Płeć: Mężczyzna
  • [ Đ€VîĹ']['€ĂM ČŐŘPŐŘĂŢIŐŇ ] Pŕöúđ Mémbéŕ
    • forum użytkowników programu ewmapa
  • Domyślny styl: Curve
  • Wersja SMF: 2.0 RC 3
Odp: Zmiana koloru działów oraz dodanie 1 dodatku
« Odpowiedź #1 dnia: 29 Styczeń 2010, 22:04 »
Może za pomocą tego moda  ;)
Asus P5E3 | Intel Dual-Core E8400 3.0 GHz | Kingston 3GB DDR3-1066 | Seagate 7200 500GB+250GB+160GB | LG DVDR | GeForce 9600 GT Asus Silent 512MB | Asus Xonar DX/XD | Samsung SyncMaster 2253LW 22'| Windows 7 Ultimate x64 PL

Jak mądrze zadawać pytania?

Offline Scania1994

  • Użytkownik
  • **
  • Wiadomości: 10
  • Pomógł: +0/-0
  • Wersja SMF: 1.1.1
Odp: Zmiana koloru działów oraz dodanie 1 dodatku
« Odpowiedź #2 dnia: 30 Styczeń 2010, 10:51 »
Witam
Dzięki kolorki działów działaja a jak zrobić taką tabelkę np. nazwa serwera| ip| ilosc graczy| screen| tak jak na tej stronie co podawałem. Cieplutki masz +

Offline cieplutki

  • -= Đ€VîĹ =-
  • Tysięcznik
  • ***
  • Wiadomości: 1021
  • Pomógł: +118/-29
  • Płeć: Mężczyzna
  • [ Đ€VîĹ']['€ĂM ČŐŘPŐŘĂŢIŐŇ ] Pŕöúđ Mémbéŕ
    • forum użytkowników programu ewmapa
  • Domyślny styl: Curve
  • Wersja SMF: 2.0 RC 3
Odp: Zmiana koloru działów oraz dodanie 1 dodatku
« Odpowiedź #3 dnia: 30 Styczeń 2010, 16:30 »
Chodzi Ci o ten dział "ogłoszenia" i serwery sc - może poszukaj moda globalne ogłoszenia czy jakoś tak
Asus P5E3 | Intel Dual-Core E8400 3.0 GHz | Kingston 3GB DDR3-1066 | Seagate 7200 500GB+250GB+160GB | LG DVDR | GeForce 9600 GT Asus Silent 512MB | Asus Xonar DX/XD | Samsung SyncMaster 2253LW 22'| Windows 7 Ultimate x64 PL

Jak mądrze zadawać pytania?

Offline Scania1994

  • Użytkownik
  • **
  • Wiadomości: 10
  • Pomógł: +0/-0
  • Wersja SMF: 1.1.1
Odp: Zmiana koloru działów oraz dodanie 1 dodatku
« Odpowiedź #4 dnia: 30 Styczeń 2010, 17:12 »
Tak właśnie o to mi chodzi. Zaraz zacznę pracę z google. Jak coś znajdę to edytuję pościk.

Jak na razie znalazlem tylko to: http://custom.simplemachines.org/mods/index.php?mod=419
Korzystając z Firefoksa jest tam taka funkcja pokaż źródło strony. Troszkę pogrzebałem i znalazłem takie coś na tej stronie cs'a
<div id="hm" style="display: ''; position: relative;">
<table width="100%" class="forumline" cellspacing="1" cellpadding="3" border="0" align="center">
  <tr>
   <th class="thCornerL" height="25" nowrap="nowrap" onclick="javascript:ShowHide('hm','hm2','hm3');" style="cursor: pointer" title="Ukryj">&nbsp;Ogłoszenie&nbsp;</th>

  </tr>
  <tr>
   <td class="row1"><span class="gen"><center>
<br>
<table width="900" class="forumline" cellspacing="1" cellpadding="3" border="0" align="center">
<tr>
<td class="row1" align="center" width="260"> <font color="#ef764b"><b>Monitoring:</b></font></td> 
<td class="row1" align="center"> <font color="#ef764b"><b>Adres IP:</b></font></td>
<td class="row1" align="center"><font color="#ef764b"><b>Nazwa serwera:</b></font></td>

<td class="row1" align="center"> <font color="#ef764b"><b>Sloty</b></font></td>
<td class="row1" align="center"><font color="#ef764b"><b>Steam</b></font></td>
<td class="row1" align="center"><font color="#ef764b"><b>HLSW</b></font></td>
</tr>


<tr>
    <td class="row1"  width="260"><a href="http://www.gametracker.com/server_info/91.210.129.195:27015/" target="_blank"><img src="http://cache.www.gametracker.com/server_info/91.210.129.195:27015/b_350x20_C0D0D0D-0D0D0D-FFFFFF-0D0D0D.png" border="0" width="350" height="20" /></a></b></font></td> 
<td class="row1" align="center"> <b><font color="#ff3600">91.210.129.195:27015</font></b></td>

<td class="row1" align="center"><b>CS-SERWER [TeamPlay]</b></td>
<td class="row1" align="center"> <b>20</font></b></td>
<td class="row1" align="center"><a href="steam://connect/91.210.129.195:27015" border="0"><img src="http://www.cs-serwer.pl/steam.png" width="16" border="0" height="16"></a></td>
<td class="row1" align="center"><a href="hlsw://91.210.129.195:27015" border="0"><img src="http://www.cs-serwer.pl/hlsw.gif" width="16" border="0" height="16"></td>
</tr>

<tr>
    <td class="row1"  width="260"><a href="http://www.gametracker.com/server_info/91.210.129.195:27016/" target="_blank"><img src="http://cache.www.gametracker.com/server_info/91.210.129.195:27016/b_350x20_C0D0D0D-0D0D0D-FFFFFF-0D0D0D.png" border="0" width="350" height="20" /></a></b></font></td> 
<td class="row1" align="center"> <b><font color="#ff3600">91.210.129.195:27016</b></td>

<td class="row1" align="center"><b>CS-SERWER [GG+DM]</b></td>
<td class="row1" align="center"> <b>16</font></b></td>
<td class="row1" align="center"><a href="steam://connect/91.210.129.195:27016" border="0"><img src="http://www.cs-serwer.pl/steam.png" width="16" border="0" height="16"></a></td>
<td class="row1" align="center"><a href="hlsw://91.210.129.195:27016" border="0"><img src="http://www.cs-serwer.pl/hlsw.gif" width="16" border="0" height="16"></td>
</tr>

<tr>
    <td class="row1"  width="260"><a href="http://www.gametracker.com/server_info/91.210.129.195:27017/" target="_blank"><img src="http://cache.www.gametracker.com/server_info/91.210.129.195:27017/b_350x20_C0D0D0D-0D0D0D-FFFFFF-0D0D0D.png" border="0" width="350" height="20" /></a></b></font></td> 
<td class="row1" align="center">  <b><font color="#ff3600">91.210.129.195:27017</b></td>

<td class="row1" align="center"><b>CS-SERWER [FFA]</b></td>
<td class="row1" align="center"> <b>20</font></b></td>
<td class="row1" align="center"><a href="steam://connect/91.210.129.195:27017" border="0"><img src="http://www.cs-serwer.pl/steam.png" width="16" border="0" height="16"></a></td>
<td class="row1" align="center"><a href="hlsw://91.210.129.195:27017" border="0"><img src="http://www.cs-serwer.pl/hlsw.gif" width="16" border="0" height="16"></td>
</tr>

<tr>
    <td class="row1"  width="260"><a href="http://www.gametracker.com/server_info/91.210.129.195:27018/" target="_blank"><img src="http://cache.www.gametracker.com/server_info/91.210.129.195:27018/b_350x20_C0D0D0D-0D0D0D-FFFFFF-0D0D0D.png" border="0" width="350" height="20" /></a></b></font></td> 
<td class="row1" align="center">  <b><font color="#ff3600">91.210.129.195:27018</b></td>

<td class="row1" align="center"><b>CS-SERWER [Diablo Mod]</b></td>
<td class="row1" align="center"> <b>20</font></b></td>
<td class="row1" align="center"><a href="steam://connect/91.210.129.195:27018" border="0"><img src="http://www.cs-serwer.pl/steam.png" width="16" border="0" height="16"></a></td>
<td class="row1" align="center"><a href="hlsw://91.210.129.195:27018" border="0"><img src="http://www.cs-serwer.pl/hlsw.gif" width="16" border="0" height="16"></td>
</tr>

<tr>
    <td class="row1"  width="260"><a href="http://www.gametracker.com/server_info/91.210.129.195:27019/" target="_blank"><img src="http://cache.www.gametracker.com/server_info/91.210.129.195:27019/b_350x20_C0D0D0D-0D0D0D-FFFFFF-0D0D0D.png" border="0" width="350" height="20" /></a></b></font></td> 
<td class="row1" align="center">  <b><font color="#ff3600">91.210.129.195:27019</b></td>

<td class="row1" align="center"><b>CS-SERWER [Jail Break]</b></td>
<td class="row1" align="center"> <b>20</font></b></td>
<td class="row1" align="center"><a href="steam://connect/91.210.129.195:27019" border="0"><img src="http://www.cs-serwer.pl/steam.png" width="16" border="0" height="16"></a></td>
<td class="row1" align="center"><a href="hlsw://91.210.129.195:27019" border="0"><img src="http://www.cs-serwer.pl/hlsw.gif" width="16" border="0" height="16"></td>
</tr>

<tr>
    <td class="row1"  width="260"><a href="http://www.gametracker.com/server_info/91.210.129.195:27020/" target="_blank"><img src="http://cache.www.gametracker.com/server_info/91.210.129.195:27020/b_350x20_C0D0D0D-0D0D0D-FFFFFF-0D0D0D.png" border="0" width="350" height="20" /></a></b></font></td> 
<td class="row1" align="center">  <b><font color="#ff3600">91.210.129.195:27020</b></td>

<td class="row1" align="center"><b>CS-SERWER [AIM/AWP]</b></td>
<td class="row1" align="center"> <b>10</font></b></td>
<td class="row1" align="center"><a href="steam://connect/91.210.129.195:27020" border="0"><img src="http://www.cs-serwer.pl/steam.png" width="16" border="0" height="16"></a></td>
<td class="row1" align="center"><a href="hlsw://91.210.129.195:27020" border="0"><img src="http://www.cs-serwer.pl/hlsw.gif" width="16" border="0" height="16"></td>
</tr>

<tr>
    <td class="row1"  width="260"><a href="http://www.gametracker.com/server_info/91.210.129.195:27021/" target="_blank"><img src="http://cache.www.gametracker.com/server_info/91.210.129.195:27021/b_350x20_C0D0D0D-0D0D0D-FFFFFF-0D0D0D.png" border="0" width="350" height="20" /></a></b></font></td> 
<td class="row1" align="center">  <b><font color="#ff3600">91.210.129.195:27021</b></td>

<td class="row1" align="center"><b>CS-SERWER [ZMI]</b></td>
<td class="row1" align="center"> <b>12</font></b></td>
<td class="row1" align="center"><a href="steam://connect/91.210.129.195:27021" border="0"><img src="http://www.cs-serwer.pl/steam.png" width="16" border="0" height="16"></a></td>
<td class="row1" align="center"><a href="hlsw://91.210.129.195:27021" border="0"><img src="http://www.cs-serwer.pl/hlsw.gif" width="16" border="0" height="16"></td>
</tr>


<tr>
    <td class="row1"  width="260"><a href="http://www.gametracker.com/server_info/91.210.129.195:27022/" target="_blank"><img src="http://cache.www.gametracker.com/server_info/91.210.129.195:27022/b_350x20_C0D0D0D-0D0D0D-FFFFFF-0D0D0D.png" border="0" width="350" height="20" /></a></b></font></td> 
<td class="row1" align="center">  <b><font color="#ff3600">91.210.129.195:27022</b></td>

<td class="row1" align="center"><b>CS-SERWER [Ganiany]</b></td>
<td class="row1" align="center"> <b>12</font></b></td>
<td class="row1" align="center"><a href="steam://connect/91.210.129.195:27022" border="0"><img src="http://www.cs-serwer.pl/steam.png" width="16" border="0" height="16"></a></td>
<td class="row1" align="center"><a href="hlsw://91.210.129.195:27022" border="0"><img src="http://www.cs-serwer.pl/hlsw.gif" width="16" border="0" height="16"></td>
</tr>



<tr>
    <td class="row1"  width="260"><a href="http://www.gametracker.com/server_info/91.121.195.120:4000/" target="_blank"><a href="http://www.gametracker.com/server_info/91.121.195.120:4000/" target="_blank"><img src="http://cache.www.gametracker.com/server_info/91.121.195.120:4000/b_350x20_C0D0D0D-0D0D0D-FFFFFF-0D0D0D.png" border="0" width="350" height="20" /></a></b></font></td> 
<td class="row1" align="center"> <b>s7.voicespeak.org:4000</b></td>

<td class="row1" align="center"><b>SERWER VENTRILO</b></td>
<td class="row1" align="center"> <b>100</b></td>
<td class="row1" align="center"><a href="ventrilo://91.121.195.120:4000" border="0"><img src="http://www.cs-serwer.pl/ts.gif" width="16" border="0" height="16"></a></td>
<td class="row1" align="center"><img src="http://www.cs-serwer.pl/hlsw2.gif" width="16" border="0" height="16"></td>
</tr>
</table>
<br>
</span></td>
  </tr>

</table>
</div>
Może to jakoś ułatwi sprawę. może dało by radę to jakoś wkleić do mojego theme w odpowiednim miejscu i tylko lekko edytować
« Ostatnia zmiana: 30 Styczeń 2010, 17:22 wysłana przez Scania1994 »

Offline bartosh

  • Stały bywalec
  • ****
  • Wiadomości: 99
  • Pomógł: +23/-1
  • Płeć: Mężczyzna
    • VirtualCar.pl
  • Domyślny styl: No!ze
  • Wersja SMF: 2.0 RC 1-2
Odp: Zmiana koloru działów oraz dodanie 1 dodatku
« Odpowiedź #5 dnia: 31 Styczeń 2010, 01:53 »
Co do tabelki, robiłem ją na własnym forum. Robi się to tak samo jak na przemo na przykład lub tak jak pokazał kolega wyżej, tyle że cały kod html musisz dać w tagi

echo' DANY KOD HTML ';
Jednak aby tabelka była ładnie zgrana z forum musisz przypisać odpowiednie klasy do kodu html :)

Jednak jak byś nie wiedział jak to zrobić napisz, podaj nazwę stylu ew. w załączniku dodaj mi plik index.template :)

Offline Scania1994

  • Użytkownik
  • **
  • Wiadomości: 10
  • Pomógł: +0/-0
  • Wersja SMF: 1.1.1
Odp: Zmiana koloru działów oraz dodanie 1 dodatku
« Odpowiedź #6 dnia: 31 Styczeń 2010, 10:37 »
Witam
Jak byś mógł to bardzo proszę. Styl to gold moon ( www.kissofdeath.cba.pl ) chciałbym aby tabela została umieszczona mniej więcej pod aktualnościami. plik index.template wrzucony niżej
<?php
// Version: 1.1.5; index

/* This template is, perhaps, the most important template in the theme. It
contains the main template layer that displays the header and footer of
the forum, namely with main_above and main_below. It also contains the
menu sub template, which appropriately displays the menu; the init sub
template, which is there to set the theme up; (init can be missing.) and
the linktree sub template, which sorts out the link tree.

The init sub template should load any data and set any hardcoded options.

The main_above sub template is what is shown above the main content, and
should contain anything that should be shown up there.

The main_below sub template, conversely, is shown after the main content.
It should probably contain the copyright statement and some other things.

The linktree sub template should display the link tree, using the data
in the $context['linktree'] variable.

The menu sub template should display all the relevant buttons the user
wants and or needs.

For more information on the templating system, please see the site at:
http://www.simplemachines.org/
*/

// Initialize the template... mainly little settings.
function template_init()
{
global $context$settings$options$txt;

/* Use images from default theme when using templates from the default theme?
if this is 'always', images from the default theme will be used.
if this is 'defaults', images from the default theme will only be used with default templates.
if this is 'never' or isn't set at all, images from the default theme will not be used. */
$settings['use_default_images'] = 'never';

/* What document type definition is being used? (for font size and other issues.)
'xhtml' for an XHTML 1.0 document type definition.
'html' for an HTML 4.01 document type definition. */
$settings['doctype'] = 'xhtml';

/* The version this template/theme is for.
This should probably be the version of SMF it was created for. */
$settings['theme_version'] = '1.1';

/* Set a setting that tells the theme that it can render the tabs. */
$settings['use_tabs'] = true;

/* Use plain buttons - as oppossed to text buttons? */
$settings['use_buttons'] = true;

/* Show sticky and lock status seperate from topic icons? */
$settings['seperate_sticky_lock'] = true;
}

// The main sub template above the content.
function template_main_above()
{
global $context$settings$options$scripturl$txt$modSettings;

// Show right to left and the character set for ease of translating.
echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"'
$context['right_to_left'] ? ' dir="rtl"' '''><head>
<meta name="google-site-verification" content="RY60UuVm5hCqnpfjDzuYtT4bFJ5d4UxNvKn83sH5XLY" />
<meta http-equiv="Content-Type" content="text/html; charset='
$context['character_set'], '" />
<meta name="description" content="'
$context['page_title'], '" />', empty($context['robot_no_index']) ? '' '
<meta name="robots" content="noindex" />'
'
<meta name="keywords" content="PHP, MySQL, bulletin, board, free, open, source, smf, simple, machines, forum" />
<script language="JavaScript" type="text/javascript" src="'
$settings['default_theme_url'], '/script.js?fin11"></script>
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var smf_theme_url = "'
$settings['theme_url'], '";
var smf_images_url = "'
$settings['images_url'], '";
var smf_scripturl = "'
$scripturl'";
var smf_iso_case_folding = '
$context['server']['iso_case_folding'] ? 'true' 'false'';
var smf_charset = "'
$context['character_set'], '";
// ]]></script>
<title>'
$context['page_title'], '</title>';

// The ?fin11 part of this link is just here to make sure browsers don't cache it wrongly.
echo '
<link rel="stylesheet" type="text/css" href="'
$settings['theme_url'], '/style.css?fin11" />
<link rel="stylesheet" type="text/css" href="'
$settings['default_theme_url'], '/print.css?fin11" media="print" />';

/* Internet Explorer 4/5 and Opera 6 just don't do font sizes properly. (they are big...)
Thus, in Internet Explorer 4, 5, and Opera 6 this will show fonts one size smaller than usual.
Note that this is affected by whether IE 6 is in standards compliance mode.. if not, it will also be big.
Standards compliance mode happens when you use xhtml... */
if ($context['browser']['needs_size_fix'])
echo '
<link rel="stylesheet" type="text/css" href="'
$settings['default_theme_url'], '/fonts-compat.css" />';

// Show all the relative links, such as help, search, contents, and the like.
echo '
<link rel="help" href="'
$scripturl'?action=help" target="_blank" />
<link rel="search" href="' 
$scripturl '?action=search" />
<link rel="contents" href="'
$scripturl'" />';

// If RSS feeds are enabled, advertise the presence of one.
if (!empty($modSettings['xmlnews_enable']))
echo '
<link rel="alternate" type="application/rss+xml" title="'
$context['forum_name'], ' - RSS" href="'$scripturl'?type=rss;action=.xml" />';

// If we're viewing a topic, these should be the previous and next topics, respectively.
if (!empty($context['current_topic']))
echo '
<link rel="prev" href="'
$scripturl'?topic='$context['current_topic'], '.0;prev_next=prev" />
<link rel="next" href="'
$scripturl'?topic='$context['current_topic'], '.0;prev_next=next" />';

// If we're in a board, or a topic for that matter, the index will be the board's index.
if (!empty($context['current_board']))
echo '
<link rel="index" href="' 
$scripturl '?board=' $context['current_board'] . '.0" />';
   // YSHOUT HERE - <head> code
   
global $boardurl,$shoutFile;
   
$shoutFile='home';
   
$scripturlparsed parse_url($scripturl);
   
$scriptpath=isset($scripturlparsed['path'])?$scripturlparsed['path']:'/';
   
$args='';
   foreach(
$_GET as $key => $value// passthrough $_GET
      
$args.='&'.urlencode($key).'='.urlencode($value);
   echo 
'
   <script src="'
,$boardurl,'/mymod/animatedcollapse.js" type="text/javascript"></script>
   <script src="'
,$boardurl,'/yshout/js/moo.ajax.js" type="text/javascript"></script>
   <script src="'
,$boardurl,'/yshout/settings.js" type="text/javascript"></script>
   <script type="text/javascript"><!-- // --><![CDATA[
   window.onload=function(){loadChat();};
   var shoutFile="'
,$shoutFile,'";
   var yshout_php="'
,$scriptpath,'?yshout',$args,'";
   // ]]></script>
   <script src="'
,$boardurl,'/yshout/js/yshout.js?July062008" type="text/javascript"></script>
   
   <script src="'
,$boardurl,'/yshout/js/soundmanager2.js" type="text/javascript"></script>
      <script type="text/javascript">soundManager.url="'
,$boardurl,'/yshout/soundmanager2.swf";
      soundManager.debugMode = false;
      soundManager.consoleOnly = false;
      soundManager.onload = function() {
      soundManager.createSound({id:"aSound", url:"'
$boardurl'/yshout/chat.mp3", autoPlay:false});
   }</script>
        <style type="text/css">
      #yshout {
         font-size: 13px;
         overflow: hidden;
      }
      #yshout #yshout-toollinks { /* tool links (History, Commands, etc.) */
      }
      #yshout #shouts { /* main shouts area */
             overflow: auto;
             width: 800px;       /* the width you want to display */
               height: 150px;     /* the height you want to display */
      }
      #yshout .shout { /* one shout */
         margin: 0 0 0; /* Top Bottom Linespacing */
         line-height: 1;
      }
      #yshout .shout-timestamp {
         font-style: normal;
         font-weight: normal;
      }
      #yshout .shout-adminlinks { /* del and ban buttons */
         font-size: 8pt;
         color: #141414;
      }
      #yshout #shout-form {
         margin: 0;
         padding: 0;
      }
      #yshout #shout-form fieldset {
         border: none;
      }
      #yshout #forum-name {
         color: #666666;
         width: 70px;
         margin-right: 5px;
      }
      #yshout #shout-text {
         width: 310px;
         margin-right: 5px;
      }
      #yshout #shout-button {
         width: 55px;
      }
      #yshout .shout-invalid { /* invalid shout (shout textbox) */
         background: #FFFDD1;
      }
   </style>'
;
   
// YSHOUT END - <head> code

// We'll have to use the cookie to remember the header...
if ($context['user']['is_guest'])
{
$options['collapse_header'] = !empty($_COOKIE['upshrink']);
$options['collapse_header_ic'] = !empty($_COOKIE['upshrinkIC']);
}

// Output any remaining HTML headers. (from mods, maybe?)
echo $context['html_headers'], '

<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var current_header = '
, empty($options['collapse_header']) ? 'false' 'true'';

function shrinkHeader(mode)
{'
;

// Guests don't have theme options!!
if ($context['user']['is_guest'])
echo '
document.cookie = "upshrink=" + (mode ? 1 : 0);'
;
else
echo '
smf_setThemeOption("collapse_header", mode ? 1 : 0, null, "'
$context['session_id'], '");';

echo '
document.getElementById("upshrink").src = smf_images_url + (mode ? "/upshrink2.gif" : "/upshrink.gif");

document.getElementById("upshrinkHeader").style.display = mode ? "none" : "";
document.getElementById("upshrinkHeader2").style.display = mode ? "none" : "";

current_header = mode;
}
// ]]></script>'
;

// the routine for the info center upshrink
echo '
<script language="JavaScript" type="text/javascript"><!-- // --><![CDATA[
var current_header_ic = '
, empty($options['collapse_header_ic']) ? 'false' 'true'';

function shrinkHeaderIC(mode)
{'
;

if ($context['user']['is_guest'])
echo '
document.cookie = "upshrinkIC=" + (mode ? 1 : 0);'
;
else
echo '
smf_setThemeOption("collapse_header_ic", mode ? 1 : 0, null, "'
$context['session_id'], '");';

echo '
document.getElementById("upshrink_ic").src = smf_images_url + (mode ? "/expand.gif" : "/collapse.gif");

document.getElementById("upshrinkHeaderIC").style.display = mode ? "none" : "";

current_header_ic = mode;
}
// ]]></script>

</head>
<body><div id="size">'
;

echo 
'
<div id="header-r">
 <div id="header-l">
<div id="header"> <div id="logo"></div> 

<div id="memberdet">'
;

 
//Say hello to member
if ($context['user']['is_logged'])
echo '
 '
$txt['hello_member_ndt'], ' <b>'$context['user']['name'], '</b>,';

 // Only tell them about their messages if they can read their messages!
if ($context['allow_pm'])
echo ' <a href="'$scripturl'?action=pm"> '$context['user']['messages'], ' '$context['user']['messages'] != $txt[153] : $txt[471], '</a>'$txt['newmessages4'], ' '$context['user']['unread_messages'], ' '$context['user']['unread_messages'] == $txt['newmessages0'] : $txt['newmessages1'] , '.<br />';

// Show unread replies to members.
  if ($context['user']['is_logged'])
echo '
<a href="'
$scripturl'?action=unread">'$txt['unread_since_visit'] ,'</a><br />
<a href="'
$scripturl'?action=unreadreplies">'$txt['show_unread_replies'] ,'</a>';

// Show the total time logged in?
if ($context['user']['is_logged'])
echo ' <br />
  '
$txt['totalTimeLogged1'];

// If days is just zero, don't bother to show it.
if ($context['user']['is_logged'])
echo $context['user']['total_time_logged_in']['days'] . $txt['totalTimeLogged2'];

// Same with hours - only show it if it's above zero.
if ($context['user']['is_logged'])
echo $context['user']['total_time_logged_in']['hours'] . $txt['totalTimeLogged3'];

  // But, let's always show minutes - Time wasted here: 0 minutes ;).
 if ($context['user']['is_logged'])
echo $context['user']['total_time_logged_in']['minutes'], $txt['totalTimeLogged4'], '';


// Otherwise they're a guest - so politely ask them to register or login.
if ($context['user']['is_guest'])
echo '
'
$txt['welcome_guest'] ,''$txt['welcome_guest_activate'] ,'<br />
<script language="JavaScript" type="text/javascript" src="'
$settings['default_theme_url'], '/sha1.js"></script>
<form action="'
$scripturl'?action=login2" method="post" accept-charset="'$context['character_set'], '" style="margin: 4px 0;"', empty($context['disable_login_hashing']) ? ' onsubmit="hashLoginPassword(this, \'' $context['session_id'] . '\');"' '''>
<input type="text" name="user"  size="10" />
<input type="password" name="passwrd"  size="10" />
<input type="submit" value="'
$txt[34], '" />
<input type="hidden" name="hash_passwrd" value="" />
</form>'
;
echo 
'
</div>
</div>
  </div>
 </div>'
;

// Show the menu here, according to the menu sub template.
  
echo ' <div id="nav-r"><div id="nav-l"><div id="nav"> ' template_menu() , '
</div>
  </div>
 </div>'
;

echo 
' <div id="header-down-r">
 <div id="header-down-l">
<div id="header-down"> 
<div id="news"><b>' 
$txt[102] , ':</b> '$context['random_news_line'] , '
</div>

<div id="searchbox">
<form action="'
$scripturl'?action=search2" method="post" accept-charset="'$context['character_set'], '" style="margin: 0;">
<input class="biginput" type="text" name="search" value="'
$txt[182], '..." onfocus="this.value = \'\';" onblur="if(this.value==\'\') this.value=\''$txt[182], '...\';" style="width: 170px;" /></form></div>

 </div>
</div>
  </div>'
;

// The main content should go here.
echo '<br />
<div id="mainarea-r"><div id="mainarea-l"><div id="mainarea">'
;
}

function 
template_main_below()
{
global $context$settings$options$scripturl$txt;

echo 
'
</div></div></div>
<div id="footer-r"><div id="footer-l"><div id="footer">

  <br /> '
theme_copyright(), '
 <br />GoldMoon by SCANIA    <a href="http://www.cba.pl">Darmowy Hosting CBA.PL</a></a>
 <div align="center"><!-- stat.4u.pl NiE KaSoWaC -->
 <a target=_top href="http://stat.4u.pl/?kissofdeath"><img src="http://adstat.4u.pl/s4u.gif" border="0"></a>
 <script language="javascript" type="text/javascript">
 <!--
 function s4upl() { return "&amp;r=er";}
 //-->
 </script>
 <script language="JavaScript" type="text/javascript" src="http://adstat.4u.pl/s.js?kissofdeath"></script>
 <script language="JavaScript" type="text/javascript">
 <!--
 s4uext=s4upl();
 document.write(\'<img src="http://stat.4u.pl/cgi-bin/s.cgi?i=kissofdeath\'+s4uext+\'" width="1" height="1">\')
 //-->
 </script>
 <noscript><img src="http://stat.4u.pl/cgi-bin/s.cgi?i=kissofdeath&amp;r=ns" width="1" height="1"></noscript>
 <!-- stat.4u.pl KoNiEc -->
</div>
</div></div></div></div>
<div align="center"><script TYPE="text/javascript" src="http://www.cpmprofit.com/ads.php?r=196239791f37297332c36fa0486b9ac684454e4615005556&popup=0"></script>
</body></html>'
;
}

// Show a linktree. This is that thing that shows "My Community | General Category | General Discussion"..
function theme_linktree()
{
global $context$settings$options;

echo '<div class="nav" style="font-size: smaller; margin-bottom: 2ex; margin-top: 2ex;">';

// Each tree item has a URL and name. Some may have extra_before and extra_after.
foreach ($context['linktree'] as $link_num => $tree)
{
// Show something before the link?
if (isset($tree['extra_before']))
echo $tree['extra_before'];

// Show the link, including a URL if it should have one.
echo '<b>'$settings['linktree_link'] && isset($tree['url']) ? '<a href="' $tree['url'] . '" class="nav">' $tree['name'] . '</a>' $tree['name'], '</b>';

// Show something after the link...?
if (isset($tree['extra_after']))
echo $tree['extra_after'];

// Don't show a separator for the last one.
if ($link_num != count($context['linktree']) - 1)
echo '&nbsp;>&nbsp;';
}

echo '</div>';
}

// Show the menu up top. Something like [home] [help] [profile] [logout]...
function template_menu()
{
global $context$settings$options$scripturl$txt;

// Work out where we currently are.
$current_action 'home';
if (in_array($context['current_action'], array('admin''ban''boardrecount''cleanperms''detailedversion''dumpdb''featuresettings''featuresettings2''findmember''maintain''manageattachments''manageboards''managecalendar''managesearch''membergroups''modlog''news''optimizetables''packageget''packages''permissions''pgdownload''postsettings''regcenter''repairboards''reports''serversettings''serversettings2''smileys''viewErrorLog''viewmembers')))
$current_action 'admin';
if (in_array($context['current_action'], array('search''admin''calendar''profile''mlist''register''login''help''pm')))
$current_action $context['current_action'];
if ($context['current_action'] == 'search2')
$current_action 'search';
if ($context['current_action'] == 'theme')
$current_action = isset($_REQUEST['sa']) && $_REQUEST['sa'] == 'pick' 'profile' 'admin';

// Are we using right-to-left orientation?
if ($context['right_to_left'])
{
$first 'last';
$last 'first';
}
else
{
$first 'first';
$last 'last';
}

  
// Show the start of the tab section.

echo '
<ul>'
;

// Show the [home] button.
echo '<li><a href="'$scripturl'">' $txt[103] , '</a></li>';

// Show the [help] button.
echo '<li><a href="'$scripturl'?action=help">' $txt[119] , '</a></li>';

// How about the [search] button?
if ($context['allow_search'])
echo '<li><a href="'$scripturl'?action=search">' $txt[182] , '</a></li>';

// Is the user allowed to administrate at all? ([admin])
if ($context['allow_admin'])
echo '<li><a href="'$scripturl'?action=admin">' $txt[2] , '</a></li>';

// Edit Profile... [profile]
if ($context['allow_edit_profile'])
echo '<li><a href="'$scripturl'?action=profile">' $txt[79] , '</a></li>';

// Go to PM center... [pm]
if ($context['user']['is_logged'] && $context['allow_pm'])
echo '<li><a href="'$scripturl'?action=pm">' $txt['pm_short'] , ' '$context['user']['unread_messages'] > '[<strong>'$context['user']['unread_messages'] . '</strong>]' '' '</a></li>';


// The [calendar]!
if ($context['allow_calendar'])
echo '<li><a href="'$scripturl'?action=calendar">' $txt['calendar24'] , '</a></li>';

// the [member] list button
if ($context['allow_memberlist'])
echo '<li><a href="'$scripturl'?action=mlist">' $txt[331] , '</a></li>';

// If the user is a guest, show [login] button.
if ($context['user']['is_guest'])
echo '<li><a href="'$scripturl'?action=login">' $txt[34] , '</a></li>';


// If the user is a guest, also show [register] button.
if ($context['user']['is_guest'])
echo '<li><a href="'$scripturl'?action=register">' $txt[97] , '</a></li>';


// Otherwise, they might want to [logout]...
if ($context['user']['is_logged'])
echo '<li><a href="'$scripturl'?action=logout;sesc='$context['session_id'], '">' $txt[108] , '</a></li>';

echo '</ul>';

}

// Generate a strip of buttons.
function template_button_strip($button_strip$direction 'top'$force_reset false$custom_td '')
{
global $settings$buttons$context$txt$scripturl;

// Create the buttons...
foreach ($button_strip as $key => $value)
{
if (isset($value['test']) && empty($context[$value['test']]))
{
unset($button_strip[$key]);
continue;
}
elseif (!isset($buttons[$key]) || $force_reset)
$buttons[$key] = '<a href="' $value['url'] . '" ' .( isset($value['custom']) ? $value['custom'] : '') . '>' $txt[$value['text']] . '</a>';

$button_strip[$key] = $buttons[$key];
}

if (empty($button_strip))
return '<td>&nbsp;</td>';

echo '
<td class="'
$direction == 'top' 'main' 'mirror''tab_' $context['right_to_left'] ? 'last' 'first' '">&nbsp;</td>
<td class="'
$direction == 'top' 'main' 'mirror''tab_back">'implode(' &nbsp;|&nbsp; '$button_strip) , '</td>
<td class="'
$direction == 'top' 'main' 'mirror''tab_' $context['right_to_left'] ? 'first' 'last' '">&nbsp;</td>';
}

?>

 

Related Topics

  Temat / Zaczęty przez Odpowiedzi Ostatnia wiadomość
7 Odpowiedzi
1026 Wyświetleń
Ostatnia wiadomość 11 Marzec 2007, 15:33
wysłana przez wahnsinnig
4 Odpowiedzi
411 Wyświetleń
Ostatnia wiadomość 24 Sierpień 2007, 12:34
wysłana przez magmagiq
3 Odpowiedzi
506 Wyświetleń
Ostatnia wiadomość 13 Marzec 2008, 17:51
wysłana przez roco
1 Odpowiedzi
537 Wyświetleń
Ostatnia wiadomość 28 Lipiec 2008, 08:15
wysłana przez rookie
1 Odpowiedzi
451 Wyświetleń
Ostatnia wiadomość 30 Lipiec 2008, 19:28
wysłana przez lolek2