Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

[Tip/Trick] Resize image alert and click resized image open new window

Started by gevv, June 16, 2012, 01:53:33 PM

Previous topic - Next topic


smf default image resizer system useful features

1: resize alert
2: add click this image to open new window

find Sources/subs.php (line 1267)

'content' => '<img src="$1" alt="{alt}"{width}{height} class="bbc_img resized" />',


'content' => '<table id="ncode_imageresizer_warning_1" class="ncode_imageresizer_warning" width="500"><tbody><tr><td class="td1" width="20"><img alt="resized" src="" width="17" border="0" height="17"></td><td class="td2">This image has been resized. Click this image to view the full image.</td></tr></tbody></table><a href="$1" target="_blank"><img src="$1" alt="{alt}"{width}{height} class="bbc_img " /></a>',

add code  theme index.css

table.ncode_imageresizer_warning, table.ncode_imageresizer_warning td
background-color: #fefee1; /* the bgcolor behind the text and image */
table.ncode_imageresizer_warning {
color: #000000; /* the font color */
border: 1px solid #CCCDCD; /* the border around the whole thing */

cursor: pointer;
table.ncode_imageresizer_warning td {
font-size: 10px;
vertical-align: middle;
text-decoration: none;

table.ncode_imageresizer_warning td.td1 {
padding: 5px;


change icon url (

To set the size of  table width (width="500")


hosting images


upload pictures
ElkArte is a modern, powerful community building forum software.


Hi, thx for this snippet. Works perfect. :)
Is it possible to open the full image on the parent side. Like vb?