Wordpress-No Border Around Pictures

Posted by Planeta Srbija | 22.9.08 | | 7 comments »

Ifyou don't want to have border around pictures in your post, even if your theme use it, just add folloving string to your specific picture (use HTML view):

<img src="http://www.blogger.com/picture.jpg" style="border: medium none ; padding: 0pt;" alt="Picture" />


There is also another way, use class within picture's HTML:

<img src="picture.jpg" class="no-border" alt="Picture" />


But also add following to your CSS file:

.no-border { border: none; padding: 0; }



To achieve an effect of double borders around your pictures, add this to your CSS:

img, a img {
padding: 3px;
border: 1px solid #01203c;
background: #eee;
}

7 comments

  1. Anonymous // 5 November 2008 at 03:51  

    hi thanks for the tip it's usefull. I used the method class="no-border" with related entry in CSS but it works just on the single post page! Strangely it does not work on archive.php and other custom pages.

    I use WP 2.6.2 and PRiNZ BranfordMagazine 2.51 (released 2008-04-20).

    Any ideas?
    Thanks anyway
    Massimo

  2. Anonymous // 6 September 2009 at 22:32  

    After looking at numerous ways to remove the border from a specific image (and close to pulling out my hair), your tip was the only one that worked!

    Thank you for posting this very useful information.

    Cheers,
    J

  3. Lionel Myszka // 1 May 2010 at 01:18  

    Thanks for your help!

  4. Anonymous // 10 May 2010 at 19:54  

    You can just click on the image once it's been uploaded into your post/page > advanced > border > 0.

    This does the same thing without needing code.

  5. david // 13 August 2010 at 15:12  

    Thanks man - Ive tried everything. Your first suggestion worked for me but not the second.

  6. Vcom Infotech Company // 15 May 2017 at 12:15  

    Nice info for the no border around the pictures displaying. Thank you very much. kovai e solutions | e-commerce online coimbatore

  7. Anonymous // 15 November 2019 at 17:22  

    spiritual growthis an important element of achieving
    success and being happy. Not everyone who has evolved has
    achieved success, [b]but everyone who has achieved success
    [url=https://coachszkolenia.wordpress.com/]coaching[/url] has
    developed and done a lot of work on themselves. [/b]
    Personal development is on the one hand my way of life,
    but also my passion and idea for living life.

Take a look on my other postings: