Support » Fixing WordPress » wordpress caption injects css code

  • Hi guys,

    I’m dealing with the code that automatically is injected into the html always there’s a caption.

    <div class="wp-caption alignnone" style="width: 438px">

    I’d like to overwrite it, or avoid its appearence, but I don’t know how.

    I tried :

    div .wp-caption{

    But still nothing. Neither working only with the class .wp-caption…
    I can control the image is inside but not the caption itself, which eventually appears smaller than the image, so the text that follows gets wrapped too soon.

    Did anyone solved that ?


Viewing 1 replies (of 1 total)
  • Ok, sorry.

    the ‘p’ tag which defines the text is under control now (I had some extra padding).

    If you need to make smaller the whole caption (because if your original images are huge the caption will break all), just use the max-width, to the div:

    div .wp-caption{

Viewing 1 replies (of 1 total)
  • The topic ‘wordpress caption injects css code’ is closed to new replies.