Forums

Image captions in conflict with paragraph align (7 posts)

  1. Manydoubts
    Member
    Posted 7 months ago #

    Hi, I have a problem with captions and align paragraph. When I upload a picture and choose alignleft for it inside a justified align paragraph, everything goes well. But when a I put a caption to that image, that part of the paragraph become left align.
    Here is one example of each case:
    Images with captions

    Images without captions

    It seems that the captions have a sort of conflict with the align of the paagraph. Any idea what's going on?

  2. Manydoubts
    Member
    Posted 7 months ago #

    Sorry, here are the proper links:

    Images with captions

    Images without captions

  3. Manydoubts
    Member
    Posted 7 months ago #

    Other issue I found is that the caption doesn't respect the align I set in the css style (left), but appear centered.
    This is the code in the css style:

    .wp-caption {
    	background: #FFFFFF;
    	font: 10px "Helvetica Neue", Arial, Helvetica, "Nimbus Sans L", sans-serif;
    	margin-bottom: 0em;
    	padding: 1px 1px 1px;
    	text-align: left;
    	max-width: 96%;

    Any suggestion please?

  4. giant slayer
    Member
    Posted 7 months ago #

    The caption appears left aligned on my browser. I am using ie8.
    Another thing I noticed from the source is the multiple class declarations. You have 4 of the wp-caption and 4 of the alignleft declared in the <img> tag. It is a little overkill. You have already made those classes in the containing <div> tag.

    You may also want to have that <div> class with a float:left;. that should have all the other text wrap around it with no breaks.

  5. Manydoubts
    Member
    Posted 7 months ago #

    You are right, giant slayer, the caption appears aligned left now (it seems that it took a while for update it). I don't know where you are seeing 4 wp-caption and alignleft. I looked in the css style, but only found one, where else I need to look? About the

      float:left;
    , you mean to put it in the wp-caption code that is in the css style, like this?:
    .wp-caption {
    	background: #FFFFFF;
    	font: 10px "Helvetica Neue", Arial, Helvetica, "Nimbus Sans L", sans-serif;
    	margin-bottom: 0em;
    	padding: 1px 1px 1px;
    	text-align: left;
    	max-width: 96%;
    	float:left;
    }

    Thanks for your help.

  6. Manydoubts
    Member
    Posted 7 months ago #

    I managed that the part of the text where it is the image keep the justified align too. the only problem now is wherever I put the image (with captions) start a new paragraph.

    Images with captions

    Images without captions

    I still don't know where you found the 4 of the wp-caption and 4 of the alignleft declared in the <img> tag.

  7. Manydoubts
    Member
    Posted 7 months ago #

    giant slayer you there?

Reply

You must log in to post.

About this Topic