Back to vBulletin 3.8 Add-ons

Easy Style font resizer
Mod Version: 1.00, by animcentral

vB Version: 3.8.x Rating: (2 votes - 5.00 average) Installs: 15
Released: 28 Jun 2009 Last Update: Never Downloads: 2
Not Supported Template Edits  

The following script can be used to allow visitors to increase or decrease the size of text on your page. This can be useful for visitors who have trouble reading smaller text and allows them to increase it to something they can view more easily.

Template edits:

add the following script in Header
Code:
<script type="text/javascript" language="javascript">
var min=8;
var max=18;
function increaseFontSize() {
   var p = document.getElementsByTagName('div');
   for(i=0;i<p.length;i++) {
      if(p[i].style.fontSize) {
         var s = parseInt(p[i].style.fontSize.replace("px",""));
      } else {
         var s = 12;
      }
      if(s!=max) {
         s += 1;
      }
      p[i].style.fontSize = s+"px"
   }
}
function decreaseFontSize() {
   var p = document.getElementsByTagName('div');
   for(i=0;i<p.length;i++) {
      if(p[i].style.fontSize) {
         var s = parseInt(p[i].style.fontSize.replace("px",""));
      } else {
         var s = 12;
      }
      if(s!=min) {
         s -= 1;
      }
      p[i].style.fontSize = s+"px"
   }   
}
</script>
and the following anywhere you wanna show the icons:
Code:
<div>
         <a href="javascript:increaseFontSize();"><img src="font-inc.gif" alt="Increase Font Size" style="border:0px;" /></a>
         <a href="javascript:decreaseFontSize();"><img src="font-dec.gif" alt="Decrease Font Size" style="border:0px;" /></a>
        </div>
Icons:


Demo:
http://fa.animcentral.com/forums/
comment: Persian Language

Download

No files for download.

Similar Mods

Font Resizer vBulletin 3.5 Add-ons

vblts.ru supports vBulletin®, 2022-2025