WordPress 2.5 : Author Bio About the Author WordPress 2.5 : Contact Form
Apr 06

Some of you may be having issues with images in posts using the new WordPress 2.5 image upload. If you find that your theme isn’t placing the images correctly you will want to take a look at your current themes style.css file to make sure the alignment rules have been written.

Note: Always, always and yes .. always make a backup before you go messing with things.

Admin > Design > Theme Editor > Current Theme > style.css

You will want to look for the following or something similar:

.alignleft {
float:left;
padding: 4px;
}

.alignright {
float:right;
padding: 4px;
}
.aligncenter {
float:center;
padding: 4px;
}

If these css rules (alignleft, alignright, aligncenter) are not currently in your style.css file simple copy and paste them in at the bottom. You can make changes if you would like; add a border etc.

If you liked the above post, why not buy a round of coffee :)

About The Author

Written by MissDanni
MissDanni is a jill of all trades, from web design to web promotion and everything in between, you might just say web everything. Working in the web industry since 2000 she continues to learn new things everyday. "Nothing is impossible if you are willing to take the time to learn and make mistakes."

Other posts by MissDanni

Tags: , , , ,

Suggested Reading

Christmas Gifts
Buy Amazing Christmas Gifts on Walmart for your family [..]
US Colleges
Choose the right college with our site. Check some [..]

8 Responses to “WordPress 2.5 : Image in Post Alignment Fix”

  1. Dan Says:

    Hey Jill Do you know why when I post an image in 2.5 it pushes my text over to the right? Here is my page http://bostonredsoxchat.com

  2. Dan Says:

    Oops sorry I meant MissDanni :)

  3. MissDanni Says:

    @ Dan

    Looking at your site I don’t see any posts that display what you mention.

    However you can control how images are displayed in the image upload when you make a post. Simply check the radio button beside your choice, none, left, right, ect.

    If you don’t want your images to align to one side and text to the other simply check none on the image unloader alignment selection.

  4. Hung Says:

    Hi … I’m running into this stubborn problem with image alignment on WP 2.5. I put the codes you suggested at end of style.css but it didn’t do a thing. Even tried to add “img” in “.alignleft … {” still didn’t change alignment. Would you please take a look at this site to see if I’ve done something stupid? Thanks!

    http://sj2.org/pauly-nguyen/

    BTW I have another website (my blogsite) which I use the Misty Look theme and images seem to align fine on that theme!

  5. MissDanni Says:

    @Hung

    Your css seems to be fine, the rules are there and should be working for you.

    One thing to note, when you upload a photo and place it in the post, select the alignment from that screen, there are radio buttons for none, left, center and right. Now in the editor it will not look like it has aligned at all, but once you make your post you will see that it has.

    Give it another try and let me know.

  6. Hung Says:

    I tried all that and the picture stubbornly remains on the left. You can see from the “view-source” that the img statement has class designated as “alignright” and it still goes to the left. Switch it to “aligncenter” and it still goes to the left. And yes I chose these from that upload photo dialog box.

    How did you look at my css file? I inserted your code, because I didn’t see that anywhere else in my css sheet. It is curious that I have no problem at another blog (http://hungpham.sj2.org). I use a different theme there though (Misty Look). I wonder if the theme I use here, after so much butchering, is messing up how Wordpress align images.

    If you can offer some help I’d really appreciate it. THANKS!

  7. MissDanni Says:

    @Hung

    That is interesting.

    Regrading your css I simply view your page source, collect your css url and load it in my browser.

    Are you by chance using a cache plugin?

    This could very well be a theme issue, the best way to find out is to switch your theme to the wordpress default theme and see if it changes anything.

  8. Hung Says:

    Hi MissDanni - thanks for the prompt response and thanks for the tip to read css url. No I don’t use a cache plugin. Probably has to do with my theme. I’ll have to take time looking into it :sad: Thanks again!





Trackbacks

Leave a Reply

Copyright 2000-2008 STCFX | Sitemap