Title: Including code in post
Last modified: August 18, 2016

---

# Including code in post

 *  [fuzzy_logic](https://wordpress.org/support/users/fuzzy_logic/)
 * (@fuzzy_logic)
 * [21 years, 2 months ago](https://wordpress.org/support/topic/including-code-in-post/)
 * I was trying to include some php code in my post and much to my surprise, the
   tags don’t show up as intended. Instead, they get interpreted, even though I 
   used the code tag to wrap it. How can I correct this?

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [Kafkaesqui](https://wordpress.org/support/users/kafkaesqui/)
 * (@kafkaesqui)
 * [21 years, 2 months ago](https://wordpress.org/support/topic/including-code-in-post/#post-179651)
 * [http://dev.wp-plugins.org/wiki/RunPHP](http://dev.wp-plugins.org/wiki/RunPHP)
 *  Thread Starter [fuzzy_logic](https://wordpress.org/support/users/fuzzy_logic/)
 * (@fuzzy_logic)
 * [21 years, 2 months ago](https://wordpress.org/support/topic/including-code-in-post/#post-179652)
 * Maybe I didn’t explain myself very well. What I’m trying to do is to simply display
   the code, not to run it.
 *  [Kafkaesqui](https://wordpress.org/support/users/kafkaesqui/)
 * (@kafkaesqui)
 * [21 years, 2 months ago](https://wordpress.org/support/topic/including-code-in-post/#post-179654)
 * Ahh!
 * Two ways to go about this:
 * 1. Instead of using opening and closing brackets: ( < and > ), use their character
   entity equivalents: &lt; and &gt;
 * 2. [http://www.coffee2code.com/archives/2005/03/29/plugin-preserve-code-formatting/](http://www.coffee2code.com/archives/2005/03/29/plugin-preserve-code-formatting/)
 *  Thread Starter [fuzzy_logic](https://wordpress.org/support/users/fuzzy_logic/)
 * (@fuzzy_logic)
 * [21 years, 2 months ago](https://wordpress.org/support/topic/including-code-in-post/#post-179656)
 * Ahhh, I totally forgot about &lt and &gt. What I ended up doing was to copy the
   code into the “design view” of Dreamweaver and then copy what’s in the “code 
   view” and pasted that into WP.
    Thanks Kafkaesqui!

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Including code in post’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 4 replies
 * 2 participants
 * Last reply from: [fuzzy_logic](https://wordpress.org/support/users/fuzzy_logic/)
 * Last activity: [21 years, 2 months ago](https://wordpress.org/support/topic/including-code-in-post/#post-179656)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
