The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Plus - minus

View previous topic View next topic Go down

Solved Plus - minus

Post by Yakko! on October 14th 2010, 5:49 pm

How to have this:


in the gangstar forum!

Yakko!
Forumember

Male Posts : 661
Reputation : -5
Language : Italian, english, Français

Back to top Go down

Solved Re: Plus - minus

Post by Guest on October 14th 2010, 5:52 pm

That's font resizer, can only done by phpbb2 or punbb.

Guest
Guest


Back to top Go down

Solved Re: Plus - minus

Post by Yakko! on October 14th 2010, 5:53 pm

yes! i have punBB

Yakko!
Forumember

Male Posts : 661
Reputation : -5
Language : Italian, english, Français

Back to top Go down

Solved Re: Plus - minus

Post by Guest on October 14th 2010, 5:55 pm

Okay Go to

ACP - Display - Templates - Overall_header:

Paste this part under <head> tag:
Code:

<script  type="text/javascript">
var min=11;
var max=18;
function increaseFontSize() {
  var p = document.getElementsByTagName('span');
  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('span');
  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 paste this part anywhere under the <body> tag:
Code:

<br><a href="javascript:decreaseFontSize();"><img src="http://cdn.iconfinder.net/data/icons/diagona/icon/16/104.png" border="0" Alt="Decrease font size"></a>
<a href="javascript:increaseFontSize();"><img src="http://cdn.iconfinder.net/data/icons/woothemesiconset/16/add.png" border="0" Alt="Increase font size"></a>
<br>

Save + Publish

Its unfair i given my codes away lol ;D Rolling Eyes

Guest
Guest


Back to top Go down

Solved Re: Plus - minus

Post by Saxaca on October 14th 2010, 6:59 pm

Gangstar, you have to learn. Lol. Cool people like sharing codes.
Anyways, i suppose that script will work on my HTML pages?

Saxaca
Forumember

Male Posts : 539
Reputation : 26
Language : Markup.

Back to top Go down

Solved Re: Plus - minus

Post by Guest on October 14th 2010, 7:44 pm

Haha Very Happy i will Very Happy yah but you must have <span> </span> tags around the text you want to resizer (:

Guest
Guest


Back to top Go down

Solved Re: Plus - minus

Post by Yakko! on October 17th 2010, 2:48 pm

Thanks!
solved

Yakko!
Forumember

Male Posts : 661
Reputation : -5
Language : Italian, english, Français

Back to top Go down

Solved Re: Plus - minus

Post by Guest on October 17th 2010, 4:16 pm

Solved Locked

Guest
Guest


Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum