Se solicita Programador para editar leer mas

  • Autor Autor Vladimir Ceballos
  • Fecha de inicio Fecha de inicio
Estado

🔒 Este tema está cerrado para nuevas respuestas.

⏰ Solo el creador del tema puede solicitar la reapertura de sus propios temas, pero únicamente dentro de los 60 días previos a la última actualización.

V

Vladimir Ceballos

Iota
SEO
Retroalimentación: +205 / =0 / -3
Saludos foreros

Necesito un programador que me solucione un problema:

Deseo que al darle clic al leer mas de mi blog, este no haga un salto, sino que empiece nuevamente desde el principio del post.

Pago $ 5 dolares por esa peque;isima modificacion, si les parece muy poco diganme por cuanto haen el trabajo
 
En ves que vaya al #more-1745 que vaya al principio del post?
 
Si osea yo al darle clic a leer articulo completo a uno de los articulos de mi blog, este hace un salto, continuando la lectura desde donde se corto el post con el more.... lo que quiero es que no haga ese salto sino que al darle clic lleve al visitante al principio del post
 
En el archivo archive.php,index.php y search.php busca <?php the_excerpt(__('Read more'));?> y cámbialo por <?php the_content(__('Read more'));?>
 
no sei ya lo solucionaste, por que que no da ningun salto en opera, empieza en el top del post
 
En el archivo archive.php,index.php y search.php busca <?php the_excerpt(__('Read more'));?> y cámbialo por <?php the_content(__('Read more'));?>

No amigo, los codigos que tu me das no estan en mi plantilla... encuentro esto en el index

PHP:
$more_text = get_post_meta($post->ID, "more-text", true);			// If you want to specify your own excerpt and 'more text' then you can do that.
		if ($temp_post['post_excerpt']) {									// This code block gets the excerpt and more text from the custom fields,
			echo '<p>' . $temp_post['post_excerpt'] . '</p><p><a href="'; 	// or does something sensible if you havent specified them.
			the_permalink(); 
			echo '" class="more-link">';
			
			if ($more_text != '') 
				echo get_post_meta($post->ID, "more-text", true) . '</a></p>';
			else 
				echo 'Leer el artículo completo >></a></p>';
		}
		else {
			if ($more_text == '') $more_text = 'Leer el artículo completo >>';
			the_content($more_text); 
		}
		?>
 
No amigo, los codigos que tu me das no estan en mi plantilla... encuentro esto en el index

PHP:
$more_text = get_post_meta($post->ID, "more-text", true);			// If you want to specify your own excerpt and 'more text' then you can do that.
		if ($temp_post['post_excerpt']) {									// This code block gets the excerpt and more text from the custom fields,
			echo '<p>' . $temp_post['post_excerpt'] . '</p><p><a href="'; 	/ or does something sensible if you havent specified them.
			the_permalink(); 
			echo '" class="more-link">';
			
			if ($more_text != '') 
				echo get_post_meta($post->ID, "more-text", true) . '</a></p>';
			else 
				echo 'Leer el artículo completo >></a></p>';
		}
		else {
			if ($more_text == '') $more_text = 'Leer el artículo completo >>';
			the_content($more_text); 
		}
		?>

Podrías pegar el index.php completo?
 
Este es el index.php completo

PHP:
<?php get_header(); ?>

<!--
home.php
~~~~~~~~~~~~~~~~~~~~~~~~ ~~~ -->

<!--
Content of the page (inc comments and post details)
~~~~~~~~~~~~~~~~~~~~~~~~ ~~~ -->
<div id="page-body-wrapper">

	<div id="content">

