Title: Conditional Statement Help
Last modified: August 18, 2016

---

# Conditional Statement Help

 *  Resolved [neoian2](https://wordpress.org/support/users/neoian2/)
 * (@neoian2)
 * [18 years, 8 months ago](https://wordpress.org/support/topic/conditional-statement-help/)
 * I want to use a PHP IF statement on only certain pages and on pages that aren’t
   defined I want another piece of code to run. How Do I do this?
 * I know ‘is_home’ but how do I define a certain page? Like say my about page?

Viewing 1 replies (of 1 total)

 *  [btard](https://wordpress.org/support/users/btard/)
 * (@btard)
 * [18 years, 2 months ago](https://wordpress.org/support/topic/conditional-statement-help/#post-638880)
 * You can get the ID of the page/post and test against “the_ID”. [http://codex.wordpress.org/Template_Tags/the_ID](http://codex.wordpress.org/Template_Tags/the_ID)
 * That is one way. I am wondering why this topic is resolved with no replies?

Viewing 1 replies (of 1 total)

The topic ‘Conditional Statement Help’ is closed to new replies.

 * 1 reply
 * 2 participants
 * Last reply from: [btard](https://wordpress.org/support/users/btard/)
 * Last activity: [18 years, 2 months ago](https://wordpress.org/support/topic/conditional-statement-help/#post-638880)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
