vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Auto resize Huge images for [IMG] bbcode (https://vborg.vbsupport.ru/showthread.php?t=68677)

Tradjick 12-08-2004 08:46 PM

Quote:

Originally Posted by ShaanuJaanu
nope..it doesnt resize anything.. :(

Sometimes yes, sometimes not. This sucks indeed :(

mtha 12-09-2004 02:13 AM

Quote:

Originally Posted by Tradjick
Sometimes yes, sometimes not. This sucks indeed :(

yeah, in IE, it sometimes works,sometime not.

For the same image, same page, if you refresh, its on and off :D


.... seems like when you click on the image (to see full size), the image's displayed as fullsize.

mtha 12-09-2004 05:52 AM

Quote:

Originally Posted by SVTBlackLight01

hey, try to use
if(screen.width-255 < this.width)

instead of
if(this.width>screen.width-255)
in the condition, that would work:

PHP Code:

function handle_bbcode_img_match($link
 { 
     global 
$vboptions
      
     
$link strip_smilies(str_replace('\\"''"'$link)); 
  
     
// remove double spaces -- fixes issues with wordwrap 
     
$link str_replace('  '''$link); 
  
     if (
$vboptions['legacypostbit']) 
     { 
        return 
'<a href=' $link ' target="_blank"><img src="' $link '" onload="if(screen.width-255 < this.width) {this.width=screen.width-255;this.alt=\'Full View\';}" onmouseover="if(this.alt) this.style.cursor=\'hand\';" border="0"></a>'
     } 
     else 
     { 
         return 
'<a href=' $link ' target="_blank"><img src="' $link '" onload="if(screen.width-80 < this.width) {this.width=screen.width-80;this.alt=\'Full View\';}" onmouseover="if(this.alt) this.style.cursor=\'hand\';" border="0"></a>'
     } 
 } 


Tradjick 12-09-2004 07:55 AM

Does it work then, mtha? Btw, in Opera it?s the same.

I once tried to make a condition that, if the picture is in a size that fits the forum, it doesn?t display like a link. But i suck at coding :(

mtha 12-09-2004 08:37 AM

Quote:

Originally Posted by Tradjick
Does it work then, mtha? Btw, in Opera it?s the same.

why dont you try it and see if it works? It works for me, but I didnt do a full test for it.

It does work for Opera too.

Skyline_GT 12-09-2004 09:08 AM

Quote:

Originally Posted by mtha
function handle_bbcode_img_match($link)
{
global $vboptions;

$link = strip_smilies(str_replace('\\"', '"', $link));

// remove double spaces -- fixes issues with wordwrap
$link = str_replace(' ', '', $link);

if ($vboptions['legacypostbit'])
{
return '<a href=' . $link . ' target="_blank"><img src="' . $link . '" onload="if(screen.width-255 < this.width) {this.width=screen.width-255;this.alt=\'Full View\';}" onmouseover="if(this.alt) this.style.cursor=\'hand\';" border="0"></a>';
}
else
{
return '<a href=' . $link . ' target="_blank"><img src="' . $link . '" onload="if(screen.width-80 < this.width) {this.width=screen.width-80;this.alt=\'Full View\';}" onmouseover="if(this.alt) this.style.cursor=\'hand\';" border="0"></a>';
}
}

Great, this work

Bison 12-11-2004 05:45 PM

I adjusted the size number to 1,000 and the images still don't decrease. The only good thing about this hack is that you can view the images in another window. I'd like for these off-site images to show up as resizeable thumbnails, and open up to show the original size.

That's what I thought this hack would do ...

Tradjick 12-11-2004 06:23 PM

This is the best hack i found so far: http://www.vbulletin-germany.com/for...ad.php?t=13527

Bison 12-11-2004 08:50 PM

Quote:

Originally Posted by Tradjick
This is the best hack i found so far: http://www.vbulletin-germany.com/for...ad.php?t=13527

You have to register the forum before you can download the hack, and I cannot speak one good line of German! :o

I wish someone could fix this one, I really need something that works!

SVTBlackLight01 12-11-2004 09:35 PM

Quote:

Originally Posted by Bison
I adjusted the size number to 1,000 and the images still don't decrease. The only good thing about this hack is that you can view the images in another window. I'd like for these off-site images to show up as resizeable thumbnails, and open up to show the original size.

That's what I thought this hack would do ...

It's not doing anything for me either. :ermm:


All times are GMT. The time now is 12:10 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01092 seconds
  • Memory Usage 1,749KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_php_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete