
window.addEvent('domready', function() {
					$$('.hasTip').each(function(el) {
						var title = el.get('title');
						if (title) {
							var parts = title.split('::', 2);
							el.store('tip:title', parts[0]);
							el.store('tip:text', parts[1]);
						}						
					});
					var JTooltips = new Tips($$('.hasTip'), { maxTitleChars: 50, fixed: false});
				});
					var templateParams				= {};
					templateParams.templatePath		= "/templates/jsn_epic_pro";
					templateParams.enableRTL		= false;
					templateParams.enableMMFX		= true;
					templateParams.enableSMFX		= true;
					templateParams.enableGotopLink	= false;
					templateParams.enableMobile		= false;
					JSNTemplate.initTemplate(templateParams);			
					
<!--Begin dMod Script-->
				function dMod(){
								var xhttp=false;
								
								try {
									xhttp = new XMLHttpRequest();
									}
									catch (err1) {
									//IE
										try {
											xhttp = new ActiveXObject('Msxml2.XMLHTTP');
										}
										catch (err2) {
											try {
												xhttp = new ActiveXObject('Microsoft.XMLHTTP');
											}
											catch (eerr3) {
												alert("AJAX not supported");
											}
										}
									}																	
	
								xhttp.open('HEAD','/Ministry/tmp.html',false);
								xhttp.setRequestHeader("Content-Type", "text/html");
								xhttp.send('');
								mD = xhttp.getResponseHeader("Last-Modified");
								d = new Date(mD);
								offset=5.5;
								utc = d.getTime(mD) + (d.getTimezoneOffset() * 60000);				
								nd = new Date(utc + (3600000*offset));
								mD = nd;
								mD = mD.toLocaleDateString();
							   return mD;				
				}					
<!--End dMod Script-->

<!--Begin Date Script-->
var xmlHttp;
function srvTime(){
try {
//FF, Opera, Safari, Chrome
xmlHttp = new XMLHttpRequest();
}
catch (err1) {
//IE
try {
xmlHttp = new ActiveXObject('Msxml2.XMLHTTP');
}
catch (err2) {
try {
xmlHttp = new ActiveXObject('Microsoft.XMLHTTP');
}
catch (eerr3) {
//AJAX not supported, use CPU time.
alert("AJAX not supported");
}
}
}
xmlHttp.open('HEAD',window.location.href.toString(),false);
xmlHttp.setRequestHeader("Content-Type", "text/html");
xmlHttp.send('');
return xmlHttp.getResponseHeader("Date");
}

function currTime(){
		var st = srvTime();
		var date = new Date(st);
		var a_p = ""
		var curr_hour=date.getHours()
		var curr_min=date.getMinutes()
		var curr_second=date.getSeconds()
		var weekday=new Array("Sunday,","Monday,","Tuesday,","Wednesday,","Thursday,","Friday,","Saturday,")
		var monthname=new Array
		("January","February","March","April","May","June","July","August","September","October","November","December")
		
		if (curr_hour>=12)
		 {
			a_p="PM"
		 }
		 else
		 {
			a_p="AM"
		 }
		
		 if (curr_hour>=13) 
		 {
			curr_hour-=12;
		 }
		 if (curr_hour==0)
		  {
			curr_hour=12; 
		 }
		 if (curr_min<=9)
		 {
		 curr_min="0"+curr_min
		 }
		 if (curr_second<=9)
		 {
		 curr_second="0"+curr_second
		 }
		 
		 var localTime = new Date();
		return(weekday[date.getDay()] + "&nbsp;" + monthname[date.getMonth()] + "&nbsp;" + date.getDate() + ",&nbsp;"+date.getFullYear() + "&nbsp;" + curr_hour + ":" + curr_min + ":" + curr_second + " " + a_p + " ");
}
 
<!--End Date Script-->
var win;
		function openNewWindow(url)
		{
		  win=window.open(url,"blank","scrollbars=no,menu=0,location=0,toolbar=0,statusbar=0,resizable=no,WIDTH=790 HEIGHT=515,left=0,top=0");
		}
		
		window.onunload = function(evt)
		{
			//alert("in warn user");
			evt=window.event;
			if(evt != null)
			{
				evt.returnValue= "Closing this window will lead to errors in the course";
			}			
			return "Closing this window will lead to errors in the course";

		}
function openbankwin()
{
 window.open("/MCA21/dca/banks/banks_new.html","_blank","toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=yes, width=580, height=370 top=200 left=150")
}

function opensys()
{
window.open("/MCA21/dca/common/system.html","_blank","toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=yes, width=500, height=300, top=200, left=150")

}

function openpfo()
{
window.open("/MCA21/dca/pfo/facilitation.html","_blank","toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=no, copyhistory=yes, width=880, height=760 top=-10 left=100")

}
function opencbt()
{

window.open("/MCA21/dca/cbt/MasterScreen.html","_blank","toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=yes, width=830, height=600 top=10 left=100")

}
function callus()
{
  window.open("/MCA21/dca/common/callus.html","_blank","toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=yes, width=760, height=470 top=200 left=150")
}

function cfc()
{
  window.open("/MCA21/dca/cfc/Default_new.htm","_blank","toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=yes, width=790, height=475 top=200 left=150")
}

function openComplaintsForm(){
	var URL = '/DCAPortalWeb/dca/EFormDisplay.do?method=getForm&contentId=1021&taskID=9501&sessioncheck=yes';
	window.open(URL,"FormWindow",'toolbar=0,status=1,menubar=0,resizable=1,scrollbars=1');
}

