Homepage/Front page only conditional code wordpress

Homepage only data with default data

<?php if( is_home() || is_front_page() ) : ?>

<!-- Homepage Only Code -->

<?php else : ?>

<!-- Other Page Code -->

<?php endif; ?>


Homepage only data

<?php if( is_home() || is_front_page() ) : ?>

<!-- Homepage Only Code -->

<?php endif; ?>

Leave a Reply