Title: Make non-WP page recognize conditional?
Last modified: August 18, 2016

---

# Make non-WP page recognize conditional?

 *  Resolved [Doodlebee](https://wordpress.org/support/users/doodlebee/)
 * (@doodlebee)
 * [18 years, 12 months ago](https://wordpress.org/support/topic/make-non-wp-page-recognize-conditional/)
 * I was wondering, really quickly, if there was something I could place in the 
   top of a non-WordPress handled page that would make WordPress recognize it as
   a non-WordPress page, and I could write a conditional statement for it?
 * To try and give a better explanation, I have a page that is outside of WordPress.
   However I’ve brought in the wp-blog-header.php file in the top, so I can use 
   WordPress calls for the layout (get_header() and all that). However, I have a
   number of conditional statements for the whole site, and I need this non-WordPress
   page to have the same layout as my Pages (I’m using a `body id="page"` thing).
   But the conditional doesn’t recognize the non-WP page, and is giving it the default
   blank body tag. It’s totally understandable *why* it’s doing this, but I can’t
   seem to come up with the right code snippet to place in the non-WP page to “tag”
   the page with something so I can make the WP conditional recognize what it is,
   and serve the right body ID.
 * Man, I hope that made sense.

Viewing 1 replies (of 1 total)

 *  Thread Starter [Doodlebee](https://wordpress.org/support/users/doodlebee/)
 * (@doodlebee)
 * [18 years, 12 months ago](https://wordpress.org/support/topic/make-non-wp-page-recognize-conditional/#post-569593)
 * Crap. 5 minutes go by, and I’ve figured it out.
 * I added:
 *     ```
       <?php if($postID == "") { ?>
       <body id="nonWP">
       <?php } ?>
       ```
   
 * So it looks to see if there’s any post ID set for the page. If not, it’s not 
   a WP page, and therefore gets the new ID. Yay!
 * Haven’t completely tested it out yet, but so far, I’m good.

Viewing 1 replies (of 1 total)

The topic ‘Make non-WP page recognize conditional?’ is closed to new replies.

## Tags

 * [conditional](https://wordpress.org/support/topic-tag/conditional/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 1 participant
 * Last reply from: [Doodlebee](https://wordpress.org/support/users/doodlebee/)
 * Last activity: [18 years, 12 months ago](https://wordpress.org/support/topic/make-non-wp-page-recognize-conditional/#post-569593)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
