Advanced Thumbnail Popup Image Resize BBCode

User submitted BBCodes
Let us see what You have
Forum rules
We dont add more BBCodes to our database, but feel free to share and support your own BBCodes here.

[textarea]Remember that it is not allowed to use {TEXT} inside the html tags!!!
It causes a serious security risk to your board and users.
Like this: <div style="{TEXT}">{TEXT}</div>
Green = OK - Red = forbidden[/textarea]

Advanced Thumbnail Popup Image Resize BBCode

Post by Sir Xiradorn »

Advanced Thumbnail Popup Image Resize BBCode

Author: Sir Xiradorn
Description: This BBCode will allow you to create thumbnails automatically with help of javascript. To see the full-size images, pop-ups can be invoked through a simple click on that.

BBcode:

Code: Select all

[advthumb]{URL}[/advthumb]
HTML:

Code: Select all

<!-- Adv_Thumb_resize_popup_Sir_Xiradorn -->
<a style="text-decoration: none; font-style: italic; font-size: 0.75em;" href="javascript:void(0)" onclick="window.open('{URL}', 'XCyberPopUp',  'width=500,height=500,resize=1,toolbar=0,scrollbars=1,screenX=200,screenY=200,left=200,top=200')"><img onload="tempWidth=this.width; tempHeight=this.height; if(tempWidth>201||tempHeight>201) {if(tempWidth>tempHeight) {tempHeight=tempHeight*201/tempWidth;tempWidth=201} else {tempWidth=tempWidth*201/tempHeight;tempHeight=201}}; this.width=tempWidth; this.height=tempHeight;" src="{URL}" alt="{L_IMAGE}" /></a>
<!-- Adv_Thumb_resize_popup_Sir_Xiradorn -->
Example:

Code: Select all

[advthumb]http://a.imagehost.org/0012/evamendes.jpg[/advthumb]
Demo:
http://xiradorn.it/forum/viewtopic.php?f=36&t=114