// JavaScript Document

/*
Date: Oct 25, 2007
Author: Walter

Reason: This smgeneral function will write a encryped email to the users screen.

Input: 	- User: which is the email user name
		- Host: which is the host domain of the email
		- Domain: which is the country / dot com part of the email.
		
**** Emails can be generated via the webpage http://www.zapyon.de/spam-me-not/
*/

function smgeneral(user, host, domain, cssclass) 
{
	emstring = 'm' + 'a' + 'i' + 'lto'+ ':' + user + '@' + host + '.' + domain;
	emstring = '<a class="' + cssclass + '" href="' + emstring + '">' + user + '@' + host + '.' + domain + '</a>';

	document.write(emstring);
}


matchHeight=function(){ 

     var divs, contDivs, maxHeight, divHeight, d; 

     divs=document.getElementsByTagName('div');     // get all <div> elements in the document 

     contDivs=[]; 

     maxHeight=0;   // initialize maximum height value 
    
    // iterate over all <div> elements in the document 
     for (var i=0; i < divs.length; i++)
     { 

          // make collection with <div> elements with class attribute 'container' 
          if(/\bcontainer\b/.test(divs[i].className)){ 

                d = divs[i];

                contDivs[contDivs.length]=d; 

                if (d.offsetHeight) // determine height for <div> element 
                { 
                     divHeight=d.offsetHeight; 
                } 

                else if(d.style.pixelHeight)
                { 
                     divHeight=d.style.pixelHeight; 
                } 

                // calculate maximum height 
                maxHeight=Math.max(maxHeight,divHeight); 
          } 
     } 
     
     for(var i=0;i<contDivs.length;i++)
     { 
          contDivs[i].style.height = maxHeight + 'px'; // assign maximum height value                                               // to all of container <div> elements 
     } 

} 


// execute function when page loads 
window.onload=function()
{ 
     if(document.getElementsByTagName)
     { 
          matchHeight(); 
     } 
}