// JavaScript Document
// calculateFn... just for the hashtags
function calculateFn (image, fishType, yourWeightLbs, fishSizeOz) {
	var fishName = nutrArr[fishType][0];
		var RecipeURL = (nutrArr[fishType][18]);
				
		var Omega = ((parseFloat(nutrArr[fishType][1] * fishSizeOz)) + (parseFloat(nutrArr[fishType][2] * fishSizeOz))).toFixed(2);
		var OmegaRDI = (nutrArr[fishType][8] * fishSizeOz).toFixed(1);
		var Protein = (nutrArr[fishType][3] * fishSizeOz).toFixed(2);
		var ProteinRDI = (nutrArr[fishType][9] * fishSizeOz).toFixed(1);
		var B12 = (nutrArr[fishType][4] * fishSizeOz).toFixed(2);
		var B12RDI = (nutrArr[fishType][10] * fishSizeOz).toFixed(1);
		var Potassium = (nutrArr[fishType][5] * fishSizeOz).toFixed(2);
		var PotassiumRDI = (nutrArr[fishType][11] * fishSizeOz).toFixed(1);
		var Selenium = (nutrArr[fishType][6] * fishSizeOz).toFixed(2);
		var SeleniumRDI = (nutrArr[fishType][12] * fishSizeOz).toFixed(1);
		var Iron = (nutrArr[fishType][7] * fishSizeOz).toFixed(2);
		var IronRDI = (nutrArr[fishType][13] * fishSizeOz).toFixed(1);
		var Prep = (nutrArr[fishType][14]);
		var Calories = (nutrArr[fishType][15] * fishSizeOz).toFixed(0);
		var Fat = (nutrArr[fishType][16] * fishSizeOz).toFixed(2);
		var Sodium = (nutrArr[fishType][17] * fishSizeOz).toFixed(2);
		var RecipeURL =  (nutrArr[fishType][18]);
		var Merc = mercArr[fishType][1];
		
		if (Merc == 0) {
			var MercOz = 0;
			var MercNote = 
			"The level of detectable mercury is too low to pose any hypothetical health risk, regardless of weekly intake. You may eat an unlimited amount without adverse health effects from mercury.";
		} else {
			var MercOz = parseInt((yourWeightLbs * 0.112 ) / Merc);
			var MercNote = "";
		}
		var MercLbs = (MercOz/16).toFixed(2);
		
		$('#portionVar').html(portionText[fishSizeOz]);
		$('#OmegaVar').html(Omega);
		$('#OmegaRDIVar').html(OmegaRDI);
		$('#ProteinVar').html(Protein);
		$('#ProteinRDIVar').html(ProteinRDI);
		$('#B12Var').html(B12);
		$('#B12RDIVar').html(B12RDI);
		$('#PotassiumVar').html(Potassium);
		$('#PotassiumRDIVar').html(PotassiumRDI);
		$('#SeleniumVar').html(Selenium);
		$('#SeleniumRDIVar').html(SeleniumRDI);
		$('#IronVar').html(Iron);
		$('#IronRDIVar').html(IronRDI);
		$('#FatVar').html(Fat);
		$('#SodiumVar').html(Sodium);
		$('#CaloriesVar').html(Calories);
		$('#PrepVar').html(Prep);
				
	
		$('.fishName').html(fishName);
		$('#fish-thumb-wrap').fadeOut(150);	
		$('#full-photo').html('<img src="./images/full/' + image + '.jpg"/><a id="recipe" href="javascript;:" target="_blank">Recipes</a>');
		$('#recipe').attr("href", RecipeURL);		
		$('#full-size').fadeIn(150);
		$('#weight-oz-selectors input, #weight-oz-selectors select, #row-two, #pick-a-fish').hide();
		$('#lbs').html('<span style="color: #3FA9D9;">150 lbs</span>');
		$('#weight-oz-selectors').append('<span id="oz" style="color: #3FA9D9;">6 oz. (Lunch)</span>');
		
		$('#weight-oz-selectors').css('width', '608px').css('display', 'inline').css('clear', 'none').removeClass("clearfix"); 
		$('#pregnant').css('margin', '0').css('top', '-18px');
		
		$('#reset').html('More Fish?').css('background', 'none').css('text-indent', '0').css('padding-top', '12px').css('height', '28px').click(function() {$(this).attr('href', 'http://howmuchfish.com');});
			
}