<!--
The Home Page 'Page Block'
~~~~~~~~~~~~~~~~~~~~~~~~ ~~~ -->
		<?php	
		$thispage = new WP_Query();
		$option = hmt_get_option(hmt_featured); 	// get the featured page option
		$thispage->query('page_id=' . $option);
		
		if (($option!="") && (!is_paged())) { 		// if a featured home page option has been specified  
													// and this is is the first page of posts, then show the featured page
			$thispage->the_post(); ?>
			
<!--
The Home Page 'Page Block' content 
~~~ -->
			
			<div class="featured-page-content">
			
<!--
Widget Area: [All Content] Above 
~~~ -->			
				<?php 
				dynamic_sidebar('[All Content] Above'); 
				$ads_already_shown = TRUE;										// this lets subsequent blog posts know that they are not the first thing on the page
																				// and therefore no ads will be shown around them. Ads only show on the first item on the page.
				echo '<h1 class="h1-underline">'; the_title(); echo '</h1>';	// This is the most important thing on the page for indexing and therefore gets a H1
				dynamic_sidebar('[Content Item] Above');
				dynamic_sidebar('[Content Item] Left'); 
				dynamic_sidebar('[Content Item] Right');
				
				if (function_exists('has_post_thumbnail')) {				
					if (has_post_thumbnail()) { //  new for 10/03/2010 - okay so if this post has a thumbnail (as per wp 2.9 thumnail features) then do something about it ?>
					
					<div class="common-page-thumbnail-left">		   
						<?php 
						the_post_thumbnail('post-image-size');
						?>
						</div>
				<?php
					}
				}
				
				the_content();
				dynamic_sidebar('[Content Item] Below');
				echo "\n"; 
				?>
	
			</div> <!-- class="featured-page-content" -->
			
			<div class="clearFloat"></div>
	
<!--
The Home Page 'Page Block' post details 
~~~ -->
	
			<div class="featured-page-details">		
	
				<p>Publicado por
				
					<?php echo get_the_author(); ?>
					<?php /* the_author_posts_link(); */ /*uncomment this if you actually want a link to the authors posts - it reveals the authors username though - or am I being too security concious? */?>
					 el 
					<?php the_date(); echo ' a las '; the_time(); /* changed date and time format 19/10/09 so that default system date and time is used instead of preset date and time */ ?>
				</p>
				
				<p>
				<?php edit_post_link('(Edit)', '', ''); ?>
				</p>
			
			</div> <!-- class="featured-page-details" -->
			
		<?php
		} 
		?>
		
		<?php 
		/* Update for v2.3 19/10/09 
		In 2.2 common.php did not override properly in child themes.
		This new code checks to see if a child theme is installed, 
		and then checks to see if common.php exists in the child theme.
		If if does exist in the child theme then the child theme version of 
		common.php is included. 
		If not, then the common.php from the parent theme is included.
		*/
		
		$stylesheetfile = STYLESHEETPATH . '/common.php'; 
		if (function_exists('hmt_child_theme') && (file_exists($stylesheetfile)))
			include(STYLESHEETPATH."/common.php");
		else 
			include(TEMPLATEPATH."/common.php");
		
		/* end of update */ 
		?>
		

	</div> <!-- id="content" -->
	
	<?php get_sidebar(); ?>

</div> <!-- id="page-body-wrapper" -->

<?php get_footer(); ?>


<!--
End of index.php
~~~ -->

Pero los mas cercano que encuentro a ese codigo es:

en el archivo common.php

PHP:
<!--
common.php
~~~~~~~~~~~~~~~~~~~~~~~~ ~~~ -->


<!--
The Posts 
~~~~~~~~~~~~~~~~~~~~~~~~ ~~~ -->

	<?php $first_time_through=TRUE; 	// This is set so that ads are only around the first post ?>
	
	<?php if (have_posts()) : while (have_posts()) : the_post(); ?>	
<!--
Individual Post Content 
~~~ -->
	<div class="post-content">
<!--
Widget Area: [All Content] Above 
~~~ -->
		<?php 
		if ($first_time_through) {
			if (!$ads_already_shown && !$all_content_above_already_shown) { 	// check to see if the ads have already been shown due to the use of the featured page option 
				dynamic_sidebar('[All Content] Above');							// or the display of an archive or search page
			}
		}
		?>
<!--
The Post Title 
~~~ -->	
		<h1 class="h2-simulate-h1-size"><a href="<?php the_permalink() ?>" rel="bookmark"> 
			<?php the_title(); 													// Because single post or pages are more important for indexing, multiple post pages just have a h2 title for each item
			?>
			</a></h1>
<!--
Widget Area: [Content Item] Above
~~~ -->	
		<?php 
		if ($first_time_through) if (!$ads_already_shown) {
		
				dynamic_sidebar('[Content Item] Above');?>
<!--
Widget Area: [Content Item] Left 
~~~ -->
				<?php
				dynamic_sidebar('[Content Item] Left'); 
				?>			
<!--
Widget Area: [Content Item] Right
~~~ -->
				<?php
				dynamic_sidebar('[Content Item] Right');
		}		
		?>		  
			
<!--
The content itself 
~~~ -->
		<?php 
		$temp_post = get_post($post->ID, ARRAY_A);					
		$ids[] = get_the_ID(); 										// grabs the id of the page so it can be excluded in the recent posts plus widget


		if (function_exists('has_post_thumbnail')) {
			if (has_post_thumbnail()) {	//  new for 10/03/2010 - okay so if this post has a thumbnail (as per wp 2.9 thumnail features) then do something about it ?>								
			
				<div class="common-page-thumbnail-left">		   
				
					<?php
					if ((is_archive())||is_search()) the_post_thumbnail('archive-image-size'); // show a smaller thumbnail if this is an archive - otherwise just show the regular sized thumbnail
					else the_post_thumbnail('post-image-size');
					?>
				
				</div>
			
		<?php
			}
		}

		$more_text = get_post_meta($post->ID, "more-text", true);			// If you want to specify your own excerpt and 'more text' then you can do that.
		if ($temp_post['post_excerpt']) {									// This code block gets the excerpt and more text from the custom fields,
			echo '<p>' . $temp_post['post_excerpt'] . '</p><p><a href="';     // or does something sensible if you havent specified them. 
                        the_permalink();  
echo '" class="more-link">'; 
			
			if ($more_text != '') 
				echo get_post_meta($post->ID, "more-text", true) .

             '</a></p>';
			else 
				echo 'Leer el artículo completo >></a></p>';
		}
		else {
			if ($more_text == '') $more_text = 'Leer el artículo completo >>';
			the_content($more_text); 
		}
		?>


<!--
Widget Area: [Content Item] Below
~~~ -->
		<?php if ($first_time_through) if (!$ads_already_shown) dynamic_sidebar('[Content Item] Below');?>
		
	</div> <!-- class="post-content" -->
	
	<div class="clearFloat"></div>

<!--
Individual Post Details 
~~~ -->
	
	<div class="post-details">

		<p class="comment-button-box"><span class="comment-button"><a href="<?php the_permalink();?>#respond">
				<?php comments_number('Sé el primero en comentar', '1 comentario', '% comentarios');?></a> - Qué piensa usted?</span>&nbsp;&nbsp;Publicado por
			<?php echo get_the_author(); ?>
			<?php /* the_author_posts_link(); */ /*uncomment this if you actually want a link to the authors posts - it reveals the authors username though - or am I being too security concious? */?>
			 el 
			<?php the_date(); echo ' a las '; the_time(); /* changed date and time format 19/10/09 so that default system date and time is used instead of preset date and time */ ?> 
		</p>
		<p>Categorias:
			<?php the_category(', ') ?>
		&nbsp;&nbsp;Tags:
			<?php the_tags('') ?>
		</p>
		<p>
			<?php edit_post_link('(Edit)', '', ''); ?>
		</p>
	
	</div> <!-- class="post-details" -->
	
		<?php $first_time_through=FALSE; ?> 
	
	<?php endwhile; 
	
	/* deleted the no posts found statement from here 30/1/2010 so that sites using pages dont have to have posts on the home page if the site is enirely made up of pages */
	
	endif; ?>
	
<!--
Widget Area: [All Content] Below
~~~ -->
	<?php dynamic_sidebar('[All Content] Below'); ?>
	
<!--
Previous and Next Page navigation
~~~ -->
	<div class="post-nav"><p><?php posts_nav_link(); ?></p></div>
	
<!--
End of common.php
~~~ -->
 
Última edición:
solo agrega este codigo en el archivo functions.php de tu tema:


PHP:
function remove_more_jump_link($link) { 
$offset = strpos($link, '#more-');
if ($offset) {
$end = strpos($link, '"',$offset);
}
if ($end) {
$link = substr_replace($link, '', $offset, $end-$offset);
}
return $link;
}
add_filter('the_content_more_link', 'remove_more_jump_link');

mas info aqui

