Thread Prefix on Forum Index
Esta modificación permite mostrar los Prefix en el Index, los prefix creados en ACP de MyBB 1.8.x
Open File: /inc/functions_forumlist.php
Find:
Replace with:
Find:
Replace with:
Ahora, vamos a Modificar el Template, para que nos muestre los cambios.
Template Sets » Default Templates » Edit Template: forumbit_depth2_forum_lastpost
Ponemos estas lineas: {$thread['displayprefix']} Después de: <span class="smalltext"> and salvamos or save the template. el codigo seria algo así:
Referencia:
https://community.mybb.com/thread-77229.html
El Resultado seria como se muestra en el archivo adjunto.
Esta modificación permite mostrar los Prefix en el Index, los prefix creados en ACP de MyBB 1.8.x
Open File: /inc/functions_forumlist.php
Find:
PHP Code:
global $fcache, $moderatorcache, $forumpermissions, $theme, $mybb, $templates, $bgcolor, $collapsed, $lang, $showdepth, $plugins, $parser, $forum_viewers;
Replace with:
PHP Code:
global $db, $fcache, $moderatorcache, $forumpermissions, $theme, $mybb, $templates, $bgcolor, $collapsed, $lang, $showdepth, $plugins, $parser, $forum_viewers;
Find:
PHP Code:
elseif($hideinfo != true)
{
Replace with:
PHP Code:
elseif($hideinfo != true)
{
/************** Show prefix on index ************ */
// @Author: Mattia
// @Web: www.methack.it/forum/
// Get the thread details from the database.
$thread = get_thread($lastpost_data['lastposttid']);
// Get thread prefix if there is one.
$thread['threadprefix'] = '';
$thread['displayprefix'] = '';
if($thread['prefix'] != 0)
{
$query = $db->simple_select('threadprefixes', 'prefix, displaystyle', "pid='{$thread['prefix']}'");
$threadprefix = $db->fetch_array($query);
$thread['threadprefix'] = $threadprefix['prefix'].' ';
$thread['displayprefix'] = $threadprefix['displaystyle'].' ';
}
/************** End show prefix ***************** */
Ahora, vamos a Modificar el Template, para que nos muestre los cambios.
Template Sets » Default Templates » Edit Template: forumbit_depth2_forum_lastpost
Ponemos estas lineas: {$thread['displayprefix']} Después de: <span class="smalltext"> and salvamos or save the template. el codigo seria algo así:
PHP Code:
<span class="smalltext">{$thread['displayprefix']}
<a href="{$lastpost_link}" title="{$full_lastpost_subject}"><strong>{$lastpost_subject}</strong></a>
<br />{$lastpost_date}<br />{$lang->by} {$lastpost_profilelink}</span>
Referencia:
https://community.mybb.com/thread-77229.html
El Resultado seria como se muestra en el archivo adjunto.
