I have a bit of content in a PHP file that is designed to live inside an iframe on another page. The PHP file is very simple-- here it is in its entirety right now:
<div class="content-tos"> <?php // get the terms of service from other page $getpage = get_page_by_path('/terms-of-service'); echo apply_filters('the_content', $getpage->post_content); ?> </div>
Obviously I need to include something above these lines of code so the PHP has access to the Wordpress core functions (like
get_page_by_path())... but if I use
get_header() I get my entire header, nav bar, Google Analytics tracking code etc, which then appear inside the iframe, which I definitely don't want.
Is there a way in Wordpress to do some kind of include that will give me the basic Wordpress API but won't draw a full HTML header, etc, etc, etc from the