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)
-   -   Wide image automatic resize for html and vB tags in posts - fixes template problems (https://vborg.vbsupport.ru/showthread.php?t=67743)

Tradjick 12-03-2004 01:50 PM

Here?s the one I just found. It?s client side and very quick!

https://vborg.vbsupport.ru/showthread.php?t=68677

I thought i should inform some of the people that didn?t notice that hack.

Have a nice day.

dwh 12-13-2004 08:10 PM

I went through a few pages but haven't seen this question. Apologies if someone asked this. I just want to turn all outside images into links rather than an inline display while leaving attached images to thumbnails (as it works now)

dwh 12-17-2004 08:45 PM

Quote:

Originally Posted by dwh
I went through a few pages but haven't seen this question. Apologies if someone asked this. I just want to turn all outside images into links rather than an inline display while leaving attached images to thumbnails (as it works now)

Anyone have ideas?

Mechanical Mind 12-18-2004 11:11 AM

Quote:

Originally Posted by dwh
Anyone have ideas?

This should be an option already available in vBulletin 3.0.3. You just disallow IMG in the affected forum and any images attempted to be posted will be a link.

dwh 12-18-2004 03:20 PM

Quote:

Originally Posted by Mechanical Mind
This should be an option already available in vBulletin 3.0.3. You just disallow IMG in the affected forum and any images attempted to be posted will be a link.

It doesn't seem to be an option. But I got a workaround http://www.vbulletin.com/forum/showt...810#post779810

SVTBlackLight01 12-18-2004 10:50 PM

Quote:

Originally Posted by Mechanical Mind
This should be an option already available in vBulletin 3.0.3. You just disallow IMG in the affected forum and any images attempted to be posted will be a link.

What would be nice would be to turn any image over a certain size into a link instead of resizing it.

Steve St.Lauren 12-19-2004 04:32 PM

Quote:

Originally Posted by SVTBlackLight01
What would be nice would be to turn any image over a certain size into a link instead of resizing it.

That wouldn't be hard at all - this hack could be easily modified to do that. Just change lines 90 and 91 in the hack file from this:

$bbtag = '<table><tr><td align="center"><a href="' . $link . '"><img src="' . $link . '" width="'.$max_imgsize.'" border="0"'.substr($bbtag,$linkclose+1,strlen($bbt ag)-$linkclose+1).'<br>Picture has been resized, click for full size pic</a></td></tr></table>';

to this:

$bbtag = '<table><tr><td align="center"><a href="' . $link . '">' . $link . '</a></td></tr></table>';

and lines 214 & 215 of the hack file from:

$biglink = '<table><tr><td align="center"><a href="' . $link . '" ><img src="' . $link . '" width="'.$max_imgsize.'" border="0" alt=""><br>Picture has been resized, click for full size pic</a></td></tr></table>';

to:

$biglink = '<table><tr><td align="center"><a href="' . $link . '" >' . $link . '</a></td></tr></table>';

That should do what you are looking for. If you want to add some text in there as well as the link address put it right after the > just before ' . $link

If you want to replace the link address with text remove the ' . $link . ' between the > and < and place whatever text you want there.

Gnappy 12-22-2004 04:54 PM

this hack really rox, thx Steve!

[high]* Gnappy install ^^
[/high]



but i have a little question.. on my forums many ppl uses to upload images on forum, and for these images i added this tag, used to see this kind of pictures(with url dont finish with .jpg, .gif, .jpeg, etc..) i called this tag [card] (i think many other ppl here uses this tag) and it works like this:
Code:

<img src="{param}">
now, when i use [img] tag ur hack works nicely, but when i use the tag card for a forum uploaded images, the hack dont work. Its obviously that this hack is made just to be applicated to [img] tag, BUT can u tell me how can i use this nice hack to my [card] tags?

thx a lot for replies :o

HaloImpulse 12-22-2004 07:25 PM

alright, I used this on my forums when we were hosted by a hosting company called EPGservers, but we recently rented a dedicated machine from http://servermatrix.com/, the 2.4 machine, and now this hack doesnt work. Any suggestions?

Steve St.Lauren 12-23-2004 01:21 AM

Quote:

Originally Posted by HaloImpulse
alright, I used this on my forums when we were hosted by a hosting company called EPGservers, but we recently rented a dedicated machine from http://servermatrix.com/, the 2.4 machine, and now this hack doesnt work. Any suggestions?

What version of php are you running on that server? Some versions of php have trouble with the imagesize function.


All times are GMT. The time now is 12:51 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
  • Page Generation 0.01247 seconds
  • Memory Usage 1,745KB
  • 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_code_printable
  • (6)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