Nota: Si te marca error o algo avisame y lo convertimos en plugin, a veces algunos temas no aceptan codigo en el functions.php.

Saludos :top:
 
Última edición:
solo agrega este codigo en el archivo functions.php de tu tema:


PHP:
function remove_more_jump_link($link) { 
$offset = strpos($link, '#more-');
if ($offset) {
$end = strpos($link, '"',$offset);
}
if ($end) {
$link = substr_replace($link, '', $offset, $end-$offset);
}
return $link;
}
add_filter('the_content_more_link', 'remove_more_jump_link');

mas info aqui

Nota: Si te marca error o algo avisame y lo convertimos en plugin, a veces algunos temas no aceptan codigo en el functions.php.

Saludos :top:

Lo hice pero me da unos errores... si quieres puedes entrar al Blog y ves como se ve
 
Ok, para quitarnos de broncas, elimina el codigo anterior y ahorita te paso el plugin.
 
YA tengo la solucion...

Reemplaza esto:

PHP:
 <?php 
            } 
        } 

        $more_text = get_post_meta($post->ID, "more-text", true);            // If you want to specify your own excerpt and 'more text' then you can do that. 
        if ($temp_post['post_excerpt']) {                                    // This code block gets the excerpt and more text from the custom fields, 
            echo '<p>' . $temp_post['post_excerpt'] . '</p><p><a href="';     // or does something sensible if you havent specified them.  
                        the_permalink();   
echo '" class="more-link">';  
             
            if ($more_text != '')  
                echo get_post_meta($post->ID, "more-text", true) . 

             '</a></p>'; 
            else  
                echo 'Leer el artículo completo >></a></p>'; 
        } 
        else { 
            if ($more_text == '') $more_text = 'Leer el artículo completo >>'; 
            the_content($more_text);  
        } 
        ?>

por

PHP:
<a href="<a href="<?php the_permalink() ?>" title="<?php the_title(); ?>">Leer el Articulo Completo</a>

Eso esta en el archivo common.php =D
 
Aqui esta el codigo, copialo y lo pegas en un archivo nuevo con notepad, y lo salvas como leer-mas-sin-salto.php, luego lo subes a tu directorio de plugins y lo activas.

PHP:
<?php
/*
    Plugin Name: Leer mas sin salto
    Plugin URI: none
    Description: Este plugin sirve para evitar el salto del "read more"
    Version: 1.0
    Author: LA100RRA
    Author URI: http://wpplug-ins.info/
*/

function remove_more_jump_link($link) { 
$offset = strpos($link, '#more-');
if ($offset) {
$end = strpos($link, '"',$offset);
}
if ($end) {
$link = substr_replace($link, '', $offset, $end-$offset);
}
return $link;
}
add_filter('the_content_more_link', 'remove_more_jump_link');
?>

Enlace eliminado

Saludos :top:
 
Última edición:
Leí todo el post; que buen trabajo que se mandaron !!!
Felicitaciones !!!
 
Acabo a probar el plugin en RosarioCelulares.com.ar y anda de 10 !!
Congrats !!!
 
Listo, intente cada una de sus opciones por orden... y la que finalmente funciono fue el plugin de Solo, las demas posibilidades me dieron error... me estaba asustando porque en un momento toque codigo que no debia tocar... igualmente gracias a todos por su colaboracion... pero solo puedo premiar a uno que fue el que me dio la solucion... si pudiera los premiaria a todos creanme... de todas maneras ya saben que pueden contar conmigo... Exitos pa todos!

Enviando Mp a Solo!!!
 
Estado

🔒 Este tema está cerrado para nuevas respuestas.

⏰ Solo el creador del tema puede solicitar la reapertura de sus propios temas, pero únicamente dentro de los 60 días previos a la última actualización.

Temas similares

seoangel
Respuestas
4
Visitas
152
Miopin
Miopin
The_Rock
Respuestas
7
Visitas
210
Matiasgq
Matiasgq
Sannntiago
Respuestas
3
Visitas
144
Sannntiago
Sannntiago
Pipilin666
Respuestas
9
Visitas
355
Sereri
Sereri
The_Rock
Respuestas
1
Visitas
242
Edrien
Edrien
Atrás
Arriba