
|
|
PHP-Quelltext |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
<div class="container-2" style="min-height: 22px; padding:6px">
<div class="containerIcon">
<img src="{icon}groupM.png{/icon}" alt="" />
</div>
<div class="containerContent">
{if WIO_OPEN_POPUP}
<h3><a href="javascript:;" onclick="window.open('index.php?page=Wio{@SID_ARG_2ND}','WerIstOnline','width=800,height=450,toolbar=no,scrollbars=yes,left=50,top=50,resizable=yes');return false;"> {lang}wcf.wio.title{/lang}</a></h3>
{else}
<h3><a href="index.php?page=wio{@SID_ARG_2ND}">{lang}wcf.wio.title{/lang}</a></h3>
{/if}
{if $users || $guestCount}
<div>
<p class="smallFont">{if $guestCount}{$guestCount} {if $guestCount == 1}{lang}wcf.wio.guest{/lang}{else}{lang}wcf.wio.guests{/lang}{/if}{/if}{if $guestCount && $users|count} {lang}wcf.wio.and{/lang} {/if}{if $guestCount && !$users|count} {lang}wcf.wio.online{/lang}{/if}{if $users|count}{$users|count} {if $users|count == 1}{lang}wcf.wio.member{/lang}{else}{lang}wcf.wio.members{/lang}{/if}{/if}</p>
{if $users}
<p class="smallFont">{implode from=$users item=user}
<a {if $user.rankID == 1} class = "Vorstand" {elseif $user.rankID == 11} class="Forentechniker" {elseif $user.rankID == 10} class="Marketing"{elseif $user.rankID == 12} class="Finanzen und Verwaltung" {elseif $user.rankID == 13} class="Produktion"{/if} href="index.php?page=User&userID={@$user.userID}{@SID_ARG_2ND}">{@$user.username}</a>{/implode}</p>
{/if}
</div>
{else}
<div>
<p class="smallFont">{lang}wcf.wio.nobodyOnline{/lang}</p>
</div>
{/if}
<p class="smallFont">{lang}Legende{/lang}: <font color="red">{lang}Vorstand{/lang}</font>, <font color="orange">{lang}Forentechniker{/lang}</font>, <font color="darkblue">{lang}Marketing{/lang}</font>, <font color="green">{lang}Finanzen und Verwaltung{/lang}</font>, <font color="yellow">{lang}Produktion{/lang}</font> </p>
</div>
</div>
|
|
|
PHP-Quelltext |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 |
<?php
//wcf imports
require_once(WCF_DIR.'lib/data/user/User.class.php');
/**
* WhoIsOnline
*
* @package de.wcom.wbblite.wio
* @author Martin Schwendowius
* @copyright 2010 wbb3addons.de
* @license Creative Commons Attribution-NoDerivs 3.0 Unported License <http://creativecommons.org/licenses/by-nd/3.0/>
*/
abstract class WhoIsOnline {
public $sqlSelects = 'user.rankID,';
public $sqlJoins = '';
public $sqlOrderBy = 'session.username';
public $guestCount;
/**
* gets wio data
*
* @return void
*/
public function getWiO() {
$sql = "SELECT".$this->sqlSelects."
user_option.userOption".User::getUserOptionID('invisible').", session.userID, session.ipAddress,
session.userAgent, session.lastActivityTime, user.username
FROM wcf".WCF_N."_session session
LEFT JOIN wcf".WCF_N."_user user
ON (user.userID = session.userID)
LEFT JOIN wcf".WCF_N."_user_option_value user_option
ON (user_option.userID = session.userID)
".$this->sqlJoins."
WHERE session.lastActivityTime > ".(TIME_NOW - USER_ONLINE_TIMEOUT)."
ORDER BY ".$this->sqlOrderBy;
$result = WCF::getDB()->sendQuery($sql);
$this->guestCount = 0;
while ($row = WCF::getDB()->fetchArray($result)) {
$this->handleRow($row, new User(null, $row));
}
}
/**
* returns the visibility status
*
* @param mixed $row
* @param mixed $user
* @return visibility status
*/
protected function isVisible($row, User $user) {
return (WCF::getUser()->userID == $user->userID || !$user->invisible || WCF::getUser()->getPermission('admin.general.canViewInvisible'));
}
/**
* returns the username
*
* @param mixed $row
* @param mixed $user
* @return username
*/
public static function getUsername($row, User $user) {
$row['username'] = StringUtil::encodeHTML($row['username']);
if ($user->invisible) {
$row['username'] .= WCF::getLanguage()->get('wcf.wio.invisible');
}
return $row['username'];
}
}
?>
|
|
|
PHP-Quelltext |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 |
a:link.Vorstand{
color: FF0000;
}
a:visited.Vorstand{
color: FF0000;
}
a:hover.Vorstand{
color: FF0000;
}
a:link.Forentechniker{
color: FFA500;
}
a:visited.Forentechniker{
color: FFA500;
}
a:hover.Forentechniker{
color: FFA500;
}
a:link.Marketing{
color: 00008B;
}
a:visited.Marketing{
color: 00008B;
}
a:hover.Marketing{
color: 00008B;
}
a:link.Finanzen und Verwaltung{
color: 008000;
}
a:visited.Finanzen und Verwaltung{
color: 008000;
}
a:hover.Finanzen und Verwaltung{
color: 008000;
}
a:link.Produktion{
color: FFFF00;
}
a:visited.Produktion{
color: FFFF00;
}
a:hover.Produktion{
color: FFFF00;
}
|



