MyBB Community Forums

Full Version: Give a retouch to images in threads
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
http://i.imgur.com/ojLYk.png

http://i.imgur.com/FqRpu.png

Add New My Code >

Title: Images in The Thread
Description: Add a border and a little 'shadow to the images in threads
Regular Expression: \[img\](.*?)\[/img\]
Replacement: <img ='$1';" src="$1" id="borderimage">

Go to global.css and add:

#borderimage {
        border: 6px solid #e4e4e4;
       -webkit-border-radius: 2px;
        border-radius: 2px;
       -moz-border-radius: 2px;
       -moz-box-shadow: -3px 3px 3px #B8B8B8;
       -webkit-box-shadow: -3px 3px 3px #B8B8B8;
       box-shadow: -3px 3px 3px #B8B8B8;
}
You don't need a MyCode for this. Just use the .post_content class provided by default or add your own in postbit/postbit_classic.
Yeah just adding:

.post_content img {
        border: 6px solid #e4e4e4;
       -webkit-border-radius: 2px;
        border-radius: 2px;
       -moz-border-radius: 2px;
       -moz-box-shadow: -3px 3px 3px #B8B8B8;
       -webkit-box-shadow: -3px 3px 3px #B8B8B8;
       box-shadow: -3px 3px 3px #B8B8B8;
}

into showthread.css will do the same thing. :/


(Also multiple images on the same page will all have the same ID, so you should use class)
Does it matter where I add this to showthread.css? Trying to learn more... Big Grin
Never mind, I got it. Thanks anyway. Big Grin