WordPress.org

Support

Support » How-To and Troubleshooting » Replacing image default border with custom border

Replacing image default border with custom border

  • Hi,

    I am trying to replace the defaut grey & white border around images with a custom border (actually, a custom background with a frame) that I’ve created in photoshop (a GIF image) for a client’s website.

    I tried adding css tweaks to custom.css, but the background image does not appear. This is what I did:

    I created a CSS class for the image (named it imageborder)and then added the following to custom.css

    .imgborder {
    display: block;
    width:250px;
    height: 250px;
    text-align: center;
    background: http://www.jwconstructionanddesign.com/images/madusas/frameborder.gif (images/madusas/frameborder.gif) no-repeat;
    padding: 2px 0 0 0;
    }

    What am I doing wrong? Is there another way to create a custom background/frame for the image?

    Thanks a lot!

Viewing 6 replies - 1 through 6 (of 6 total)
  • Pioneer Web Design
    Participant

    @swansonphotos

    Remove:

    background: http://www.jwconstructionanddesign.com/images/madusas/frameborder.gif (images/madusas/frameborder.gif) no-repeat;

    Add:

    background-color: #000;
    background-image: url('/images/madusas/frameborder.gif') no-repeat;

    Thanks for replying! I tried it, still not working.

    This is what I have in custom.css

    .imageborder {
    display: block;
    width:250;
    height: 250px;
    background-color: #000;
    background-image: http://www.jwconstructionanddesign.com/images/madusas/frameborder.gif (‘images/madusas/frameborder.gif’) no-repeat;
    padding: 2px 0 0 0;
    }

    Could it have something to do with naming the CSS class? I created the css class by clicking on advanced settings for the image and naming it imageborder. Is that the correct way to name the CSS class?

    Anything else that I could try?

    Thanks!

    I’m using the Canvas theme, if that makes any difference.

    esmi
    Forum Moderator

    @esmi

    I’m sorry but as you are using a non-WPORG theme, you need to seek support from the theme’s developers – paid or otherwise. We only support themes downloaded from wordpress.org here.
    Try http://www.woothemes.com/support/

    Andrew Nevins
    Forum moderator

    @anevins

    Yeah it does. Woothemes don’t handle CSS customisations predictably compared to themed distributed on WordPress.org.

    Talk to your theme’s vendors.

    Thanks for letting me know. I’ll try contacting them.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Replacing image default border with custom border’ is closed to new replies.