wordpress-theme / category-services.php
category-services.php
Raw
<?php get_header(); ?>
<h1 class='service-heading'>Explore More</h1>
<div class="allservices-section">
<?php 
    if ( have_posts() ) {
        while ( have_posts() ) {
            the_post(); 
            ?>
            <article >
                <?php  
                    if ( has_post_thumbnail() ) { // check if the post has a Post Thumbnail assigned to it.
                        $thumbnail_url = get_the_post_thumbnail_url('', 'post-thumbnails');  
                        ?>
                        <div class="article-img-wrapper">
                            <img alt="'" src='<?php echo $thumbnail_url; ?>'>
                        </div> 
                        <?php  
                            } 
                ?>
                
                <div class="heading2"><?php the_title(); ?> </div>
        
                <br> <br> 
                <div class="service-content"> <?php the_content(); ?> </div>
        
            </article>
            <?php
        } 
    }    
        ?>
</div>
<?php get_footer(); ?>