![]() |
Auto Resize large images in an IMG tag
Sorry about my bad english :rolleyes:
With this small hack, all large images in an IMG Tag will be resized after the site has loaded. With a click on the resized imge, it will open in an new window with the original size. Works in Firefox, Opera, IE and i think in all other browser. Here is a Demo: Link Work with vB 3.7.x INSTALLATION: -------------------------------- - Copy the file resizevbimg.js in the dir clientscript. -------------------------------- Open the file includes/class_bbcode.php Search the line(~line 1932 ): Code:
return '<img src="' . $link . '" border="0" alt="" />'; Code:
return '<img src="' . $link . '" border="0" alt="" id="vBCodeIMG" />'; -------------------------------- Styles & Templates > Search the SHOWTHREAD Template Seach: Code:
<body onload="$onload"> Code:
<body onload="$onload;vbImageResize()"> -------------------------------- Styles & Templates > Search the newreply Template Search: Code:
<body$onload> Code:
<body onload="$onload;vbImageResize()"> -------------------------------- - Styles & Templates > Style Manager > Common Templates > headinclude Search: Code:
<!-- / CSS Stylesheet --> Code:
<script type="text/javascript" src="clientscript/resizevbimg.js"></script> -------------------------------- Styles & Templates > Style Manager > Main CSS > Additional CSS Definitions After, add: Code:
.vbimgcodelimit { -------------------------------- Done :) |
Nice, it's almost as spleasure's resize mod.
Is there any way you can choose the minimum size that the mod resizes? |
i think THIS is better :)
|
That's for 3.6 this one is specially made for 3.7...
Don't be an ass. |
Quote:
I don't need and want for img resizes DB queries. ^^ |
Quote:
Quote:
|
Quote:
Open the resizevbimg.js with an text editor and change the two values (500 is default size) to your new minimum size. |
is there any way install whit out all that edits ?
|
No there isn't. The instructions are very easy to follow.
Nice add on. Regards Jason :) |
is it compatible with vb 3.6.8 ?
|
All times are GMT. The time now is 06:03 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|