Temos pavadinimas: WordPress, Shopify ir PHPFusion programuotojų bendruomenė :: Reikia pagalbos, susije su theme

Parašė Langas· 2008 Rugp. 3 20:08:21
#1

nu kuriu theme, ir :
Last seen users panel
<?php
/*---------------------------------------------------+
| PHP-Fusion 6 Content Management System
+----------------------------------------------------+
| Copyright © 2002 - 2005 Nick Jones
| http://www.php-fusion.co.uk/
+----------------------------------------------------+
| Released under the terms & conditions of v2 of the
| GNU General Public License. For details refer to
| the included gpl.txt file or visit http://gnu.org
+----------------------------------------------------*/
if (file_exists(INFUSIONS."last_seen_users_panel/locale/".$settings['locale'].".php")) {
   include INFUSIONS."last_seen_users_panel/locale/".$settings['locale'].".php";
} else {
   include INFUSIONS."last_seen_users_panel/locale/English.php";
}

openside($locale['lsup000']);
$result = dbquery("SELECT * FROM ".$db_prefix."users WHERE user_lastvisit>'0' AND user_status='0' ORDER BY user_lastvisit DESC LIMIT 0,10");
echo "<table cellpadding='0' cellspacing='0' width='100%'>";
if (dbrows($result) != 0) {
   while ($data = dbarray($result)) {
      $lastseen = time() - $data['user_lastvisit'];
      $iW=sprintf("%2d",floor($lastseen/604800));
      $iD=sprintf("%2d",floor($lastseen/(60*60*24)));
      $iH=sprintf("%02d",floor((($lastseen%604800)%86400)/3600));
      $iM=sprintf("%02d",floor(((($lastseen%604800)%86400)%3600)/60));
      $iS=sprintf("%02d",floor((((($lastseen%604800)%86400)%3600)%60)));
      if ($lastseen < 60){
         $lastseen= $locale['lsup001'];
      } elseif ($lastseen < 360){
         $lastseen= $locale['lsup002'];
      } elseif ($iW > 0){
         if ($iW == 1) { $text = $locale['lsup003']; } else { $text = $locale['lsup004']; }
         $lastseen = $iW." ".$text;
      } elseif ($iD > 0){
         if ($iD == 1) { $text = $locale['lsup005']; } else { $text = $locale['lsup006']; }
         $lastseen = $iD." ".$text;
      } else {
         $lastseen = $iH.":".$iM.":".$iS;
      }
      echo "<tr>\n<td class='side-small' align='left'><img src='".THEME."images/bullet.gif' alt=''>\n";
      echo "<a href='".BASEDIR."profile.php?lookup=".$data['user_id']."' title='".$data['user_name']."' class='side'>\n";
      echo trimlink($data['user_name'], 15)."</a></td><td class='side-small' align='right'>".$lastseen."</td>\n</tr>\n";
   }
}
echo "</table>";
closeside();
?>




kaip sita turini ideti ant headerije esancio vieno table ? istraukite koda kuri deti, buciau dekingas :)

ir del user info paneles "user avarat" kodo
if ($userdata['user_avatar'] != "") {
echo "<center><img border='0' src='".BASEDIR."images/avatars/".$userdata['user_avatar']."'></center>\n";
} else {
echo "<center><img border='0' src='".THEME."images/noav.gif'></center>\n";
}



su juo man neina rodo tik ta noav.gif paveiksliuka kai ir bunu uzsidejas avarata, o kai i pridetinius puslapus idedu ta koda su <?php ?> eina, bet ant headerio su tais <?php ?> neina :/ padekite
Nedarykite off-topic, jei nesistengiate padeti nerasykite cia :)

Redagavo Langas· 2008 Rugp. 3 20:08:03

Parašė MAnjack· 2008 Rugp. 3 20:08:16
#2

Pirmu atvėju, tai includink panelę ir viskas, o antru, tai man atrodo atsakymų forume buvo.

Parašė Langas· 2008 Rugp. 3 20:08:04
#3

man reikia kad istrauktu koda, includinti neapsiemu, o del avarato varau ieskoti :)

Parašė MAnjack· 2008 Rugp. 3 20:08:48
#4

include irgi gerai ;)

Parašė Langas· 2008 Rugp. 3 20:08:40
#5

Kitaip sakant nesugebu :D galetum surasyti instrukcija kaip tai padaryti ? :)

Parašė MAnjack· 2008 Rugp. 3 20:08:36
#6

include_once INFUSIONS."last_seen_users_panel/last_seen_users_panel.php";

Parašė Langas· 2008 Rugp. 3 20:08:16
#7

O susitvarkiau, nuemes openside ir closeside :) dekui uz sita pagalba, bet dar reikia pagalbos su avaratais, forume nerandu

Redagavo Langas· 2008 Rugp. 3 20:08:44

Parašė Langas· 2008 Rugp. 3 22:08:52
#8

padekite

Parašė MAnjack· 2008 Rugp. 3 22:08:00
#9

Daabr tingiu. Rytoj parašysiu.

Parašė Langas· 2008 Rugp. 3 22:08:54
#10

jeigu nerspesiu susitvarkyti :)