Title: Caption HTML Isn&#8217;t Being Generated
Last modified: August 19, 2016

---

# Caption HTML Isn’t Being Generated

 *  [kvcrawford](https://wordpress.org/support/users/kvcrawford/)
 * (@kvcrawford)
 * [16 years, 8 months ago](https://wordpress.org/support/topic/caption-html-isnt-being-generated/)
 * Take a look here: [http://comps.gunnjerkens.com/oas/wp/2009/10/](http://comps.gunnjerkens.com/oas/wp/2009/10/)
 * When I edit my posts in the WYSIWYG post editor, and I add an image with a caption,
   it shows up nicely in the WYSIWYG–with the nice-looking default formatting. When
   viewing it in HTML mode (w/o WYSIWYG), I see the [caption] tag.
 * However, when viewing the actual post, none of the HTML for the caption is there.
   I tried reverting to the default theme, and it still didn’t show up. I also tried
   disabling the “Raw HTML” plugin that I use, as well as all other plugins, and
   it still didn’t work. Any help? 🙁

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

 *  [Clayton James](https://wordpress.org/support/users/claytonjames/)
 * (@claytonjames)
 * [16 years, 8 months ago](https://wordpress.org/support/topic/caption-html-isnt-being-generated/#post-1231258)
 * A quick look at your css, and I don’t think I saw any of the wordpress generated
   classes that let a theme take advantage of the image captions and alignments 
   generated by wordpress. I may have missed it, but I don’t think I saw it anywhere.
   Here is the information about the classes that need to be present in a themes
   style sheet for wp captions and borders to work properly.
 * [http://codex.wordpress.org/CSS#WordPress_Generated_Classes](http://codex.wordpress.org/CSS#WordPress_Generated_Classes)
 *  [d_james](https://wordpress.org/support/users/d_james/)
 * (@d_james)
 * [16 years, 8 months ago](https://wordpress.org/support/topic/caption-html-isnt-being-generated/#post-1231498)
 * I’m experiencing exactly the same problem as **kvcrawford**.
 * The WYSIWYG editor wraps the <img> tag in [caption] tags, like this:
 * `[caption id="attachment_141" align="aligncenter" width="400" caption="caption
   text"]<img class="size-full wp-image-141" title="pic title" src="http://www.summitcove.
   com/wp-content/uploads/2009/08/img1.jpg" alt="alt text" width="400" height="300"/
   >[/caption]`
 * But the <img> tag doesn’t appear in the markup on the front-end until I remove
   the [caption] delimiters.
 * I added the css needed for the WordPress Generated Classes to my style.css file.
   No luck. It seems to me like you’re suggesting that the markup doesn’t appear
   unless the necessary css is detected by WordPress?
 * If that’s not the case then at the very least the HTML should be there, right?
   I’m kind of a WP noob.
 *  [d_james](https://wordpress.org/support/users/d_james/)
 * (@d_james)
 * [16 years, 8 months ago](https://wordpress.org/support/topic/caption-html-isnt-being-generated/#post-1231499)
 * Oh by the way here’s a sample page where it’s not working for me:
 * [http://www.summitcove.com/area-info/](http://www.summitcove.com/area-info/)
 * The first image is the only one on the page because I removed the [caption] tags
   that were around it.
 *  [Clayton James](https://wordpress.org/support/users/claytonjames/)
 * (@claytonjames)
 * [16 years, 8 months ago](https://wordpress.org/support/topic/caption-html-isnt-being-generated/#post-1231500)
 * My knee-jerk reaction is to say that I think the border currently surrounding
   your image is being defined by this;
 * > .entry img {
   >  /* background:#324259; border:1px solid #2B394D; padding:3px;
   > position:relative; */ border: 1px solid #404040; -moz-border-radius: 5px; -
   > webkit-border-radius: 5px; padding: 8px; }
 * ….rather than by .wp-caption ?
 * It’s really just a pretty poor guess on my part.
 * I used firebug to alter your image to what I believe it _should_ look like in
   the source (roughly) and pasted it back into firebug;
 * `<div style="width: 445px;" class="wp-caption alignnone"><img height="300" width
   ="400" alt="River Run Village in Keystone Resort" src="http://www.summitcove.
   com/wp-content/uploads/2009/08/DSC06468.jpg" title="Keystone River Run" class
   ="size-full wp-image-141"/><p class="wp-caption-text">My Caption</p></div>`
 * That left me with the proper image, and the caption , “My Caption”. It also left
   me with an extra border being generated by “.entry img”.
    After I removed this
   from your css,
 * > .entry img {
   >  /* background:#324259; border:1px solid #2B394D; padding:3px;
   > position:relative; */ border: 1px solid #404040; -moz-border-radius: 5px; -
   > webkit-border-radius: 5px; padding: 8px; }
 * It looked fine – Of course the image/caption background was #DDD instead of black
   at that point. As convoluted as it seems, I’m afraid that’s all I can offer from
   here.
 *  [d_james](https://wordpress.org/support/users/d_james/)
 * (@d_james)
 * [16 years, 8 months ago](https://wordpress.org/support/topic/caption-html-isnt-being-generated/#post-1231505)
 * Wow. Thanks for looking into this **ClaytonJames**. I really appreciate it.
 * The problem turned out to be that we had disabled several [output buffering functions](http://php.net/manual/en/book.outcontrol.php)
   in our php.ini file, which WordPress seems to rely heavily upon.
 *  [Clayton James](https://wordpress.org/support/users/claytonjames/)
 * (@claytonjames)
 * [16 years, 8 months ago](https://wordpress.org/support/topic/caption-html-isnt-being-generated/#post-1231507)
 * Glad to hear you got it working. Best wishes!
 *  [petufo](https://wordpress.org/support/users/petufo/)
 * (@petufo)
 * [16 years, 4 months ago](https://wordpress.org/support/topic/caption-html-isnt-being-generated/#post-1231527)
 * I have the same problem, byt I can’t edit php.ini… any ideas how to solve it?
   🙁

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

The topic ‘Caption HTML Isn’t Being Generated’ is closed to new replies.

## Tags

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

 * 7 replies
 * 4 participants
 * Last reply from: [petufo](https://wordpress.org/support/users/petufo/)
 * Last activity: [16 years, 4 months ago](https://wordpress.org/support/topic/caption-html-isnt-being-generated/#post-1231527)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
