suport Posted December 3, 2010 Report Share Posted December 3, 2010 public function list_online_members(){ $r = ''; foreach($this->data->members as $member){ $group = $this->cache->groups[$member->group_id]; $r.= sprintf( [u] '<td class="%s">%s<td class="member_name"><a href="%s?showuser=%d">%s%s%s</a>%s%s%s</td></td>',[/u] preg_replace("/[^a-z0-9\-_]/", "", strtolower($group->g_title)), $this->cfg->avatar == true ? $this->format_avatar($member->id) : '', self::$url, $member->id, $this->cfg->group == true ? $group->prefix : '', $member->name, $this->cfg->group == true ? $group->suffix : '', $this->cfg->group == true ? '<br />'.$group->prefix.$group->g_title.$group->suffix : '', $this->cfg->last_click == true ? '<br />'.$this->format_time($member->time) : '', $this->cfg->location == true ? '<br />'.$this->format_location($member->location) : '' ); } $r.= '</ul>'; return $r; pasvitrotaja vieta cik es saprotu , katram lietotajam piescir savu classs , piemeram root admin ir class=rootadmin , member class=memeber , vismaz source skatoties ta ir . Ka to varetu nonemt , esmu meginajis bet nesanaak ! Quote Link to comment Share on other sites More sharing options...
xPtv45z Posted December 3, 2010 Report Share Posted December 3, 2010 Ko tu mēģināji? Visu preg_replace ar null aizstāt mēģināji? Quote Link to comment Share on other sites More sharing options...
suport Posted December 3, 2010 Author Report Share Posted December 3, 2010 esmu iesaacejs , varetu kka konkretak vai kadu piemeru ! Quote Link to comment Share on other sites More sharing options...
xPtv45z Posted December 5, 2010 Report Share Posted December 5, 2010 Arī priekš iesācēja mazliet par traku jautājums. Ko vēl konkrētāk? preg_replace funkcija tev atgriež grupas nosaukumu, aizstāj to funkciju ar to ko tu gribi, lai ievieto to grupu nosaukumu vietā. Ja negribi neko, tad null vai arī ''. Quote Link to comment Share on other sites More sharing options...
marcis Posted December 5, 2010 Report Share Posted December 5, 2010 Nesapratu kā tev tās klases traucē? Quote Link to comment Share on other sites More sharing options...
mefisto Posted December 5, 2010 Report Share Posted December 5, 2010 Nāksies vien apgūt kā sprintf() darbojas. Īpaši tā '<td class="%s">' daļa. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.