Brak legendy grup

Inne  Założony przez  Avithor.

wersja skryptu MyBB: 1.8
adres forum: aktualnie brak
na czym polega problem (screen, opis, komunikaty, nazwa stylu/theme/szablonu):

Niestety nie posiadam legendy na swoim forum admina, moda itd. Jak to zrobic?
Brak adresu forum ...

Wpisz w google mybb legenda grup

Wysłane z mojego LG-P700 przy użyciu Tapatalka
Niekompatybilny z 1.8
Jej, wpisz doboe w gpogleco zrobić w takiej sytuacji... Wystarczy zmienić 16 na 18 w linijce compatybility - plik pluginu.
Prośby na PW dotyczące wsparcia z problemami będą ignorowane. Pomoc poza forum - odpłatna; kontakt: snakemybboard@gmail.com.
<?php
/**
 *    Copyright © 2006-2008 CraKteR, crakter [at] gmail [dot] com
 *
 *    This program is free software: you can redistribute it and/or modify
 *    it under the terms of the GNU General Public License as published by
 *    the Free Software Foundation, either version 3 of the License, or
 *    (at your option) any later version.
 *
 *    This program is distributed in the hope that it will be useful,
 *    but WITHOUT ANY WARRANTY; without even the implied warranty of
 *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *    GNU General Public License for more details.
 *
 *    You should have received a copy of the GNU General Public License
 *    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 *    @version $Id: usergrouplegends.php 35 2008-08-14 19:14:12Z CraKteR $
 *    @copyright $LastChangedDate: 2008-08-14 21:14:12 +0200 (to, 14 aug 2008) $
 *    @author CraKteR <crakter@gmail.com>
 */

if(!defined("IN_MYBB"))
{
    die(
"This file cannot be accessed directly.");
}

$plugins->add_hook("index_start""do_legend");

function 
usergrouplegends_info()
{
    return array(
        
"name"                => "Usergroup legends",
        
"description"        => "Shows Usergroups legends on the index.",
        
"website"            => "",
        
"author"            => "CraKteR",
        
"authorsite"        => "mailto:crakter@gmail.com",
        
"version"            => "2.0",
        
"guid"                => "d912aad6bc509657d0691d31ae8038a6",
        
"compatibility"     => "14*",
    );
}

function 
usergrouplegends_activate()
{
    global 
$db;

    
$setting_group = array(
        
"gid" =>            NULL,
        
"name" =>            "uot",
        
"title" =>            "User group legends",
        
"description" =>    "",
        
"disporder" =>        "35",
        
"isdefault" =>        "no"
    
);
    
$db->insert_query("settinggroups"$setting_group);
    
$gid $db->insert_id();

    
$s_1 = array(
        
"sid"            => NULL,
        
"name"            => "legendsdontshow",
        
"title"            => "Groups to not show",
        
"description"    => "Groups not to be shown on usersgroup legends. Seperate with \',\'.",
        
"optionscode"    => "text",
        
"value"            => "",
        
"disporder"        => "2",
        
"gid"            => intval($gid)
    );
    
$db->insert_query("settings"$s_1);

    
$template = array(
        
"tid"        => NULL,
        
"title"        => "usergroup_legend",
        
"template"    => "<tr><td class=\"tcat\"><strong>Group Legend</strong></td></tr>
<tr><td class=\"trow1\">{\$usertitles}</td></tr>"
,
        
"sid"        => "-1"
    
);
    
$db->insert_query("templates"$template);
    
    require 
MYBB_ROOT."/inc/adminfunctions_templates.php";
    
find_replace_templatesets("index_boardstats"'#{\$whosonline}#'"{\$whosonline}\n{\$user_legend}");
}

function 
usergrouplegends_deactivate()
{
    global 
$db;

    
$db->query("DELETE FROM ".TABLE_PREFIX."templates WHERE title='usergroup_legend'");
    
$db->query("DELETE FROM ".TABLE_PREFIX."settinggroups WHERE name='uot'");
    
$db->query("DELETE FROM ".TABLE_PREFIX."settings WHERE name='legendsdontshow'");

    require 
MYBB_ROOT."/inc/adminfunctions_templates.php";
    
find_replace_templatesets("index_boardstats"'#(\n?){\$user_legend}#'''0);
}

function 
do_legend()
{
    global 
$db$mybb$user_legend$templates$groupscache$cache$theme;

    if(!
is_array($groupscache))
    {
        
$groupscache $cache->read("usergroups");
    }

    
$usertitles "";
    
$dontshow explode(','$mybb->settings['legendsdontshow']);

    foreach(
$groupscache as $usertitle)
    {
        if(!
in_array($usertitle['gid'], $dontshow))
        {
            
$format $usertitle['namestyle'];
            
$userin substr_count($format"{username}");
            if(
$userin == 0)
            {
                
$format "{username}";
            }

            
$format stripslashes($format);
            
$plugincache $cache->read("plugins");
            
$usergroup str_replace("{username}"$usertitle['title'], $format);

            if(
$plugincache['active']['showgroup'])
            {
                
$usergroup "<a href=\"./groups.php?gid=".$usertitle['gid']."\">".$usergroup."</a>";
            }

            
$usertitles .= "[".$usergroup."] ";
        }
    }
    eval(
"\$user_legend = \"".$templates->get("usergroup_legend")."\";"); 
}
?>
https://webboard.pl/thread-24209.html?pi...4#pid94424

W Twoim przypadku będzie to z 14 na 18 -.-'
Używaj szukajki wbudowanej w forum - po to ona jest i Google, zazwyczaj wystarczy.
Wgraj to...
http://community.mybb.com/mods.php?action=view&pid=10
Prośby na PW dotyczące wsparcia z problemami będą ignorowane. Pomoc poza forum - odpłatna; kontakt: snakemybboard@gmail.com.



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

1 gości