// do not edit this file, it is created by the theme, any edits will be lost

	function p2_toggle_contactform(delay) {
	if (delay == undefined) delay = 500;
	jQuery('#contact-form').slideToggle(delay);
}		
		
	
sfHover = function() {
	var sfEls = document.getElementById("topnav").getElementsByTagName("LI");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			this.className+=" sfhover";
		}
		sfEls[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
		}
	}
}
if (window.attachEvent) window.attachEvent("onload", sfHover); // for MSIE only


jQuery(document).ready(function(){
		
		jQuery(".comments-count").click(function(){
		$thisclick = jQuery(this);
		var comments_id = "#"+$thisclick.parents(".entry-comments").attr("id");
		if ( jQuery(comments_id+" p.comment").size() > 0 ) {
			jQuery(comments_id).toggleClass('comments-count-active');
			jQuery(comments_id+" .comments-body").slideToggle(400);
		}
	});			
		
	
		
	jQuery('#p2-nav-contact').click(function(){
		p2_toggle_contactform(500);
	});	

	var hash = window.location.hash.substr(1);
	if ( hash === 'contact-form' ) {
		p2_toggle_contactform(0);
	}
	
	// handle contact form submission messages
	if ( hash === 'error' ) {
		jQuery("#p2-contact-error")
			.css('display', 'block')
			.animate({opacity: 1.0}, 3500, function(){p2_toggle_contactform(300)})
			.fadeTo(500, 0)
			.slideUp(300);
	}
	if ( hash === 'success' ) {
		jQuery("#p2-contact-success")
			.css('display', 'block')
			.animate({opacity: 1.0}, 3500)
			.fadeTo(500, 0)
			.slideUp(300);
	}
	
	jQuery('a[@href*=#contact-form]').click(function(){
		if (jQuery("#contact-form form").size() == 0 ) {
			p2_toggle_contactform();
		} else {
			jQuery('#contact-form').slideDown(500);
		}
	});
		
	jQuery('#topnav li ul a').attr('title', '');
	
	// add arrow to dropdown with nested menu
	jQuery('#topnav li ul li:has(ul)').each(function(){
		$link = jQuery(this).children('a');
		linktext = $link.html();
		$link.html(linktext+" &raquo;");
	});
	// add underline to parent while child is being viewed
	jQuery('#topnav li ul li ul').hover(function(){
		jQuery(this).parent().children('a').css('text-decoration', 'underline');
	},function(){
		jQuery(this).parent().children('a').css('text-decoration', 'none');
	});
	
		if (!jQuery.browser.msie) {	
		jQuery('#topnav li ul').css('opacity', 0.93);
	}
	if (jQuery.browser.msie) {
		if (jQuery('#topnav li ul li:has(ul)').size() == 0) {
			jQuery('#topnav li ul').css('opacity', 0.93);
		}
	}
		
	jQuery('.entry-post:last').css('border', 'none');
	var padding = jQuery('body.single .entry-content').css('padding-bottom');
	jQuery('.entry-post:last').css('padding-bottom', '0');
	jQuery('.entry-post:last').css('background-image', 'none');
		jQuery('#statcounter-wrapper br').remove();	
	jQuery('a#hidden-bio').click(function(){
		jQuery('#bio-inner').css('background', 'none'); 
		jQuery('#bio').slideToggle(350,function(){
			jQuery('#bio-outer').css('display', 'block');
			jQuery('#biocolumns').css('display', 'inline');
			jQuery('.biocolumn').css('display', 'block');
			jQuery('#bio-inner').css('background', 'url(http://photoaura.net/blog/wp-content/themes/prophoto2/images/bio-pageturn-alt.jpg) no-repeat top left');
		});
	});	
			
		
	
			 
});

// flash header area
var params = {
	FlashVars: "path2xml=http://photoaura.net/blog/wp-content/uploads/p2/images.xml?13971",
	bgcolor: "#121212",
	wmode: "opaque"
}
swfobject.embedSWF("http://photoaura.net/blog/wp-content/themes/prophoto2/flash/flashheader.swf", "flash-header", "980", "350", "7.0.0", "http://photoaura.net/blog/wp-content/themes/prophoto2/flash/expressinstall.swf", false, params);
function randombiopics() {
	var biopics=new Array()
	
	biopics[0]='<img id="biopic" src="http://photoaura.net/blog/wp-content/uploads/p2/biopic1_1239914252.jpg" width="167" height="250" alt="PHOTOAURA BLOG | Wedding Event Photographer Kelantan Terengganu Pahang Kuala Lumpur Photographer Jurufoto Perkahwinan Foto Kahwin, Foto Perkahwinan, Jurufoto Kahwin, Gambar Kahwin, Khidmat Fotografi, Fotografi Perkahwinan, Khidmat Jurufoto, Jurugambar Kahwin, Jurugambar Perkahwinan, Perkahwinan Malaysia, Perkhidmatan Jurufoto, Perkhidmatan Jurugambar, Gambar Kahwin, Perkahwinan Melayu, Fotografi Perkahwinan, Fotografi Kahwin, fotografi Profesional, Wedding Photography, Wedding Photographer, Candid Photographer, Perkahwinan Melayu, Foto Pengantin, Pengantin Kahwin, Gambar Perkahwinan, Foto Kawin Fotokawin, KL Photographer, Terengganu Photographer, Kelantan Photographer, Pahang Photographer, chinese wedding, india wedding, event management, event photography, jurufoto event, model fotography, food photography, fashion photography, white room, studio white room, photo editing, photoshop editing, custom album wedding, wedding custom album, photoaura, fineart, kelantan photographer, photographer kelantan, malaysia photographer, photographer malaysia bio picture" />'

	biopics[1]='<img id="biopic" src="http://photoaura.net/blog/wp-content/uploads/p2/biopic2_1234893854.jpg" width="167" height="250" alt="PHOTOAURA BLOG | Wedding Event Photographer Kelantan Terengganu Pahang Kuala Lumpur Photographer Jurufoto Perkahwinan Foto Kahwin, Foto Perkahwinan, Jurufoto Kahwin, Gambar Kahwin, Khidmat Fotografi, Fotografi Perkahwinan, Khidmat Jurufoto, Jurugambar Kahwin, Jurugambar Perkahwinan, Perkahwinan Malaysia, Perkhidmatan Jurufoto, Perkhidmatan Jurugambar, Gambar Kahwin, Perkahwinan Melayu, Fotografi Perkahwinan, Fotografi Kahwin, fotografi Profesional, Wedding Photography, Wedding Photographer, Candid Photographer, Perkahwinan Melayu, Foto Pengantin, Pengantin Kahwin, Gambar Perkahwinan, Foto Kawin Fotokawin, KL Photographer, Terengganu Photographer, Kelantan Photographer, Pahang Photographer, chinese wedding, india wedding, event management, event photography, jurufoto event, model fotography, food photography, fashion photography, white room, studio white room, photo editing, photoshop editing, custom album wedding, wedding custom album, photoaura, fineart, kelantan photographer, photographer kelantan, malaysia photographer, photographer malaysia bio picture" />'

	var biopic = Math.floor(Math.random()*(biopics.length));
	document.write(biopics[biopic]);
}	


