How to set up a echo? [closed]

You can use get_post_type() function and pass current post id to it. global $post; if(get_post_type($post->ID) == ‘videos’) { // do this } Update <?php global $post; if(get_post_type($post->ID) == ‘videos’) { ?> <video class=”video” width=”https://wordpress.stackexchange.com/questions/91208/<?php echo get_field(“width’); ?>” height=”https://wordpress.stackexchange.com/questions/91208/<?php echo get_field(“height’); ?>” controls preload> <source src=”https://wordpress.stackexchange.com/questions/91208/<?php echo get_field(“mp4′); ?>” media=”only screen and (min-device-width: 960px)”></source> <source src=”https://wordpress.stackexchange.com/questions/91208/<?php … Read more