Dieser Beitrag wurde bereits 2 mal editiert, zuletzt von »Gandalf« (26. Januar 2012, 20:31)
.
.|
|
PHP-Quelltext |
1 2 3 4 5 |
a:Vorstand {color: #FF0000;}
a:Forentechniker {color: #FFA500;}
a:Marketing {color: #00008B;}
a:Finanz {color: #008000;}
a:Produktion {color: #FFFF00;}
|
|
|
PHP-Quelltext |
1 2 3 4 5 |
a.Vorstand {color: #FF0000;}
a.Forentechniker {color: #FFA500;}
a.Marketing {color: #00008B;}
a.Finanz {color: #008000;}
a.Produktion {color: #FFFF00;}
|
Benutzerinformationen überspringen
Wohnort: Hannover-/Wedemark
Beruf: Auszubildener - Bürokaufmann
Forenversion: WBBLite 2.1.x
Zu jeder "Kategorie" ---> z.B. Vorstand musst du mehrere CSS-Deklarationen haben, oder nicht?a.Vorstand:link, a.Vorstand:hover, a.Vorstand:active {color: red;}
Danke!Bei deinen CSS-Deklarationen fehlt doch noch ein Teil, oder nicht?
keine besonderen farben willst kannst du die pseudoklassen einfach weglassen, also a.Vorstand {…}
|
|
PHP-Quelltext |
1 2 3 4 5 |
a.Vorstand:link, a.Vorstand:hover, a.Vorstand:active {color: red;}
a.Forentechniker:link, a.Forentechniker:hover, a.Forentechniker:active {color: orange;}
a.Marketing:link, a.Marketing:hover, a.Marketing:active {color: blue;}
a.Finanz:link, a.Finanz:hover, a.Finanz:active {color: green;}
a.Produktion:link, a.Produktion:hover, a.Produktion:active {color: yellow;}
|

|
|
PHP-Quelltext |
1 2 3 4 5 6 7 8 9 |
.copyright {
background-image: url(../images/Christmas.time/Christmas.time-copyright.png);
border: 1px solid #000002;
}
a.Vorstand:link, a.Vorstand:hover, a.Vorstand:active {color: red;}
a.Forentechniker:link, a.Forentechniker:hover, a.Forentechniker:active {color: orange;}
a.Marketing:link, a.Marketing:hover, a.Marketing:active {color: blue;}
a.Finanz:link, a.Finanz:hover, a.Finanz:active {color: green;}
a.Produktion:link, a.Produktion:hover, a.Produktion:active {color: yellow;}
|

|
|
Cascading Style Sheet |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 |
a:link.admin { color:red; } a:visited.admin { color:red; } a:hover.admin { color:red; } .admin { color:red; } a:link.mod { color: 09f; } a:visited.mod { color: #09f; } a:hover.mod { color: #09f; } .mod { color: #09f; } a:link.Wrestling-Designs.Designer { color: #0f0; } a:visited.Wrestling-Designs.Designer { color: #0f0; } a:hover.Wrestling-Designs.Designer { color: #0f0; } .Wrestling-Designs.Designer { color: #90f; } a:link.Wrestling-Designs.Cutter { color: #90f; } a:visited.Wrestling-Designs.Cutter { color: #90f; } a:hover.Wrestling-Designs.Cutter { color: #90f; } .Wrestling-Designs.Cutter { color: #90f; } a:link.Wrestling-Designs.Schueler { color: #ff0; } a:visited.Wrestling-Designs.Schueler { color: #ff0; } a:hover.Wrestling-Designs.Schueler { color: #ff0; } .Wrestling-Designs.Schueler { color: #ff0; } |