WordPress.org

Ready to get started?Download WordPress

Forums

Boarders on JPGS in postings (5 posts)

  1. Moosers
    Member
    Posted 6 years ago #

    Hello!

    I am inquiring about how I would put a border (say, 2 or 3 pixels) around each of the photos I use in my posts. When I do post, I usually have 3-10 photos per post.

    Is there something in the CSS that I can add to the code to make all JPGs or anything with the IMG tag automatically get a border or would I have to do that manually (and if so what would be the easiest way to do so)?

    I appreciate any assistance.

  2. Jeremy Clark
    Moderator
    Posted 6 years ago #

    Yes there is something easy you can do in your stylesheet. Look for a id #img. If it doesn't exist anywhere in your stylesheet which I doubt it wouldn't be there just add it. Use this code for a border around your picutres.

    border-width: 3px;
    You can also format the color
    border-color: #ffffff This color is white but you can change it to any hex color code.

  3. Moosers
    Member
    Posted 6 years ago #

    Thank you very much, Jeremy. That helps a ton!

  4. rudolf45
    Member
    Posted 6 years ago #

    Maybe I am from another school... but I don't think there is an "img ID" as in
    #img
    It should simply be
    img - and if there isn't, just add it to your stylesheet with the properties suggested above.

  5. Jeremy Clark
    Moderator
    Posted 6 years ago #

    Very true I'm still kinda new to the whole CSS game, I forgot that actual tags weren't designated with the #. Good catch.

Topic Closed

This topic has been closed to new replies.

About this Topic