<?php ob_start(); ?>

<?php    $count = 1; 
$query_args = array('post_type' => 'sh_services' , 'showposts' => $num , 'order_by' => $sort , 'order' => $order);

if( $cat ) $query_args['services_category'] = $cat;
$query = new WP_Query($query_args) ;  

			if($query->have_posts()):?>

				<div class="container">
					<div class="padding-top">
						<header class="header-section wow fadeInDown" data-wow-duration="1.5s">
							<h2><?php echo balanceTags($title); ?></h2>
							<p><?php echo balanceTags($text); ?></p>
						</header> <!-- / .header-section -->
						
						<div class="row margin-bottom-30">

							<?php while( $query->have_posts() ): $query->the_post(); 

								$meta = _WSH()->get_meta();

								$url = sh_set( $meta, 'single_link' );
								$limit = ( $excerpt ) ? $excerpt : 10;?>

								<div class="col-md-4">
									<div class="feature-box wow fadeIn" data-wow-delay="0s">
										<span class="fbox-icon">
											<i class="<?php echo esc_attr(sh_set( $meta, 'fontawesome')); ?>"></i>
										</span>
										<div class="fbox-content">
											<?php if( $url ): ?>
												<h4 class="uppercase"><a href="<?php echo esc_url($url); ?>" title="<?php the_title_attribute(); ?>"><?php the_title(); ?></a></h4>
											<?php else: ?>
												<h4 class="uppercase"><?php the_title(); ?></h4>
											<?php endif; ?>

											<?php echo _sh_trim(get_the_content(), $limit); ?>
										</div>  <!-- / .fbox-content -->
									</div> <!-- / .feature-box -->
								</div> <!-- / .col-md-4 -->
							
							<?php endwhile; ?>

						</div> <!-- / .row -->
					</div>
				</div>
				
			<?php endif; ?>

<?php wp_reset_postdata();
return ob_get_clean();

