Dopasowanie lastvisit do szablonu

Inne  Założony przez  Szogi1910.

wersja skryptu MyBB:1.6.13
adres forum:gamesing.pl
na czym polega problem (screen, opis, komunikaty, nazwa stylu/theme/szablonu):

Chce dopasować sobie wygląd lastvisit jak jest dla znajomych w poglądzie profilu już mam to zrobione praktycznie tylko nie mogę i nie wiem jak by tą belkę z napisem osatnio byli rozciągnąć jak w widoku wyżej dla znajomi.
[Obrazek: 71425974830840936756_thumb.jpg]
<table border="0" cellspacing="{$theme['borderwidth']}cellpadding="{$theme['tablespace']}class="tborder">
<
tr>
<
td class="thead_p">
<
strong>Ostatnio Byli</strong>
</
td>
</
tr>
<
tr>
<
td class="trow_kat5">
{
$lastvisitor}
</
td>
</
tr>
</
table>  

Dodam iż jak by ktoś chciał to zobaczyć na moim forum,musi zjechać na dół strony i zmienić styl na shit_v1
Nie można zmienić stylu
H1Z1Forum.PL - Polska społeczność graczy H1Z1
a pokaz jeszcze
member_profile_buddylist
member_profile_buddylist_content
bo to podobno na carbonie jest budowane
member_profile_buddylist
<div class="tabela_podglad">
<
h3>Znajomi</h3>
<
div class="tabela_srd">                                            

{
$buddy_list_row}
{
$informacja}
</
div>
     </
div
member_profile_buddylist_content
<a href="member.php?action=profile&uid={$id}">
<
img src="{$avatar}title="{$nick}class="tipTip userAvatar" width="34" height="34">
</
a

Dodam że instalując styl on nie wymaga dodawania takich szablonów acz kolwiek jak zauważyłem nie które czerpie z szablonów globalnych, jeżeli jest zainstalowany styl carbon jeżeli nie bez tych szablonów też działa poprawnie, jedynie co w paczce było i wykorzystuje z carbona to plugin dodatki do szablonu
zobacz tak

<div class="tabela_podglad">
<h3>Ostatnio Byli</h3>
<div class="tabela_srd">
{$lastvisitor}
</div>
     </div>

i tak dla pewnosci pokaz jeszcze member_profile
Teraz to trochę całkiem się rozwaliło
Cały styl można zobaczyć na koncie testowym
L:tester
H:gamesing
[Obrazek: 10597290060533452514_thumb.jpg]

<?php 
    
    $query 
$db->query("SELECT * FROM ".TABLE_PREFIX."users WHERE uid='".$memprofile['uid']."'");
    
$query2 $db->query("SELECT * FROM ".TABLE_PREFIX."userfields WHERE ufid='".$memprofile['uid']."'");
    
    
$info $db->fetch_array($query);
        
$website $info['website'];
        
$group_id $info['usergroup'];
        
$repinfo $info['reputation'];
        

        if(
$website == ''$website 'Nie określono';
    
    
$query3 $db->query("SELECT * FROM ".TABLE_PREFIX."usergroups WHERE gid='$group_id'");
    
$grupka $db->fetch_array($query3);
    
    
$grupa format_name($grupka['title'], $grupka['gid']);
    
    
$info2 $db->fetch_array($query2);
        
$miejscowosc $info2['fid1'];
        
$plec $info2['fid3'];
        
$osobie $info2['fid2'];
        
        if(
$miejscowosc == ''$miejscowosc 'Nie określono';
        if(
$plec == ''$plec 'Nie określono';
        if(
$osobie == ''$osobie '<center>Użytkownik nic o sobie nie napisał</center>';

?>

<title>{$mybb->settings['bbname']} - {$lang->profile}</title>
{$headerinclude}
</head>
<body>
{$header}

 <div class="podglad">

<div class="info_podglad">
<div class="calosc_podglad">



<div class="lewa_podglad">
<div class="avatar_podglad">
<img src="{$memprofile['avatar']}" width="138" height="138" alt="" />
</div>
<ul class="tabs">
    <li><a href="#tab1">Przegląd</a></li>
    <li><a href="#tab3">Posty</a></li>
    <li style="border-bottom: none !important;"><a href="#tab4">Tematy</a></li>    
</ul>
</div>


<div class="prawa_podglad">
<div class="tab_container">
<span class="info_top">
<h1 class="nick_usera">{$memprofile['username']}</h1>
        <span class="info_o_userze">
        <ul>
<li>Rejestracja: {$memregdate}</li>
<li>{$online_status}</li>
         </ul>
</span>
</span>
<span style="float: right;margin-right: 10px;margin-top: -38px;">
{$buddy_options}
<a href="private.php?action=send&amp;uid={$memprofile['uid']}" class="button_profile" style="color: #fff;"><img src="images/carbon/pm_profile.png" style="vertical-align: middle;"/> Wyślij wiadomość</a>
<a href="search.php?action=finduser&amp;uid={$memprofile['uid']}" class="button_profile" style="color: #fff;"><img src="images/carbon/zaw_profile.png" style="vertical-align: middle;"> Zawartość</a>
{$warning_level}

</span>

    <div id="tab1" class="tab_content">

<div class="podglad_wrapper">

<div class="lewa_content">

<div class="tabela_podglad">

<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<tr>
<td class="thead_p"><strong>
O mnie
</strong></td>
</tr>
<tr>
<td class="trow_kat5">
{$osobie}
</td>
</tr>
</table>

<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="margin-bottom: 10px;">
<tr>
<td class="thead_p"><strong>
Statystyki
</strong></td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Grupa:</div>
<div class="profil_lewoD">{$grupa}</div>
</td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Całość postów:</div>
<div class="profil_lewoD">{$memprofile['postnum']}</div>
</td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Czas online:</div>
<div class="profil_lewoD">{$timeonline}</div>
</td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Tytuł:</div>
<div class="profil_lewoD">{$usertitle}</div>
</td>
</tr>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Wiek:</div>
<div class="profil_lewoD">{$membdayage}</div>
</td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Urodziny:</div>
<div class="profil_lewoD">{$membday}</div>
</td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Płeć:</div>
<div class="profil_lewoD">{$plec}</div>
</td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Miejscowość:</div>
<div class="profil_lewoD">{$miejscowosc}</div>
</td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Strona:</div>
<div class="profil_lewoD">{$website}</div>
</td>
</tr>
</table>

<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="margin-bottom: 10px;">
<tr>
<td class="thead_p"><strong>
Dodatkowe Informacje
</strong></td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Steam ID:</div>
<div class="profil_lewoD">{$userfields['fid6']}</div>
</td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Nick:</div>
<div class="profil_lewoD">{$userfields['fid7']}</div>
</td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Ulubiony Serwer:</div>
<div class="profil_lewoD">{$userfields['fid4']}</div>
</td>
</tr><tr>
<td class="trow_prof_stat1 ">
<div class="profil_lewo">Ulubiona Broń:</div>
<div class="profil_lewoD">{$userfields['fid5']}</div>
</td>
</tr></td>
</tr>
</table>

{$signature}

    </div>


</div>

<div class="prawa_content">
<?php 
$a 
"{$repinfo}";
$b "0";

if(
$a $b)
      echo 
"<div id='reputacja_pozytywna' class='tipTip' title='{$memprofile['username']} ma {$repinfo} pukntów reputacji'>
<div id='reputacja_liczba'>
{$repinfo}</div>
<div id='reputacja_text'>Pozytywny</div>
</div>"
;
   elseif (
$a == $b)
      echo 
"<div id='reputacja_neutral' class='tipTip' title='{$memprofile['username']} ma {$repinfo} pukntów reputacji'>
<div id='reputacja_liczba'>
{$repinfo}</div>
<div id='reputacja_text'>Neutralny</div>
</div>"
;
   elseif (
$a $b)
      echo 
"<div id='reputacja_negatywna' class='tipTip' title='{$memprofile['username']} ma {$repinfo} pukntów reputacji'>
<div id='reputacja_liczba'>
{$repinfo}</div>
<div id='reputacja_text'>Mniej niż Zero</div>
</div>"
;
?>

<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="margin-bottom: 10px;">
<tr>
<td class="thead_p"><strong>
Znajomi
</strong></td>
</tr>
<tr>
<td class="trow_prof_stat1 ">


<?php
    $query 
$db->query("SELECT * FROM ".TABLE_PREFIX."users WHERE uid='".$memprofile['uid']."'");
    
    while(
$array $db->fetch_array($query))
    {   
        
        
$tablica explode(","$array['buddylist']);
        
$ile count($tablica);
        
        if(
$array['buddylist'] == ''$informacja '<center>Brak znajomych</center>';
        for(
$i=0$i<$ile$i++)
        {   
            
$id $tablica[$i];
            
$query_znajomy $db->query("SELECT * FROM ".TABLE_PREFIX."users WHERE uid='$id'");
            while(
$array_znajomy $db->fetch_array($query_znajomy))
            {   
                
$avatar $array_znajomy['avatar'];
                
$nick $array_znajomy['username'];
                
$id $array_znajomy['uid'];

                          echo 
"<a href='member.php?action=profile&uid={$id}'><img src='{$avatar}' title='{$nick}' class='tipTip userAvatar' width='34' height='34'></a>";
            }
            
        }
        
    }
?>


{$informacja}

</td>
</tr>
</table>



{$last_visit}



</div>

</div>

</div>
<div id="tab2" class="tab_content">
 <div class="tabela_podglad" style="margin-top: 95px;">
    <div>
            <h3>Friends</h3>
            
                Lista przyjaciół
            
        </div>
<br>
        
</div>
    </div>
 <div id="tab3" class="tab_content">
        {$ostatnie_posty}
<center><a href="search.php?action=finduser&amp;uid={$uid}">Kliknij tutaj aby wyszukać posty napisane przez {$formattedname}</a></center>
    </div>
    <div id="tab4" class="tab_content">

        {$ostatnie_tematy}
<center><a href="search.php?action=finduserthreads&amp;uid={$uid}">Kliknij tutaj aby wyszukać tematy napisane przez {$formattedname}</a></center>
    </div>
    <div id="tab5" class="tab_content">
       Reputacja
    </div>
    <div id="tab6" class="tab_content">
       Shoutbox
    </div>
    </div>


</div>
</div>


</div>
</div>



   
{$footer}
</body>
</html> 
Może troche poza tematem ale aż kuje w oczy

$query_znajomy $db->query("SELECT * FROM ".TABLE_PREFIX."users WHERE uid='$id'");
            while(
$array_znajomy $db->fetch_array($query_znajomy))
            {   
                
$avatar $array_znajomy['avatar'];
                
$nick $array_znajomy['username'];
                
$id $array_znajomy['uid']; 

da fuk?
dla trzech kolumny wyciagac wszystko z tabeli ... o nie i to jeszcze haslo usera
Ja bym radzil to troszke zoptymalizowac
są tam co najmniej 4 zbędne zapytania

made by baszar :)

zobacz to
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="margin-bottom: 10px;">
<tr>
<td class="thead_p"><strong>
Znajomi
</strong></td>
</tr>
<tr>
<td class="trow_prof_stat1 ">
{$lastvisitor}
</td>
</tr>
</table>
Taki sam efekt jak w pierwszym poście że ucina tą tabelkę



Użytkownicy przeglądający ten wątek:

1 gości