07-27-2022, 10:59 AM
0
Captura GIF
En c.posts.php --> inc --> class --> c.posts.php
Buscar:
Reemplazar por:
Buscar:
Debajo agregar:
Buscar:
Reemplazar por:
En posts.php --> php --> class --> posts.php
Buscar:
Debajo agregar:
Buscar:
Reemplazar por:
En head_submenu.tpl --> themes --> default --> templates --> sections --> head_submenu.tpl
Buscar:
Reemplazar por:
En m.home_last_posts --> themes --> default --> templates --> modules --> m.home_last_posts
Buscar:
Debajo agregar:
Creditos: Debes agradecer para ver el contenido...
[img]Registrate o inicia tu sesión para ver este contenido[/img]
En c.posts.php --> inc --> class --> c.posts.php
Buscar:
Código PHP: ( Seleccionar Todo )
function getLastPosts($category = NULL, $subcateg = NULL, $sticky = false)
Reemplazar por:
Código PHP: ( Seleccionar Todo )
function getLastPosts($category = NULL, $subcateg = NULL, $sticky = false, $a = false)
Buscar:
Código PHP: ( Seleccionar Todo )
$posts['total'] = $q1[0];
//
$start = $tsCore->setPageLimit($tsCore->settings['c_max_posts'],false,$posts['total']);
$lastPosts['pages'] = $tsCore->getPages($posts['total'], $tsCore->settings['c_max_posts']);
}
Debajo agregar:
Código PHP: ( Seleccionar Todo )
if($a)
$s_order = 'p.post_title';
Buscar:
Código PHP: ( Seleccionar Todo )
GROUP BY p.post_id ORDER BY '.$s_order.' DESC
Reemplazar por:
Código PHP: ( Seleccionar Todo )
GROUP BY p.post_id ORDER BY '.$s_order.' '.(empty($a) ? "DESC" : "ASC").'
En posts.php --> php --> class --> posts.php
Buscar:
Código PHP: ( Seleccionar Todo )
$category = $_GET['cat'];
Debajo agregar:
Código PHP: ( Seleccionar Todo )
$a = (int)$_GET['a'];
Buscar:
Código PHP: ( Seleccionar Todo )
$tsLastPosts = $tsPosts->getLastPosts($category, $subcateg);
Reemplazar por:
Código PHP: ( Seleccionar Todo )
$tsLastPosts = $tsPosts->getLastPosts($category, $subcateg, false, $a);
$smarty->assign("tsAlf", $a);
En head_submenu.tpl --> themes --> default --> templates --> sections --> head_submenu.tpl
Buscar:
Código PHP: ( Seleccionar Todo )
<li{if $tsPage == 'home' || $tsPage == 'portal'} class="here"{/if}><a class=vctip title="Inicio" href="{$tsConfig.url}/{if $tsPage == 'home' || $tsPage == 'posts'}posts/{/if}">Inicio</a></li>
<li{if $tsPage == 'buscador'} class="here"{/if}><a class=vctip title="Buscador" href="{$tsConfig.url}/buscador/">Buscador</a></li>
Reemplazar por:
Código PHP: ( Seleccionar Todo )
<li{if ($tsPage == 'home' || $tsPage == 'portal') && $tsAlf == 0} class="here"{/if}><a class=vctip title="Inicio" href="{$tsConfig.url}/{if $tsPage == 'home' || $tsPage == 'posts'}posts/{/if}">Inicio</a></li>
<li{if $tsPage == 'buscador'} class="here"{/if}><a class=vctip title="Buscador" href="{$tsConfig.url}/buscador/">Buscador</a></li>
<li{if $tsAlf == 1} class="here"{/if}><a class=vctip title="Ordenar alfabéticamente" href="{$tsConfig.url}/posts/?a=1">Ordenar alfabéticamente</a></li>
En m.home_last_posts --> themes --> default --> templates --> modules --> m.home_last_posts
Buscar:
Código PHP: ( Seleccionar Todo )
{if $tsPosts}
{foreach from=$tsPosts item=p}
<li class="categoriaPost" style="{if $p.post_status == 3} background-color:#f1f1f1; {elseif $p.post_status == 1}background-color:coral;{elseif $p.post_status == 2} background-color:rosyBrown;{elseif $p.user_activo == 0} background-color:burlyWood;{elseif $p.user_baneado == 1} background-color:orange;{/if}" ><img src="{$tsConfig.tema.t_url}/images/icons/cat/{$p.c_img}" title="{$p.c_nombre}" alt="{$p.c_nombre}" style="width: 26px; height:32px; float: left;">
<a {if $p.post_status == 3}class="qtip" title="El post está en revisión"{elseif $p.post_status == 1}class="qtip" title="El post se encuentra en revisión por acumulación de denuncias"{elseif $p.post_status == 2}class="qtip" title="El post está eliminado"{elseif $p.user_activo == 0}class="qtip" title="La cuenta del usuario está desactivada"{elseif $p.user_baneado == 1}class="qtip" title="La cuenta del usuario está suspendida"{/if} class="title {if $p.post_private}categoria privado{/if}" alt="{$p.post_title}" title="{$p.post_title}" target="_self" href="{$tsConfig.url}/posts/{$p.c_seo}/{$p.post_id}/{$p.post_title|seo}.html"><h1 style="font-size: 14px;font-weight: bold; margin-top: 0px;">{$p.post_title|truncate:50}</h1></a>
Debajo agregar:
Código PHP: ( Seleccionar Todo )
{if $tsAlf}
{php}
$l = strtoupper(substr($this->get_template_vars("p")['post_title'], 0, 1));
$this->assign('letra', $l);
{/php}
<span class="floatR" style="margin-top:-17px"><font color="#005CA5">{$letra}</font></span>
{/if}
Creditos: Debes agradecer para ver el contenido...


Facebook
Twitter
Reddit
Digg
del.icio.us
Tumblr
Pinterest
Blogger
Fark
LinkedIn
Mix
Google