I see there have been a few people asking how to do this.
First, Create a page template that you will apply to pages to be displayed in the Thickbox. You new page template should be minimalist, without menus and other extraneous stuff, perhaps showing only the page content. Here’s a really simple one:
<?php /* Template Name: Thickbox Page */ ?> <div id="thickbox-page"> <?php if (have_posts()) : while (have_posts()) : the_post();?> <div class="post"> <h2 id="post-<?php the_ID(); ?>"><?php the_title();?></h2> <div><?php the_content(); ?></div> </div> <?php endwhile; endif; ?> </div>
Now create a page, say “My New Post”, apply the “Thickbox Page” template and publish.
From any other page or post, add a link to your new page’s permalink and make sure that you include the
thickboxclass attribute with the anchor:
<a href="/my-new-post" class="thickbox">Click here for a page in a popup</a>
- The topic ‘WP Page in a Thickbox’ is closed to new replies.