![]() |
Auto resize large image
In fact this is a work around for the auto resize feature to work with the WYSIWYG editor.
Step1. In includes/class_bbcode.php Find (in line around 18xx): Code:
return '<img src="' . $link . '" border="0" alt="" />'; Code:
return '<img src="' . $link . '" onload="if(largerThan(this.width,700)) {this.width=700;this.alt=\'Click here to see a large version\';}" onmouseover="if(this.alt) this.style.cursor=\'pointer\';" onclick="if(this.alt) window.open(\'' . $link . '\');" border="0" />'; Add this to the headinclude section: Code:
<script type="text/javascript"> http://talkmusic.org/showthread.php?t=3165 |
good grazie ... .-)
|
Simple effective, I like ;)
congratulation "Click Install" ;) |
congratulation
|
*Clicks Install* :) Thanks
|
This is the best image resizer i have seen,,
thank u very much |
What's the way for adding a text that says something like "Click on the image to see orginial size"?
ORIGINAL MOD: Code:
return '<img src="' . $link . '" onload="if(largerThan(this.width,700)) {this.width=700;this.alt=\'Click here to see a large version\';}" onmouseover="if(this.alt) this.style.cursor=\'hand\';" onclick="if(this.alt) window.open(\'' . $link . '\');" border="0" />'; WITH TEXT BELOW: Code:
return '<img src="' . $link . '" onload="if(largerThan(this.width,700)) {this.width=700;this.alt=\'Click here to see a large version\';}" onmouseover="if(this.alt) this.style.cursor=\'hand\';" onclick="if(this.alt) window.open(\'' . $link . '\');" border="0" /><br /><p>Click on the image to see original size<p />'; |
iam useing this and its usefull also .
in the same file and the same code just find this code :- PHP Code:
PHP Code:
just choose the width as u want the picture to be shown and thats all ... any way i will try ur code also |
This belongs in the code modification forum as it it edits one of the orignal vB scripts.
|
I've been looking for this. Thanks!
|
All times are GMT. The time now is 04:41 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:
|