$(document).ready(function() {
			
	
			
	$("#tabs-phone").tabs({ fx: { opacity: 'toggle' }, selected: 0 }).tabs('rotate', 3400); 
	$("#pic-tabs-home").tabs({ fx: { opacity: 'toggle' }, selected: 0 }).tabs('rotate', 7000); 
	
	// Form Input
	$('.change').focus(function() {
	if (this.value == this.defaultValue) {
	this.value = ''; }});
	$('.change').blur(function() {
	if (this.value == '') {
	this.value = this.defaultValue; }});
	
    $("#tabs").tabs();
	
	/* This is basic - uses default settings */
	$(".fancybox").fancybox({
		'titleShow'		: 	false
	});

	if(typeof($.fn.treeview) == 'function') {
		$(".side-menu-list").treeview({
			persist: "location",
			collapsed: true,
			unique: true,
			animated: true,
			speed: 90
		});
		$('.side-menu-list li.selected').parent('ul').show().parent('li').removeClass('expandable').addClass('collapsable');
	}
	
	$("a.video").click(function() {
                 $.fancybox({
                  'padding'             : 0,
                  'autoScale'   : false,
                  'transitionIn'        : 'none',
                  'transitionOut'       : 'none',
                  'title'               : this.title,
                  'width'               : 680,
                  'height'              : 495,
                  'href'                : this.href.replace(new RegExp("watch\\?v=", "i"), 'v/'),
                  'type'                : 'swf',    // <--add a comma here
                  'swf'                 : {'allowfullscreen':'true'} // <-- flashvars here
                  });
                 return false;

            }); 
	
});

