

/**
 * HIDE EMAIL SCRIPT
 *
 *     <script type="text/javascript">myEmail("Contact Name", "email", "domain.com");</script>
	   <script type="text/javascript">writeEmail("email", "email", "domain.com");</script>
 *
 * @param string
 * @param string
 * @param string
 */
function myEmail(contact, email, emailHost) {
  document.write("<a href=" + "&#109a&#105l" + "&#116&#111:" + email + "@" + emailHost+ ">" + contact+"</a>");
}

function writeEmail(contact, email, emailHost) {
  document.write("<a href=" + "&#109a&#105l" + "&#116&#111:" + email + "@" + emailHost+ ">" + contact + "@" + emailHost+"</a>");
}


/** JQUERY CYCLE SCRIPT **/

$(document).ready(function(){
			$('#photobox').cycle({
				fx: 'fade',
				speed: 2000,
				timeout: 7000
			});
		}); 
		
		
		


function showHide(targetName) {
                if( document.getElementById ) { // NS6+
                    target = document.getElementById(targetName);
                } else if( document.all ) { // IE4+
                    target = document.all[targetName];
                }
                
                if( target ) {
                    if( target.style.display == "none" ) {
                        target.style.display = "inline";
                    } else {
                        target.style.display = "none";
                    }
                }
            }
            
function tabSwitch(active, number, tab_prefix, content_prefix) {

	for (var i=1; i < number+1; i++) {
	  document.getElementById(content_prefix+i).style.display = 'none';
	  document.getElementById(tab_prefix+i).className = '';
	}
	document.getElementById(content_prefix+active).style.display = 'block';
	document.getElementById(tab_prefix+active).className = 'active';	

}

/* SHOW HIDE TOGGLE *********************************************************

	USAGE
	
	<a onclick="toggle_visibility('div_to_hide');" href="#">Open Link</a>
	
*/

function toggle_visibility(id) {
       var e = document.getElementById(id);
       if(e.style.display == 'block')
          e.style.display = 'none';
       else
          e.style.display = 'block';
    }
	
/* my custom toggle jquery */
function toggle(){
$("ul.submenu").slideToggle("fast");
}
	
		

/* INPUT BLUR AND FOCUS SCRIPT */
	
var addEvent = function(elem, type, fn) { // Simple utility for cross-browser event handling
    if (elem.addEventListener) elem.addEventListener(type, fn, false);
    else if (elem.attachEvent) elem.attachEvent('on' + type, fn);
},
textField = document.getElementById('fullnameInput'),
placeholder = 'Your Name'; // The placeholder text

textField = document.getElementById('emailInput'),
placeholder = 'Your Email'; // The placeholder text

addEvent(textField, 'focus', function() {
    if (this.value === placeholder) this.value = '';
});
addEvent(textField, 'blur', function() {
    if (this.value === '') this.value = placeholder;
});




/* BASIC POP UP WINDOW */

function player(url, name, props) {window.open(url, name, props);}























