WordPress.org

Support

Support » Themes and Templates » Emphaino » Add border around homepage images

Add border around homepage images

  • Please, how can I add a border around the images for the homepage posts?
    I want each featured post image to have a border.

    thanks

Viewing 10 replies - 1 through 10 (of 10 total)
  • Moderator Andrew Nevins

    @anevins

    Forum moderator

    Do you have a section in the dashboard for “Custom CSS” changes?

    No.

    but I have a child theme, can I add the css there?

    Moderator Andrew Nevins

    @anevins

    Forum moderator

    Yes.
    In your Child Theme style.css file, you add the CSS.

    When you say you want a border around the homepage posts, do you mean like this http://awesomescreenshot.com/0bb1456db2 ?

    yes, Emphaino has an option to display recent posts with featured images, I want to add an extra image border around those images.

    thanks.

    Moderator Andrew Nevins

    @anevins

    Forum moderator

    Can you link to your homepage?

    Theme Author Srini G

    @srinig

    Maybe you can add this in your Custom CSS.

    .wp-post-image { border: 2px solid #f00; }

    Of course, that color is red, change it to anything you want.

    thank you for the replies.
    the code above didn’t work, is there a way to make the border an image?

    Actually, I just realized non of my child theme css changes are going through. So maybe it’s not the code, but a CSS issue.
    The Child theme loads and looks all right, so I don’t know what is causing the problem.

    My site is not loaded yet, so I have no live site to show. Any help or suggestions?

    Theme Author Srini G

    @srinig

    Your child theme’s CSS should go through, unless you are doing it wrong somewhere.

    You can also try putting the code in Custom CSS option. It’s the very last option under ‘Other Settings’ in the theme customizer interface.

    I’m not aware if there is a method to make the border an image. You can try having a background image as a pattern for the featured image, and specify a padding, that could give you a patterned border effect.

    .wp-post-image {
      background: url('path-to-your-image');
      padding: 5px;
      max-width: 260px;
    }

    thank you. When I added it to the custom CSS it showed up. However, it doesn’t show up when I add it to the child css, using the editor option.

    I have double checked and the child theme loads properly, some of the other changes are coming through, but others do not.

    For example, I added a second menu, and added some CSS styling, those modifications took effect. Really odd problem.

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Add border around homepage images’ is closed to new replies.
Skip to toolbar