vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=228)
-   -   Forum Display Enhancements - Image Resize using Lytebox (https://vborg.vbsupport.ru/showthread.php?t=171985)

Lost Heaven 03-02-2008 10:00 PM

Image Resize using Lytebox
 
This's simple hack for resize large images using Lytebox,also integration with vB attachments for vbb 3.7.x.I used it on my forum http://Hoiquantinhoc.com and i didnt see any problem with it.Here you can see online demo
Here we go !

/////////////////////////////////////////////////////////////////////////
HISTORY
Ver 1.5
  • Using lytebox instead lightbox.
  • Fixed conflict javascripts.
Ver 1.0
  • First release.
/////////////////////////////////////////////////////////////////////////
INSTALLATION
  • Upload files from folder upload.
  • Import Product ImageResize_MK.xml
  • Edit file includes/class_bbcode.php,find
PHP Code:

return '<img src="' .  $link '" border="0" alt="" />'

Replace with
PHP Code:

return '<a target="_blank" href="' $link '" rel="lytebox"><img src="' $link '" border="0" alt="" /></a>'

Note:Also remember active vblightbox option : ACP=>Message Attachment Options =>Use Image Lightbox = > Yes - Click

Default max width available of images is 500px,you can change it in ACP => Image Resize Using Lytebox.

=====================================

Đ?y l? mod resize image v? chức năng duyệt images thumbnail sử dụng thư viện lytebox,biến thể của lightbox2.

///////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
HISTORY
Ver 1.5
  • Sử dụng bộ thư viện lytebox ( lightbox2 ) thay cho lightbox.
  • Fixed conflict javascripts.
Ver 1.0
  • Bật / Tắt Chức năng resize ảnh.
  • T?y chọn k?ch thước tối đa cho ph?p của ảnh.
/////////////////////////////////////////////////////////////////////////
Installation :
  • Upload c?c file trong thư mục upload l?n thư mục tương ứng của host.
  • Import Product ImageResize_MK.xml
  • Edit file includes/class_bbcode.php,t?m
PHP Code:

return '<img src="' .  $link '" border="0" alt="" />'

Thay bằng
PHP Code:

return '<a target="_blank" href="' $link '" rel="lytebox"><img src="' $link '" border="0" alt="" /></a>'

////////////////////////////////////////////////////////////////////////////
Lưu ? :
Những ai d?ng vbb 3.7 nhớ active lightbox nghen : ACP=>Message Attachment Options =>Use Image Lightbox = > Yes - Click
Mod được hỗ trợ tốt nhất tại http://hoiquantinhoc.com

Sorry,im very bad in English ^^ .

zmmmzz 03-03-2008 04:55 PM

thanks!

codershark 03-03-2008 04:56 PM

extrem wonderfull hack !

logicuk 03-03-2008 05:27 PM

wow man this hack is just what ive been looking for amazing

installed and nominated for hotm :D

Lost Heaven 03-03-2008 05:29 PM

Thank you ^^ .

RvG2 03-03-2008 05:48 PM

thanks :)

Taragon 03-03-2008 08:10 PM

very nice! thanks!

xixxon 03-03-2008 10:13 PM

nice...exactly wat i need...thanks a lot

Brew 03-04-2008 03:46 AM

What if you had very large pics?

Like 1990X900 or some-such?

Would this include a link to show full size?

So it would show an intermediate size, say 800x600 then you would click the lightbox and it would show the full size.

Thanks!

Lost Heaven 03-04-2008 07:19 AM

Quote:

What if you had very large pics?

Like 1990X900 or some-such?

Would this include a link to show full size?

So it would show an intermediate size, say 800x600 then you would click the lightbox and it would show the full size.

Thanks!
By default,the javascript auto resize images if larger than the browser window dimensions,you can change this setting in file lytebox.js :
PHP Code:

this.autoResize            false

Thank you,hope you like this mod ^^


All times are GMT. The time now is 03:45 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.01210 seconds
  • Memory Usage 1,748KB
  • 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
  • (5)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)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