• 1. When I created a page with “grid” tempalte ,and I chacked the “Load items on same page”,and I selected one of the “Filter by taxonomy” as one tag.
    I finished above,when I try to browse the page and click the ajax button,all of other articles but not the tag articles above append the bottom of the page.

    2. Sometimes I edit an old article (maybe under the page 2 or 3),set a thumbnail pictures,and I chacked the “Hide featured image” in General settings. But when I browse the grid page use the ajax load, the thumbnail picture of the article did not show as I think and not fit with your words “Check this option if you DO NOT want to display the featured image (thumbnail) on the page; it will still be used for the corresponding tile on the “columns” or “rows” grid pages.”

    all above is both the ajax load problems,thanks.

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter perickr

    (@perickr)

    I have fix it myself.they are bugs of functions.php and tampalete-tags.php.

    please fix it next version.thank you.

    Theme Author satoristudio

    (@satoristudio)

    Hello @perickr,

    thanks for choosing Bento!
    Could you please share your solutions, so that we could include those into the next version of the theme and benefit all of its users? Cheers!

    Thread Starter perickr

    (@perickr)

    @satoristudio OK,glad to share.

    1. insert code below into function bento_ajax_pagination() in functions.php

    
    $bento_tax_filter = get_post_meta( $post_id, 'bento_filter_taxonomy', true );
    	if ( $bento_tax_filter && $bento_tax_filter != 'all' ) {
    		$term = get_term( $bento_tax_filter );
    		$query_args['tax_query'] = array(
    			array(
    				'taxonomy' => $term->taxonomy,
    				'field' => 'term_id',
    				'terms' => $bento_tax_filter,
    			),
    		);
    	}
    

    2. change the function bento_post_thumbnail() in theme/bento/includes/template-tags.php.

    // Display an optional post thumbnail.	
    function bento_post_thumbnail() {
    	
    	global $post;
    	global $bento_parent_page_id;
    	
    	// Check if it's one of the situations when a thumbnail is not needed, and exit if yes
    	if ( 
    		! has_post_thumbnail() || 
    		post_password_required() || 
    		is_attachment() || 
    		get_post_format( $post->ID ) === 'quote' ||
    		//perick add: get_page_template_slug( $bento_parent_page_id ) != 'grid.php'
    		( ! is_page() && get_post_meta( $post->ID, 'bento_hide_thumb', true ) == 'on' && get_page_template_slug( $bento_parent_page_id ) != 'grid.php') ||
    		( is_singular() && get_post_meta( $post->ID, 'bento_activate_header', true ) == 'on' && ( $bento_parent_page_id == $post->ID || is_single() ) ) 
    	) {
    		return;
    	}
    	
    	if ( is_singular() && get_page_template_slug( $bento_parent_page_id ) != 'grid.php' ) {
    		?>
    		<div class="post-thumbnail">
    			<?php the_post_thumbnail(); ?>
    		</div>
    		<?php 
    	} else { 
    		?>
    		<div class="post-thumbnail">
    			<a class="post-thumbnail" href="<?php the_permalink(); ?>">
    				<?php
    				the_post_thumbnail( 'post-thumbnail', array( 'alt' => get_the_title() ) );
    				?>
    			</a>
    		</div>
    	
    		<?php
    	}
    	
    }
    Theme Author satoristudio

    (@satoristudio)

    Thank you, @perickr!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Problems about Ajax Load’ is closed to new replies.