Peticion wtp Pro XXX

seo507

Suspendido
Mensajes
144
Puntuación de reacción
0
Hola, pues si, alguien tiene wtp Pro XXX?
Me ayudarian con otra plantilla que funcione con wordpress.
 

yuliet

Cobre
Usuario de Bronce
Mensajes
397
Puntuación de reacción
0
Depende mucho del theme, pero en general, añade estas funciones al archivo functions de tu tema

function tube_getcustomfield($filedname, $page_current_id = NULL)
{

if($page_current_id==NULL)
$page_current_id = get_page_id();

$value = get_post_meta($page_current_id, $filedname, true);
return $value;
}

function tube_get_limited_string($output, $max_char)
{
$output = str_replace(']]>', ']]>', $output);
$output = strip_tags($output);

if ((strlen($output)>$max_char) && ($espacio = strpos($output, " ", $max_char )))
{
$output = substr($output, 0, $espacio).'...';
return $output;
}
else
{
return $output;
}
}

Luego cambia la llamada al thumb de tu tema activo por esto otro

<a href="<?php the_permalink() ?>" title="<?php the_title_attribute(); ?>">
<?php $thumb = tube_getcustomfield('wtp_thumb_url',get_the_ID()); if(!empty($thumb)) { ?>
<img src="<?php echo $thumb; ?>" alt="<?php the_title_attribute(); ?>" width="300" height="170" class="thumb"/> <?php } else { ?>
<img src="<?php bloginfo('template_url') ?>/images/IMAGEN-ALTERNATIVA.jpg" width="300" height="170" alt="image" class="thumb"/><?php } ?>
</a>

Adaptas estos datos para la altura y la anchura que quieras: width="300" height="170"

Y listo.
 

seo507

Suspendido
Mensajes
144
Puntuación de reacción
0
Depende mucho del theme, pero en general, añade estas funciones al archivo functions de tu tema



Luego cambia la llamada al thumb de tu tema activo por esto otro



Adaptas estos datos para la altura y la anchura que quieras: width="300" height="170"

Y listo.

Gracias, ya arregle la plantilla que tenia.
 
Arriba