WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] posts_nav_link not working on category page (3 posts)

  1. betzy
    Member
    Posted 1 year ago #

    i have archive.php with this code

    <?php get_header(); ?>
    
    	<!-- - - - - - - - - - - - - - - Container - - - - - - - - - - - - - - - - -->	
    
    	<section class="container sbr clearfix">
    
    		<!-- - - - - - - - - - Page Header - - - - - - - - - - -->	
    
    		<div class="page-header">
    
    			<h1 class="page-title"> <?php single_cat_title(); ?> </h1>
    
    		</div><!--/ .page-header-->
    
    		<!-- - - - - - - - - end Page Header - - - - - - - - - -->	
    
    		<!-- - - - - - - - - - - - - - - Content - - - - - - - - - - - - - - - - -->		
    
    		<section id="content">
    
    			<section class="content-event">
    
    				<article class="event-item clearfix">
    									             <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
    
    					<div class="event-body">
    
    						<?php // check if the post has a Post Thumbnail assigned to it.
    if ( has_post_thumbnail() ) {
    	the_post_thumbnail('medium');
    } ?>
    
    					</div><!--/ .event-body-->
    
    					<div class="event-meta">
    						<h3 class="title">
    				<a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h3>
    
    						<table class="event-table">
    
    							<tr>
    								<td><strong>Model:</strong></td>
    								<td><?php the_field('model'); ?></td>
    							</tr>
    							<tr>
    								<td><strong>Pret:</strong></td>
    								<td><?php the_field('pret'); ?> €</td>
    							</tr>
                                                            <tr>
    								<td><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><img src="http://fcservizi.ro/wp-content/uploads/2013/03/detalii.jpg"></a></td>
    
    							</tr>
    						 </table><!--/ .event-table-->
    
    					</div><!--/ .event-meta-->
    					<?php endwhile; endif; ?>
    				</article><!--/ .event-item-->
    
    			</section><!--/ content-event-->
    
    		</section><!--/ #content-->
     		<!-- - - - - - - - - - - - - - end Content - - - - - - - - - - - - - - - - -->
    		<!-- - - - - - - - - - - - - - - Sidebar - - - - - - - - - - - - - - - - -->
    <?php if ( !function_exists('dynamic_sidebar')
    || !dynamic_sidebar('sidebar') ) : ?>
    <?php endif; ?>
    			</section><!--/.container -->
    	<?php get_footer(); ?>

    and i can”t make the nav_link to show up, pls help

  2. alchymyth
    Forum Moderator
    Posted 1 year ago #

    where have you tried to add the code?

    a normal space would be after the 'endwhile' of the loop;

    http://codex.wordpress.org/Function_Reference/posts_nav_link

    does the archive have more posts than are set under dashboard - settings - reading - blog pages show at most [] posts?

  3. betzy
    Member
    Posted 1 year ago #

    =)))))) damn, i"ve tried all the codes i could find in codex, all the plugins, my problem was the number of post, ahahahah

    10q alchymyth

Topic Closed

This topic has been closed to new replies.

About this Topic