PHP 43
WP Popup Windows without header + footer By micha on 16th August 2019 10:49:54 AM
  1. /* ========================================================================== */
  2. /* Popup Window without header + footer */
  3. /* ========================================================================== */
  4.  
  5.  
  6. <?php
  7. if (isset($_GET['ajax'])) {
  8.  
  9.   $ajax = true;
  10.  
  11. } else {
  12.  
  13.   $ajax = false;
  14.   get_header();
  15.  
  16. }
  17.  
  18. if (have_posts()) {
  19.   while (have_posts()) { the_post();
  20.   ?>
  21.     <div class="close-ajax">
  22.       <span class="dashicons dashicons-no-alt"></span>
  23.     </div>
  24.     <div class="product-container grid-m-2">
  25.       <div class="column left-column">
  26.         <div class="text pos-v-top">
  27.           <h1 class="yellow"><?php the_title(); ?></h1>
  28.           <?php the_content(); ?>
  29.         </div>
  30.  
  31.       </div>
  32.  
  33.     </div>
  34.  
  35.   <?php
  36.   }
  37. }
  38.  
  39. if (!$ajax) {
  40.   get_footer();
  41. }

Paste is for source code and general debugging text.

Login or Register to edit, delete and keep track of your pastes and more.

Raw Paste

Login or Register to edit or fork this paste. It's free.