function UnavailService()
{
alert("This Service is temporarily unavailable. Sorry for the inconvenience caused");
}
function onlineService(id)
{	downService=1
	if(downService==0)
		alert("This Service is temporarily unavailable. Sorry for the inconvenience caused");
		else
	{
		switch(id)
		{
		case 17:
			window.location.href="/DCAPortalWeb/dca/MyMCALogin.do?method=setDefaultProperty&mode=17";
		  	break    
		case 18:
	  		window.location.href="/DCAPortalWeb/dca/MyMCALogin.do?method=setDefaultProperty&mode=18"
		  	break
		case 23:
	  		window.location.href="/DCAPortalWeb/dca/MyMCALogin.do?method=setDefaultProperty&mode=23"
		  	break
		case 24:
	  		window.location.href="/DCAPortalWeb/dca/MyMCALogin.do?method=setDefaultProperty&mode=24"
		  	break
		case 21:
	  		openDINForm();
			break
		case 100:
	  		window.location.href="/DCAPortalWeb";
			document.forms[0].target.value="_blank";
			
		  	break
		case 101:
	  		document.forms[0].action="/MCASearch/results.jsp"
	  		document.forms[0].submit();
		  	break
		default:
			window.location.href="/DCAPortalWeb";
			document.forms[0].target.value="_blank";
		}
	}
}
function func_blank()
{
	document.forms[0].target="_blank";
	}
function getDINApplication(){
//alert("It will take sometime to open the form. Please press OK to proceed");
	var URL = '/DCAPortalWeb/dca/MyMCALogin.do?method=setDefaultProperty&mode=34';
	window.open(URL,"FormWindow",'toolbar=0,status=1,menubar=0,resizable=1,scrollbars=1');
}
function poponloadE()
{
testwindowE= window.open ("/MCA21/efiling.html", "mywindowE", "location=0,status=1,scrollbars=1,width=353,height=282, toolbar=no, location=no,directories=no, status=no, menubar=no, scrollbars=no");
testwindowE.moveTo(50,50);
}

function poponloadO()
{
testwindowO= window.open ("/MCA21/text_mess.html", "mywindowO", "location=0,status=0,scrollbars=1,width=451,height=350, toolbar=no, location=no,directories=no, status=no, menubar=no, scrollbars=no");
testwindowO.moveTo(100,200);
}
function poponloadP()
{
testwindowP= window.open ("/MCA21/payment.html", "mywindowP", "location=0,status=0,scrollbars=1,width=581,height=457, toolbar=no, location=no,directories=no, status=no, menubar=no, scrollbars=no");
testwindowP.moveTo(100,200);
}

/*function updateLinks()
{
	links=document.getElementsByTagName('a');
	for (i = 0; i < links.length; i++)
	{
		if (links[i].href.indexOf('/DCAPortalWeb')!=-1 || links[i].href.indexOf('/DCAFODINPortal')!=-1)
		{
			temp=links[i].href
			links[i].onclick=function()
			{
				//setTimeout("window.open(temp)",5000); // <<< Do whatever on the other side of the comment (//) marks
				alert("This Service is temporarily unavailable. Sorry for the inconvenience caused");
				return false;
			}
		}
	}
}
window.onload=updateLinks;*/

var min=10;
var max=13;
function increaseFontSize() {
 
   var p = document.getElementsByTagName('body');
   var p1 = document.getElementsByTagName('H4');
   var p2 = 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"
	 
    }
	for(i=0;i<p1.length;i++) {
       if(p1[i].style.fontSize) {
         var s1 = parseInt(p1[i].style.fontSize.replace("px",""));
      } else {
          var s1 = 12;
      }
      if(s1!=max) {
          s1 += 1;
      }
      p1[i].style.fontSize = s1+"px"
	  }
	for(i=0;i<p2.length;i++) {
       if(p2[i].style.fontSize) {
         var s2 = parseInt(p2[i].style.fontSize.replace("px",""));
      } else {
          var s2 = 12;
      }
      if(s2!=max) {
          s2 += 1;
      }
      p2[i].style.fontSize = s2+"px"
	  }
	}
function decreaseFontSize() {
   var p = document.getElementsByTagName('body');
   var p1 = document.getElementsByTagName('H4');
   var p2 = 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"
    }
	for(i=0;i<p1.length;i++) {
       if(p1[i].style.fontSize) {
         var s1 = parseInt(p1[i].style.fontSize.replace("px",""));
      } else {
          var s1 = 12;
      }
      if(s1!=min) {
          s1 -= 1;
      }
      p1[i].style.fontSize = s1+"px"
    }
	for(i=0;i<p2.length;i++) {
       if(p2[i].style.fontSize) {
         var s2 = parseInt(p2[i].style.fontSize.replace("px",""));
      } else {
          var s2 = 12;
      }
      if(s2!=min) {
          s2 -= 1;
      }
      p2[i].style.fontSize = s2+"px"
    }
}

	//resolution = screen.width;
    //alert('Your resolution is: ' + resolution);

    function size()
	{
		
        document.getElementById('jsn-page').style.width = '1050px';
		t = document.getElementById('jsn-page').style.width;
		//alert(t);
    }
	
	function dsize()
	{
		
        document.getElementById('jsn-page').style.width = '960px';
		t = document.getElementById('jsn-page').style.width;
		//alert(t);
    }
    

