	// author :: Developer1  FF  05/2010 v.1
	
	function loadContent(id) { // AJAX CALLS
	 	  
	if (id==1) {
	  	selected_state(1);
		$('#mainAreaInternal').load('http://www.famefoundry.com/wp-content/themes/Platinum/include/portfolio1.html', function() {
			$('#wrapper1').fadeIn( 'slow', function() {
			
				blah();
				//backbutton(); // hides the backbutton
				//scroll();
				});		
		 });

	 }  // if
	
	if (id==2) {
		selected_state(2);	     
     	$('#mainAreaInternal').load('http://www.famefoundry.com/wp-content/themes/Platinum/include/portfolio2.html', function() {
				$('#wrapper1').fadeIn( 'slow', function() {
			
				blah();
				//backbutton(); // hides the backbutton
				//scroll();
			});
		});

	 }  // if
	 	
	if (id==3) {
		selected_state(3);	     
     	$('#mainAreaInternal').load('http://www.famefoundry.com/wp-content/themes/Platinum/include/portfolio3.html', function() {
				$('#wrapper1').fadeIn( 'slow', function() {
			
				blah();
				//backbutton(); // hides the backbutton
				//scroll();
			});
		});

	 }  // if
	 		 	
	 	
	if (id==4) {
		selected_state(4);	     
     	$('#mainAreaInternal').load('http://www.famefoundry.com/wp-content/themes/Platinum/include/portfolio4.html', function() {
				$('#wrapper1').fadeIn( 'slow', function() {
			
				blah();
				//backbutton(); // hides the backbutton
				//scroll();
			});
		});

	 }  // if	 	
	 	
	 	
	 	
	 	
	 	
	 	
	} // eof
	
	
	function scroll() {


	// execute your scripts when DOM is ready. this is a good habit
$(function() {		
		$(".scrollable").scrollable({ vertical: true, size:1});		
	// initialize scrollable with mousewheel support
	//$(".scrollable").scrollable({ vertical: true, size:1 });	
	
});




		//$(".scrollable").scrollable({ vertical: true, size:1});	
		//$(".scrollable").scrollable({ vertical: true, mousewheel: true });	

		//$(".scrollable").scrollable({
		//	vertical:true, 
		//	size: 1
		//});	
		// .mousewheel() can be added if needed
	}


	function selected_state(el) {
	// RESET
	 $('li.webdev_selected').removeClass('webdev_selected a').addClass('webdev');
	 $('li.traffic_selected').removeClass('traffic_selected a').addClass('traffic');
	 $('li.pr_selected').removeClass('pr_selected a').addClass('pr');
 	 $('li.creative_selected').removeClass('creative_selected a').addClass('creative');

	
		if (el === 1) {
			$('li.webdev').removeClass('webdev').addClass('webdev_selected a');
		}
		
		if (el == 2) {
			$('li.traffic').removeClass('traffic').addClass('traffic_selected a');
		}
	
		if (el ==3) {
			$('li.pr').removeClass('pr').addClass('pr_selected a');
		}
		
		if (el ==4) {
			$('li.creative').removeClass('creative').addClass('creative_selected a');
		}
	
	
	}  // END SELECTED STATE



	function blah() {
			
			$(document).ready(function(){
					$(".gallery a[rel^='prettyPhoto']").prettyPhoto({theme:'light_rounded', modal:'true',autoplay: true });
				});
							

		}	


