/**
 * specific javascript functionality for Examples
 * 
 */ 

$(document).ready(function() {
	// set up observers
	// frontend section
$("body").css("overflow", "auto");
	
	$('.aHidden').colorbox({
		speed:500,
		title:true,
		opacity:0.5, 
		preloading:true	});
	$('.aThumb').colorbox({
		speed:500,
		title:true,
		opacity:0.5, 
		preloading:true	});	
	$('#tabs').tabs();
	$('.aCodeview').colorbox({
		iframe:true, 
		innerWidth:"95%", 
		innerHeight:"95%",
		speed:500,
		title:true,
		opacity:0.5, 
		preloading:true
		
	});

	$('.aSiteview').colorbox({
		iframe:true, 
		innerWidth:"95%", 
		innerHeight:"95%",
		speed:500,
		title:true,
		opacity:0.5, 
		preloading:true
	});
	$('.reviewButton').click(function(event) {
		var id = $(this).attr('id').split('-')[1];
		var rbid = '#reviewBox-'+ id;
		$(rbid).fadeIn();
	});
	$('.reviewBoxClose').click(function(event) {
		event.preventDefault();
		event.stopPropagation();
		$(this).parents('div.reviewBox').fadeOut();
	});
	
});
$(document).bind('cbox_load', function(){
	$("body").css("overflow", "hidden");
});
$(document).bind('cbox_closed', function(){
	$("body").css("overflow", "auto");
});
//$(function() {
//	$( "#tabs" ).tabs();
//});

