// JavaScript Document

var min=8;
var max=24;
/*
function increaseFontSize() {
   var p = document.getElementsByTagName('p');
   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('p');
   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"
   }   
}
*/


function changeFontSize(inc)
{
  var p = document.getElementsByTagName('p');
  for(n=0; n<p.length; n++) {
    if(p[n].style.fontSize) {
       var size = parseInt(p[n].style.fontSize.replace("px", ""));
    } else {
       var size = 14;
    }
    p[n].style.fontSize = size+inc + 'px';
   }
}


function resetFontSize()
{
  var p = document.getElementsByTagName('p');
  for(n=0; n<p.length; n++) {
    if(p[n].style.fontSize) {
       p[n].style.fontSize = '14px';
   }
  }
}



function toggleDivs(param){
	if (param=='rss_div'){
		$('#rss_div').show();	
		$('#fb_div').hide();
		$('#tw_div').hide();
		
	}
	
	if (param=='fb_div'){
		$('#fb_div').show();	
		$('#rss_div').hide();
		$('#tw_div').hide();
		
	}
	
	if (param=='tw_div'){
		$('#tw_div').show();	
		$('#rss_div').hide();
		$('#fb_div').hide();
	}
}
