Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- global $post;
- $tesimonial_list = 6;
- $testimonial_cat_id = 8;
- $args = array( 'posts_per_page' => $tesimonial_list, 'post_type'=> 'post', 'meta_key' => $testimonials_order,'orderby' => 'meta_value','order' => $testimonials_order,'category' => $testimonial_cat_id);
- $myposts = get_posts( $args );
- foreach( $myposts as $post ) : setup_postdata($post);
- ?>
- <?php
- $testimonials_order= get_post_meta($post->ID, 'testimonial_serial', true);
- $testimonial_img = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'testimonials' );
- $testimonial_name= get_post_meta($post->ID, 'testimonial_name', true);
- $testimonial_position= get_post_meta($post->ID, 'testimonial_position', true);
- $testimonial_website= get_post_meta($post->ID, 'testimonial_website', true);
- ?>
- <!-- single testimonial -->
- <div class="tesimoinal_single floatleft" id="test_monial">
- <div class="tesimonial_bg">
- <div class="tesimoinal_img">
- <img src="<?php echo $testimonial_img[0]; ?>" alt="" />
- </div>
- <div class="testimonial_text">
- <p><i class="fa fa-quote-left"></i><?php echo excerpt('35'); ?>....<i class="fa fa-quote-right"></i></p>
- </div>
- <div class="testimoinal_link">
- <a href="<?php the_permalink(); ?>">Read More</a>
- </div>
- </div>
- <div class="testimonial_tir"></div>
- <div class="tesimonial_author_info">
- <p class="testimoni_name"><?php echo $testimonial_name; ?></p>
- <p><?php echo $testimonial_position; ?></p>
- <p><?php echo $testimonial_website; ?></p>
- </div>
- </div>
- <!-- single testimonial -->
- <?php endforeach; ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement