$(document).ready(function(){

  $('#sub_more').click(function(){
      $('.sub1').fadeOut(function(){
          $('.sub2').fadeIn();
      });
		  $(this).hide();
      $('#sub_next').show();
	}); 
	
	$('#sub_next').click(function(){
      $('.sub2').fadeOut(function(){
          $('.sub1').fadeIn();
      });
      $(this).hide();
      $('#sub_more').show();
  });
  
  $('#awards_left').html(get_description(1));

  $('#link_contact').click(function(){
	    $('#big_pic').fadeOut(function(){
		  $('#contact_pane').show("slide");	
	    });	
	});
  
  $('#link_contact').css('cursor','pointer');
  
	$('form').submit(function(){
	   $.ajax({
		  type: 'POST',
		  url: 'http://www.archalli.com/email.asp',
		  data: {name:$('#name').val(),email:$('#email').val(),phone:$('#phone').val(),message:$('#message').val()},
		  success: success,
		  dataType: dataType
		});	
		return false;
	});
  
  if ($('.awards_right tr').length) { // conditional include otherwise fails
      $('.awards_right tr').hoverIntent(function(){
        var ctr = $(this).attr('rel');
        $(this).css('cursor','pointer');
		    $(this).css('background','#c3ccc0');
        $('#awards_left').html(get_description(ctr)).show("slide",{direction:"down"},400);
    },function(){$(this).css('background','transparent');});
  }
  
}); // end of doc ready
/*  
	function get_description(ctr){
		var desc_array=new Array();
		desc_array[1] = "<table width='100%'><tr><td>project name:</td><td>\"The Birches\"</td></tr><tr><td>project location:</td><td>Bryn Mawr, Pennsylvania</td></tr><tr><td>date:</td><td>1987</td></tr><tr><td>award for:</td><td>Single Family Development Design</td></tr><tr><td>award by:</td><td>Bates Memorial Planning Award Delaware County, PA</td></tr><tr><td>project description:</td><td>Upscale Sinle family Development</td></tr><tr><td>publication:</td><td>N/A</td></tr></table>";
		desc_array[2] = "<table width='100%'><tr><td>project name:</td><td>The Devereux Foundation Leo Kanner Learning Center</td></tr><tr><td>project location:</td><td>West Chester, Pennsylvania</td></tr><tr><td>date:</td><td>November 1992</td></tr><tr><td>award for:</td><td>Award - Winning and Other Oustanding Buildings</td></tr><tr><td>award by:</td><td>American School and University</td></tr><tr><td>project description:</td><td>2 story brick and educational and clinical building</td></tr><tr><td>publication:</td><td>American School & University Architectural Portfolio</td></tr></table>";
		desc_array[3] = "<table width='100%'><tr><td>project name:</td><td>The Independence School</td></tr><tr><td>project location:</td><td>Wilmington, Delaware</td></tr><tr><td>date:</td><td>November 1994</td></tr><tr><td>award for:</td><td>Award - Winning and Other Oustanding Buildings, Middle School</td></tr><tr><td>award by:</td><td>American School and University</td></tr><tr><td>project description:</td><td>Addition and Renovation to the Independence School</td></tr><tr><td>publication:</td><td>American School & University Architectural Portfolio</td></tr></table>";
		desc_array[4] = "<table width='100%'><tr><td>project name:</td><td>\"The Coop\"</td></tr><tr><td>project location:</td><td>Home of Tom and Marna Whittington, Wilmington, DE</td></tr><tr><td>date:</td><td>1998</td></tr><tr><td>project description:</td><td>Renovation of c.1930 chicken coop into office and family gathering space</td></tr><tr><td>featured at:</td><td>Delaware Center for Contemporary Atrs 1998 Design Tour</td></tr><tr><td>publication:</td><td></td></tr></table>";
		desc_array[5] = "<table width='100%'><tr><td>project name:</td><td>\"The Coop\"</td></tr><tr><td>project location:</td><td>Home of Tom and Marna Whittington, Wilmington, DE</td></tr><tr><td>date:</td><td>1998</td></tr><tr><td>award:</td><td>Name of award</td></tr><tr><td>award for:</td><td>Award for interior Detailing</td></tr><tr><td>award by:</td><td>Associated Builders and Contractors, Inc. of Delaware</td></tr><tr><td>project description:</td><td>Renovation of c.1930 chicken coop into office and family gathering space</td></tr><tr><td>publication:</td><td></td></tr></table>";
		desc_array[6] = "<table width='100%'><tr><td>project name:</td><td>Rathalla Hall - Rosemont College</td></tr><tr><td>project location:</td><td>Rosemont, Pennsylvania</td></tr><tr><td>date:</td><td>2000</td></tr><tr><td>award:</td><td>Merit Construction Award of Excellence</td></tr><tr><td>award for:</td><td>Best Restoration/renovation Project over $2 million</td></tr><tr><td>award by:</td><td>Associated Builders and Contractors, Southeast Pensylvania Chapter</td></tr><tr><td>project description:</td><td>Renovation and restoration of Rathalla Hall 18,000 square foot mansion, 1891 French Style Chateau whiskey baron residence for the college's admission, public relation and alumni departments</td></tr><tr><td>general contractor:</td><td>Pancoast & Clifford, Inc.</td></tr><tr><td>publication:</td><td></td></tr></table>";
		desc_array[7] = "<table width='100%'><tr><td>project name:</td><td>The Vault</td></tr><tr><td>project location:</td><td>Wilmington, Delaware</td></tr><tr><td>date:</td><td>2000</td></tr><tr><td>award:</td><td>First Place Award/2000</td></tr><tr><td>award for:</td><td>Hospitality projects over 3,000 sq. ft.</td></tr><tr><td>award by:</td><td>American Society of Interior Designers</td></tr><tr><td>project description:</td><td></td></tr><tr><td>general contractor:</td><td>Louise Cohen, ASID</td></tr><tr><td>publication in:</td><td></td></tr></table>";
		desc_array[8] = "<table width='100%'><tr><td>project name:</td><td>Rathalla Hall - Rosemont College</td></tr><tr><td>project location:</td><td>Rosemont, Pennsylvania</td></tr><tr><td>date:</td><td>August 2001</td></tr><tr><td>award:</td><td>Collegiate Citation for Outstanding Design</td></tr><tr><td>award for:</td><td>Outstanding Design at Rathalla Hall, Rosemont College in Rosemont, PA</td></tr><tr><td>award by:</td><td>Associated Builders and Contractors, Southeast Pensylvania Chapter</td></tr><tr><td>project description:</td><td>Renovation and restoration of Rathalla Hall 18,000 square foot mansion, 1891 French Style Chateau whiskey baron residence for the college's admission, public relation and alumni departments</td></tr><tr><td>publication:</td><td>American School & University Architectural Portfolio</td></tr></table>";
		desc_array[9] = "<table width='100%'><tr><td>project name:</td><td>Front Gate Townhouses</td></tr><tr><td>project location:</td><td></td></tr><tr><td>date:</td><td>2000</td></tr><tr><td>award:</td><td>Pyramid Award</td></tr><tr><td>award for:</td><td>\"Best Townhouse Project over $200,000\"</td></tr><tr><td>award by:</td><td>Home Builders of Delaware</td></tr><tr><td>project description:</td><td></td></tr><tr><td>publication:</td><td></td></tr></table>";
		desc_array[10] = "<table width='100%'><tr><td>project name:</td><td>Front Gate Townhouses</td></tr><tr><td>project location:</td><td></td></tr><tr><td>date:</td><td>2001</td></tr><tr><td>award:</td><td>Pyramid Award</td></tr><tr><td>award for:</td><td>\"Best Townhouse Project over $200,000\"</td></tr><tr><td>award by:</td><td>Home Builders of Delaware</td></tr><tr><td>project description:</td><td></td></tr><tr><td>publication:</td><td></td></tr></table>";
		desc_array[11] = "<table width='100%'><tr><td>project name:</td><td>Rathalla Hall - Rosemont College</td></tr><tr><td>project location:</td><td>Rosemont, Pennsylvania</td></tr><tr><td>date:</td><td>2002</td></tr><tr><td>award:</td><td>HARB Preservation Award</td></tr><tr><td>recognition for:</td><td>Adaptive Reuse</td></tr><tr><td>recognition by:</td><td>HARB in Lower Merion Township</td></tr><tr><td>project description:</td><td>Renovation and restoration of Rathalla Hall 18,000 square foot mansion, 1891 French Style Chateau whiskey baron residence for the college's admission, public relation and alumni departments</td></tr><tr><td>publication:</td><td></td></tr></table>";
		desc_array[12] = "<table width='100%'><tr><td>project name:</td><td>Valley Central Veterinary Hospital</td></tr><tr><td>project location:</td><td>Whitehall, Pennsylvania</td></tr><tr><td>date:</td><td>2002</td></tr><tr><td>award:</td><td>Eastern Pennsylvania ABC Award of Excellence</td></tr><tr><td>award for:</td><td>\"Commercial Project under $2,000,000\"</td></tr><tr><td>award by:</td><td>Associated Builders and Contractors, Eastern Pennsylvania Chapter</td></tr><tr><td>project description:</td><td>9,600 square foot, 2 story addition and total renovation of existing clinic</td></tr><tr><td>builder:</td><td>Ondra - Huyett, Associates, Inc.</td></tr><tr><td>publication:</td><td></td></tr></table>";
		desc_array[13] = "<table width='100%'><tr><td>project name:</td><td>Soffer Residence</td></tr><tr><td>project location:</td><td>Bryn Mawr, Pennsylvania</td></tr><tr><td>date:</td><td>2002</td></tr><tr><td>award:</td><td>Winner, The Main Line Builders Association Award</td></tr><tr><td>award for:</td><td>\"Single Family Home Between $1,500,000 and $3,000,000\"</td></tr><tr><td>award by:</td><td>Main Line Builders Association</td></tr><tr><td>project description:</td><td></td></tr><tr><td>builder:</td><td>E.B mahoney Builders</td></tr><tr><td>publication:</td><td></td></tr></table>";
		desc_array[14] = "<table width='100%'><tr><td>project name:</td><td>Richboro Veterinary Center</td></tr><tr><td>project location:</td><td>Richboro, Pennsylvania</td></tr><tr><td>date:</td><td>2002</td></tr><tr><td>award:</td><td>Merit Construction Award</td></tr><tr><td>award for:</td><td>\"Best Commercial Project under $3,000,000\"</td></tr><tr><td>award by:</td><td>Associated Builders and Contractors</td></tr><tr><td>project description:</td><td>9,400 square foot, 2 story new facility</td></tr><tr><td>general contractor:</td><td>C. Raymond Davis, General Contractor</td></tr><tr><td>publication:</td><td></td></tr></table>";
		desc_array[15] = "<table width='100%'><tr><td>project name:</td><td>Doyle Residence</td></tr><tr><td>project location:</td><td>Bridle Brook Development lot 5, Delaware County, PA</td></tr><tr><td>date:</td><td>2003</td></tr><tr><td>award:</td><td>Winner, Pyramid Award</td></tr><tr><td>award for:</td><td>\"Best Custom Residence over $900,000\"</td></tr><tr><td>award by:</td><td>Home Builders Association of Chester and Delaware Counties</td></tr><tr><td>project description:</td><td>Single family classic revival style residence</td></tr><tr><td>general contractor:</td><td>Michael J. Murphy Construction, Inc.</td></tr><tr><td>publication:</td><td></td></tr></table>";
		desc_array[16] = "<table width='100%'><tr><td>project name:</td><td>The Village of Rocky Run</td></tr><tr><td>project location:</td><td>Wilmington, Delaware</td></tr><tr><td>date:</td><td>2004</td></tr><tr><td>award:</td><td>Best Active Adult Home Design</td></tr><tr><td>award for:</td><td>2004 Best of Seniors Housing Design</td></tr><tr><td>award by:</td><td>National Association of Home Builders - Senior Housing Council</td></tr><tr><td>project description:</td><td></td></tr><tr><td>publication:</td><td>Benchmark Builders win NAHB Seniors housing council 2004 Best of Seniors housing design award http://www.benchmarkbuilders.com/news.htm</td></tr></table>";
		desc_array[17] = "<table width='100%'><tr><td>project name:</td><td>Lot One</td></tr><tr><td>project location:</td><td>Bryn Mawr, Pennsylvania</td></tr><tr><td>date:</td><td>2006</td></tr><tr><td>award:</td><td>Pinnacle Award</td></tr><tr><td>award for:</td><td>Best Total Renovation on a Historic Property</td></tr><tr><td>award by:</td><td>Home Builders Association of Chester and Delawware Counties</td></tr><tr><td>project description:</td><td>Family and breakfast room addition with game room below addition to 1920s's brick and limestone English manor style home</td></tr><tr><td>publication in:</td><td>Home Bulders Association of Chester and Delaware Counties 2006 fall quarter magazine</td></tr></table>";
		desc_array[18] = "<table width='100%'><tr><td>project name:</td><td>The Independence School</td></tr><tr><td>project location:</td><td>Wilmington, Delaware</td></tr><tr><td>date:</td><td>November 2006</td></tr><tr><td>award:</td><td>Elementary Schools Citation Award</td></tr><tr><td>award by:</td><td>American School and University</td></tr><tr><td>project description:</td><td>Addition and Renovation to the Independence School</td></tr><tr><td>publication:</td><td>American School & University Architectural Portfolio</td></tr></table>";
		return desc_array[ctr];
	};
   

  */
