این هم یکی دیگه از هک هایی که میشه باهاش عمل کوچیک کردن تصوصیرهای درون پست رو باهاش انجام داد .. برای نصب ابتدا فایل ضمیمه رو دانلود بکنید و فایل xml را در هک ها و پلاگین های خود ایمپورت بکنید ..
به فایل زیر برید در مسیر includes/class_bbcode.php
پیدا بکنید کد زیر رو
کد:
return '<img src="' . $link . '" border="0" alt="" />';
بجاش این کد را قرار بدید
کد:
$dynimage = ''; if ($this->registry->options['dynamicpic_enabled']) { $dynwidth = intval($this->registry->options['dynamicpic_width']) - 1; $dynimage = ($dynwidth > 0) ? 'class="resizeimage" onload="resize_image(this, \'' . $link . '\', ' . $dynwidth . ');" ' : ''; } return '<img src="' . $link . '" border="0" alt="" ' . $dynimage . '/>'; بعد به مسیر زیر برید در ادرس clientscript/vbulletin_global.js
کد زیر را پیدا بکنید
کد:
* Function to emulate document.getElementById
بجاش این رو قرار بدید
کد:
* Function to resize an image used with the [IMG] bbcode tag * * @param string Image object * @param string Image link * @param integer Image max width */ function resize_image(obj, link, maxwidth) { if (obj.width > maxwidth) { obj.style.cursor = 'pointer'; obj.style.width = maxwidth + 'px'; obj.style.height = parseInt(obj.height * maxwidth / obj.width) + 'px'; obj.onclick = function() { window.location.href = link; return false; }; } } /** * Function to emulate document.getElementById تو قسمت Dynamic Picture Resize که در تنظیمات سیستم امده می تونید مقدار پهنای عکس مجاز رو تعیین بکنید
موفق و پیروز باشید
بهرام
علاقه مندی ها (Bookmarks)