xikixikitusa
Respuestas de foro creadas
-
Foro: Guías – Resolución de problemas
En respuesta a: Feature imageAquí tienes la url http://tubodadepelicula.imaginartee.com/category/blog/
En el archivo single.php está esto
<?php /** * Single Post Template - this is the template for the single blog post. */ get_header(); if ( have_posts() ) { while ( have_posts() ) { the_post(); //get all the page data needed and set it to an object that can be used in other files $pexeto_page=array(); $pexeto_page['sidebar']=pexeto_option( 'post_sidebar' ); $pexeto_page['slider']='none'; $pexeto_page['layout']=pexeto_option( 'post_layout' ); $pexeto_page['show_title'] = true; $pexeto_page['title']=''; //include the before content template locate_template( array( 'includes/html-before-content.php' ), true, true ); //include the post template locate_template( array( 'includes/post-template.php' ), true, false ); //include the comments template comments_template(); } } //include the after content template locate_template( array( 'includes/html-after-content.php' ), true, true ); get_footer(); ?>
Y en el archivo POST TEMPLATE.PHP ESTÁ…
<?php /** * Single blog post template. */ global $pexeto_page; $format = get_post_format(); $add_post_class = is_single() ? 'blog-single-post' : 'blog-non-single-post'; $add_post_class.=' theme-post-entry'; ?> <div id="post-<?php the_ID(); ?>" <?php post_class( $add_post_class ); ?>> <?php if ( $format == 'quote' ) { //QUOTE POST FORMAT ?> <span class="post-type-icon-wrap"><span class="post-type-icon"></span></span> <blockquote><?php the_content(); ?></blockquote> <?php }elseif ( $format == 'aside' ) { //ASIDE POST FORMAT ?> <span class="post-type-icon-wrap"><span class="post-type-icon"></span></span> <aside><?php the_content(); ?></aside> <?php }else { //ALL OTHER POST FORMATS $hide_thumbnail=( isset( $pexeto_page["hide_thumbnail"] )&&$pexeto_page["hide_thumbnail"] )?true:false; $thumb_class=''; if ( (!$format && !has_post_thumbnail()) || $hide_thumbnail ) { $thumb_class=' no-thumbnail'; } ?> <?php //PRINT HEADER OF POST DEPENDING ON ITS FORMAT if(!$format || $format=='video'){ $columns = isset($pexeto_page['columns']) ? $pexeto_page['columns'] : 1; $img_size = pexeto_get_image_size_options($columns, 'blog'); } if ( $format == 'gallery' ) { //PRINT A GALLERY locate_template( array( 'includes/slider-nivo-post-gallery.php' ), true, false ); }elseif ( $format == 'video' ) { ?> <div class="post-video-wrapper"> <div class="post-video"> <?php $video_url = pexeto_get_single_meta( $post->ID, 'video' ); if ( $video_url ) { pexeto_print_video( $video_url, $img_size['width'] ); } ?> </div> </div> <?php }else { //PRINT AN IMAGE if ( has_post_thumbnail() && !$hide_thumbnail ) { ?> <div class="blog-post-img img-loading" style="min-width:<?php echo $img_size['width']; ?>px; min-height:<?php echo $img_size['height'] ?>px;"> <?php if ( !is_single() ) {?><a href="<?php the_permalink(); ?>"><?php } $thumb = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'full' ); ?> <img src="<?php echo pexeto_get_resized_image( $thumb[0], $img_size['width'], $img_size['height'], $img_size['crop'] ); ?>" /> <?php if ( !is_single() ) { ?></a><?php } ?> </div> <?php } } ?> <div class="post-content<?php echo $thumb_class; ?>"> <div class="post-title-wrapper"> <?php $htag = is_single()?'h1':'h2'; ?> <<?php echo $htag; ?> class="post-title entry-title"> <?php if ( !is_single() ) { ?> <a href="<?php the_permalink(); ?>"><?php the_title(); ?></a> <?php }else { the_title(); } ?> </<?php echo $htag; ?>> </div> <div class="clear"></div> <div class="post-content-content"> <?php //PRINT THE CONTENT $excerpt=( isset( $pexeto_page['excerpt'] ) && $pexeto_page['excerpt'] ) ? true : false; if ( !$excerpt && pexeto_option( 'post_summary' )!='excerpt' || is_single() ) { ?><div class="entry-content"><?php the_content( '' ); ?> </div> <div class="clear"></div> <?php if ( !is_single() ) { $ismore = @strpos( $post->post_content, '<!--more-->' ); if ( $ismore ) {?> <a href="<?php the_permalink(); ?>" class="read-more"><?php _e( 'Ver más', 'pexeto' ); ?><span class="more-arrow">›</span></a> <?php } } else { wp_link_pages(); } }else { ?><div class="entry-summary"><?php the_excerpt(); ?> </div> <a href="<?php the_permalink(); ?>" class="read-more"> <?php _e( 'Read More', 'pexeto' ); ?> <span class="more-arrow">›</span> </a> <?php }?> <div class="clear"></div> </div> </div> <?php //PRINT POST INFO $hide_sections=pexeto_option( 'exclude_post_sections' ); if ( sizeof( $hide_sections )!=4 ) { ?> <div class="post-info"> <span class="post-type-icon-wrap"><span class="post-type-icon"></span></span> <?php //PRINT THE POST INFO (CATEGORY, AUTHOR, DATE AND COMMENTS) if ( !in_array( 'category', $hide_sections ) && get_the_category( $post->ID ) ) {?> <span class="no-caps"> <?php _e( 'in', 'pexeto' ); ?> </span><?php the_category( ' / ' );?> <?php } if ( !in_array( 'author', $hide_sections ) ) {?> <span class="no-caps post-autor vcard author"> <?php _e( 'by', 'pexeto' ); ?> <a class="url fn n" href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ); ?>"> <?php the_author(); ?> </a> </span> <?php } if ( !in_array( 'date', $hide_sections ) ) { ?> <span class="post-date"> <?php echo pexeto_get_post_date_html(); ?> </span> <?php } if ( !in_array( 'comments', $hide_sections ) ) {?> <span class="comments-number"> <a href="<?php the_permalink();?>#comments"> <?php comments_number( '0', '1', '%' ); ?> <span class="no-caps"><?php _e( 'comments', 'pexeto' ); ?></span></a> </span> <?php } ?> </div> <?php //PRINT SHARING if ( is_single() ) { echo pexeto_get_share_btns_html( $post->ID, 'post' ); } // PRINT POST TAGS if ( is_single() ) { the_tags( '<span class="post-tags"><span class="post-tag-title">'.__( 'Post tags', 'pexeto' ).'</span>', '', '</span>' ); } ?> <?php } //end if } ?> <div class="clear"></div> </div>
Foro: Guías – Resolución de problemas
En respuesta a: Feature imageNo, no hay nada modificado.
En la demo supongo que será igual sólo que no se nota el problema, ya que habrán puesto la miniatura (imagen destacada) y es ésta la que aparece automáticamente en el blog de la demo.
El problema viene cuando yo no quiero que aparezca la imagen que he seleccionado como imagen destacada y automáticamente se pone en el post.
En ningún sitio está la opción para poder cambiarlo o modificarlo. Supongo que habrá que hacerlo desde el código. Y ahí está el problema.
Foro: Guías – Resolución de problemas
En respuesta a: Feature imageSí, compré la licencia, pero actualmente no puedo acceder a preguntar al desarrollador porque no tengo permisos porque tendría que renovar la licencia. Por eso pregunto por aquí, seguro que alquien me puede echar un cable…
El problema está en que quiero ocultar que se ponga automáticamente la imagen destacada del post en el mismo post. Para que salga la miniatura en los post relacionados tengo que adjuntar imagen destacada y claro, se pone también automáticamente dentro del post. Seguramente no será nada difícil pero no encuentro qué línea es…
- Esta respuesta fue modificada hace 5 años, 5 meses por xikixikitusa.
- Esta respuesta fue modificada hace 5 años, 5 meses por xikixikitusa.
Foro: Guías – Resolución de problemas
En respuesta a: Feature imageOk, gracias @almendron
El tema es MINERAL THEME.
Adjunto el código:
<?php /** * Single blog post template. */ global $pexeto_page; $format = get_post_format(); $add_post_class = is_single() ? 'blog-single-post' : 'blog-non-single-post'; $add_post_class.=' theme-post-entry'; ?> <div id="post-<?php the_ID(); ?>" <?php post_class( $add_post_class ); ?>> <?php if ( $format == 'quote' ) { //QUOTE POST FORMAT ?> <span class="post-type-icon-wrap"><span class="post-type-icon"></span></span> <blockquote><?php the_content(); ?></blockquote> <?php }elseif ( $format == 'aside' ) { //ASIDE POST FORMAT ?> <span class="post-type-icon-wrap"><span class="post-type-icon"></span></span> <aside><?php the_content(); ?></aside> <?php }else { //ALL OTHER POST FORMATS $hide_thumbnail=( isset( $pexeto_page["hide_thumbnail"] )&&$pexeto_page["hide_thumbnail"] )?true:false; $thumb_class=''; if ( (!$format && !has_post_thumbnail()) || $hide_thumbnail ) { $thumb_class=' no-thumbnail'; } ?> <?php //PRINT HEADER OF POST DEPENDING ON ITS FORMAT if(!$format || $format=='video'){ $columns = isset($pexeto_page['columns']) ? $pexeto_page['columns'] : 1; $img_size = pexeto_get_image_size_options($columns, 'blog'); } if ( $format == 'gallery' ) { //PRINT A GALLERY locate_template( array( 'includes/slider-nivo-post-gallery.php' ), true, false ); }elseif ( $format == 'video' ) { ?> <div class="post-video-wrapper"> <div class="post-video"> <?php $video_url = pexeto_get_single_meta( $post->ID, 'video' ); if ( $video_url ) { pexeto_print_video( $video_url, $img_size['width'] ); } ?> </div> </div> <?php }else { //PRINT AN IMAGE if ( has_post_thumbnail() && !$hide_thumbnail ) { ?> <div class="blog-post-img img-loading" style="min-width:<?php echo $img_size['width']; ?>px; min-height:<?php echo $img_size['height'] ?>px;"> <?php if ( !is_single() ) {?><a href="<?php the_permalink(); ?>"><?php } $thumb = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'full' ); ?> <img src="<?php echo pexeto_get_resized_image( $thumb[0], $img_size['width'], $img_size['height'], $img_size['crop'] ); ?>" /> <?php if ( !is_single() ) { ?></a><?php } ?> </div> <?php } } ?> <div class="post-content<?php echo $thumb_class; ?>"> <div class="post-title-wrapper"> <?php $htag = is_single()?'h1':'h2'; ?> <<?php echo $htag; ?> class="post-title entry-title"> <?php if ( !is_single() ) { ?> <a href="<?php the_permalink(); ?>"><?php the_title(); ?></a> <?php }else { the_title(); } ?> </<?php echo $htag; ?>> </div> <div class="clear"></div> <div class="post-content-content"> <?php //PRINT THE CONTENT $excerpt=( isset( $pexeto_page['excerpt'] ) && $pexeto_page['excerpt'] ) ? true : false; if ( !$excerpt && pexeto_option( 'post_summary' )!='excerpt' || is_single() ) { ?><div class="entry-content"><?php the_content( '' ); ?> </div> <div class="clear"></div> <?php if ( !is_single() ) { $ismore = @strpos( $post->post_content, '<!--more-->' ); if ( $ismore ) {?> <a href="<?php the_permalink(); ?>" class="read-more"><?php _e( 'Read More', 'pexeto' ); ?><span class="more-arrow">›</span></a> <?php } } else { wp_link_pages(); } }else { ?><div class="entry-summary"><?php the_excerpt(); ?> </div> <a href="<?php the_permalink(); ?>" class="read-more"> <?php _e( 'Read More', 'pexeto' ); ?> <span class="more-arrow">›</span> </a> <?php }?> <div class="clear"></div> </div> </div> <?php //PRINT POST INFO $hide_sections=pexeto_option( 'exclude_post_sections' ); if ( sizeof( $hide_sections )!=4 ) { ?> <div class="post-info"> <span class="post-type-icon-wrap"><span class="post-type-icon"></span></span> <?php //PRINT THE POST INFO (CATEGORY, AUTHOR, DATE AND COMMENTS) if ( !in_array( 'category', $hide_sections ) && get_the_category( $post->ID ) ) {?> <span class="no-caps"> <?php _e( 'in', 'pexeto' ); ?> </span><?php the_category( ' / ' );?> <?php } if ( !in_array( 'author', $hide_sections ) ) {?> <span class="no-caps post-autor vcard author"> <?php _e( 'by', 'pexeto' ); ?> <a class="url fn n" href="<?php echo esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ); ?>"> <?php the_author(); ?> </a> </span> <?php } if ( !in_array( 'date', $hide_sections ) ) { ?> <span class="post-date"> <?php echo pexeto_get_post_date_html(); ?> </span> <?php } if ( !in_array( 'comments', $hide_sections ) ) {?> <span class="comments-number"> <a href="<?php the_permalink();?>#comments"> <?php comments_number( '0', '1', '%' ); ?> <span class="no-caps"><?php _e( 'comments', 'pexeto' ); ?></span></a> </span> <?php } ?> </div> <?php //PRINT SHARING if ( is_single() ) { echo pexeto_get_share_btns_html( $post->ID, 'post' ); } // PRINT POST TAGS if ( is_single() ) { the_tags( '<span class="post-tags"><span class="post-tag-title">'.__( 'Post tags', 'pexeto' ).'</span>', '', '</span>' ); } ?> <?php } //end if } ?> <div class="clear"></div> </div>
- Esta respuesta fue modificada hace 5 años, 5 meses por xikixikitusa.
Foro: Guías – Resolución de problemas
En respuesta a: Cómo eliminar la imagen principal del interior del post.Hola!
Me pasa lo mismo. Quiero poner la miniatura pero no quiero que se me duplique en el post la imagen…¿Cómo puedo ocultarla?Lo único que he encontrado es es to en el archivo post-template.php
CÓDIGO:
<?php
/**
* Single blog post template.
*/global $pexeto_page;
$format = get_post_format();
$add_post_class = is_single() ? ‘blog-single-post’ : ‘blog-non-single-post’;
$add_post_class.=’ theme-post-entry’;
?>
<div id=»post-<?php the_ID(); ?>» <?php post_class( $add_post_class ); ?>><?php
if ( $format == ‘quote’ ) {
//QUOTE POST FORMAT
?>
<span class=»post-type-icon-wrap»><span class=»post-type-icon»></span></span><?php the_content(); ?>
<?php
}elseif ( $format == ‘aside’ ) {
//ASIDE POST FORMAT
?>
<span class=»post-type-icon-wrap»><span class=»post-type-icon»></span></span>
<aside><?php the_content(); ?></aside>
<?php
}else {
//ALL OTHER POST FORMATS
$hide_thumbnail=( isset( $pexeto_page[«hide_thumbnail»] )&&$pexeto_page[«hide_thumbnail»] )?true:false;
$thumb_class=»;
if ( (!$format && !has_post_thumbnail()) || $hide_thumbnail ) {
$thumb_class=’ no-thumbnail’;
}
?><?php
//PRINT HEADER OF POST DEPENDING ON ITS FORMATif(!$format || $format==’video’){
$columns = isset($pexeto_page[‘columns’]) ? $pexeto_page[‘columns’] : 1;
$img_size = pexeto_get_image_size_options($columns, ‘blog’);
}if ( $format == ‘gallery’ ) {
//PRINT A GALLERY
locate_template( array( ‘includes/slider-nivo-post-gallery.php’ ), true, false );
}elseif ( $format == ‘video’ ) {
?>
<div class=»post-video-wrapper»>
<div class=»post-video»>
<?php
$video_url = pexeto_get_single_meta( $post->ID, ‘video’ );
if ( $video_url ) {
pexeto_print_video( $video_url, $img_size[‘width’] );
}
?>
</div>
</div>
<?php
}else {
//PRINT AN IMAGE
if ( has_post_thumbnail() && !$hide_thumbnail ) { ?>
<div class=»blog-post-img img-loading» style=»min-width:<?php echo $img_size[‘width’]; ?>px; min-height:<?php echo $img_size[‘height’] ?>px;»>
<?php if ( !is_single() ) {?>«><?php }$thumb = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), ‘full’ ); ?>
» />
<?php
if ( !is_single() ) { ?><?php } ?>
</div>
<?php
}
}
?>
<div class=»post-content<?php echo $thumb_class; ?>»>
<div class=»post-title-wrapper»>
<?php $htag = is_single()?’h1′:’h2′; ?>
<<?php echo $htag; ?> class=»post-title entry-title»>
<?php if ( !is_single() ) { ?>
«><?php the_title(); ?>
<?php }else {
the_title();
} ?>
</<?php echo $htag; ?>></div>
<div class=»clear»></div><div class=»post-content-content»>
<?php
//PRINT THE CONTENT
$excerpt=( isset( $pexeto_page[‘excerpt’] ) && $pexeto_page[‘excerpt’] ) ? true : false;
if ( !$excerpt && pexeto_option( ‘post_summary’ )!=’excerpt’ || is_single() ) {
?><div class=»entry-content»><?php
the_content( » ); ?>
</div>
<div class=»clear»></div>
<?php
if ( !is_single() ) {
$ismore = @strpos( $post->post_content, ‘<!–more–>’ );
if ( $ismore ) {?> » class=»read-more»><?php _e( ‘Ver más’, ‘pexeto’ ); ?><span class=»more-arrow»>›</span>
<?php
}
} else {
wp_link_pages();
}
}else {
?><div class=»entry-summary»><?php
the_excerpt(); ?>
</div>» class=»read-more»>
<?php _e( ‘Read More’, ‘pexeto’ ); ?>
<span class=»more-arrow»>›</span>
<?php
}?>
<div class=»clear»></div>
</div>
</div>
<?php//PRINT POST INFO
$hide_sections=pexeto_option( ‘exclude_post_sections’ );
if ( sizeof( $hide_sections )!=4 ) {
?><div class=»post-info»>
<span class=»post-type-icon-wrap»><span class=»post-type-icon»></span></span>
<?php
//PRINT THE POST INFO (CATEGORY, AUTHOR, DATE AND COMMENTS)
if ( !in_array( ‘category’, $hide_sections ) && get_the_category( $post->ID ) ) {?>
<span class=»no-caps»>
<?php _e( ‘in’, ‘pexeto’ ); ?>
</span><?php the_category( ‘ / ‘ );?>
<?php }if ( !in_array( ‘author’, $hide_sections ) ) {?>
<span class=»no-caps post-autor vcard author»>
<?php _e( ‘by’, ‘pexeto’ ); ?>
«>
<?php the_author(); ?>
</span>
<?php }if ( !in_array( ‘date’, $hide_sections ) ) { ?>
<span class=»post-date»>
<?php echo pexeto_get_post_date_html(); ?>
</span>
<?php }if ( !in_array( ‘comments’, $hide_sections ) ) {?>
<span class=»comments-number»>
#comments»>
<?php comments_number( ‘0’, ‘1’, ‘%’ ); ?>
<span class=»no-caps»><?php _e( ‘comments’, ‘pexeto’ ); ?></span>
</span>
<?php } ?>
</div><?php
//PRINT SHARING
if ( is_single() ) {
echo pexeto_get_share_btns_html( $post->ID, ‘post’ );
}// PRINT POST TAGS
if ( is_single() ) {
the_tags( ‘<span class=»post-tags»><span class=»post-tag-title»>’.__( ‘Post tags’, ‘pexeto’ ).'</span>’, », ‘</span>’ );
} ?><?php } //end if
} ?>
<div class=»clear»></div>
</div>¿Qué tendría que quitar o modificar? ¿Alguien me echa un cable? Gracias!
Foro: Diseño – Temas y plantillas
En respuesta a: Página inicio diferenteOk, gracias. Entiendo más o menos la idea pero… y ¿cómo hago para que de principal sólo se muestre la nueva que he creado?
Porque desde AJUSTES–> APARIENCIA me deja seleccionar o páginas o entradas. En mi caso quiero que se muestre la que yo cree en particular.Saludos!
Foro: Diseño – Temas y plantillas
En respuesta a: Twenty Ten Enlaces permanentesMi web es: http://www.imaginartee.com
Un ejemplo para que veáis lo que pasa en: http://www.imaginartee.com/anuncio-converse/545/