[code]
##############################################################
## MOD Title: Limit Image Width MOD
## MOD Author: Vic D'Elfant < vic@pythago.nl > (Vic D'Elfant) http://www.pythago.nl/
## MOD Description: This MOD will scale each image in a post so it does not exceed
## the maximum image width set by you. Smaller images will retain they
## original size.
## When clicking such a scaled down image it will open at its original
## size in a separate popup window
##
## MOD Version: 1.0.2
##
## Installation Level: Easy
## Installation Time: ~3 Minutes
## Files To Edit: includes/bbcode.php
## admin/admin_board.php
## templates/subSilver/admin/board_config_body.tpl
## languages/lang_english/lang_main.php
## languages/lang_english/lang_admin.php
## Included Files: n/a
##############################################################
## For Security Purposes, Please Check: http://www.phpbb.com/mods/ for the
## latest version of this MOD. Downloading this MOD from other sites could cause malicious code
## to enter into your phpBB Forum. As such, phpBB will not offer support for MOD's not offered
## in our MOD-Database, located at: http://www.phpbb.com/mods/
##############################################################
## Author Notes:
## * Note that since this MOD checks the image width of each posted image
## the loading process of a page containing [img] tags could be slowed
## down
## * This MOD requires the PHP GD getimagesize() function. Make sure that
## this function is installed and enabled at your web host
##
##############################################################
## MOD History:
##
## 2004-08-30 - Version 1.0.0
## - Submitted to MOD Team
##
## 2004-09-10 - Version 1.0.1
## - Fixed some compatibility problems with PHP 3.0.9
## Initial release
##
## 2004-10-19 - Version 1.0.2
## - Clicking a scaled image will now open the image in a popup window instead
## of a new browser window
## - Added tooltip and small text indicating that the user should click
## the image in order to view it at its original size
## - Added admin panel integration
##
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################
#
#-----[ OPEN ]------------------------------------------
#
includes/bbcode.php
#
#-----[ FIND ]------------------------------------------
#
// [img]image_url_here[/img] code..
// This one gets first-passed..
$patterns[] = "#\[img:$uid\](.*?)\[/img:$uid\]#si";
$replacements[] = $bbcode_tpl['img'];
#
#-----[ REPLACE WITH ]------------------------------------------
#
// [img]image_url_here[/img] code..
// This one gets first-passed..
//$patterns[] = "#\[img:$uid\](.*?)\[/img:$uid\]#si";
//$replacements[] = $bbcode_tpl['img'];
#
#-----[ BEFORE, ADD ]------------------------------------------
#
$lang['Max_img_width'] = 'Maximum image width';
$lang['Max_img_width_explain'] = 'Specify the maximum width of an image posted using the [img] tags here. The value should be in pixels.<br>Entering 0 will disable the Limit Image Width MOD';
#
#-----[ OPEN ]------------------------------------------
#
language/lang_english/lang_main.php
#
#-----[ BEFORE, ADD ]------------------------------------------
#
$lang['LIW_click_image'] = 'Click to view this image at its original size';
$lang['LIW_click_image_explain'] = 'Click on the image to view it at its original size';
Bu forumda yeni başlıklar açamazsınız Bu forumdaki başlıklara cevap veremezsiniz Bu forumdaki mesajlarınızı değiştiremezsiniz Bu forumdaki mesajlarınızı silemezsiniz Bu forumdaki anketlerde oy kullanamazsınız