<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-8238555369142194186</id><updated>2012-01-01T14:12:39.694-06:00</updated><title type='text'>Trim Up Tuesday</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>15</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-3146266936098604131</id><published>2008-08-26T07:33:00.001-05:00</published><updated>2008-08-26T07:33:38.727-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.11)  08/26/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;br /&gt;&lt;br /&gt;
Trim Up Tuesday isn't just for those who are trying to lose weight.  Anyone who wants to focus on better nutrition and/or fitness should give it a try!  We're not picky here at Trim Up Tuesday, so pick any aspect you like and ignore those you don't.  And as always, if you don't comment, I can't come check out your Trim Up Tuesday blog, so please don't forget to comment!

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Basic Info&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;b&gt;New For This Version (1.5)&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;No new items!  Gimme some FEEDBACK!  (please?)
&lt;/ul&gt;

&lt;br /&gt;
&lt;b&gt;Don't forget to leave a comment!&lt;/b&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var weightStart = document.getElementById('weightStart').value;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var numTimes = document.getElementById('numTimes').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightAfter) &amp;&amp; weightFormat.test(weightStart)){
	blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
	blogString += "&lt;ul&gt;";
  weightDesc = getWeightDiffOverAll(weightAfter, weightStart);
  blogString += "&lt;li /&gt; "+weightDesc;
  weightTopics = true;
}//end overall weight tracking
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
    if(!weightTopics){
    blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
    blogString += "&lt;ul&gt;";
    }else{
      blogString += "&lt;br /&gt;";
    }
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end test for ideal weight vs. today's weight

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(twoDigitFormat.test(numTimes)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
blogString += "&lt;li /&gt; I worked out "+numTimes+" time(s) this week.";
exerciseTopics = true;
}

if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

function getWeightDiffOverAll(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I have not lost any weight yet.";
}else if(weightDiff &gt;= 0){
   weightDesc = "I have lost "+weightDiff+" pound(s) since I started!";
}else{
   weightDesc = "I have gained "+Math.abs(weightDiff)+" pound(s) since I started.";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Beginning Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightStart" id="weightStart" size="5" maxlength="5" 
title="Weight when you first started exercise regimine." /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Exercised:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="numTimes" id="numTimes" size="1" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm still looking for ideas for the next version.  I'm toying with adding steps per day to tool.  I also need to somehow get the picture automatically added in.
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-3146266936098604131?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/3146266936098604131/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=3146266936098604131&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/3146266936098604131'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/3146266936098604131'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/08/trim-up-tuesday-version-111-08262008.html' title='Trim Up Tuesday (Version 1.11)  08/26/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-7668437989396607177</id><published>2008-08-18T14:41:00.001-05:00</published><updated>2008-08-18T14:41:49.840-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.10)  08/19/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;br /&gt;&lt;br /&gt;
Trim Up Tuesday isn't just for those who are trying to lose weight.  Anyone who wants to focus on better nutrition and/or fitness should give it a try!  We're not picky here at Trim Up Tuesday, so pick any aspect you like and ignore those you don't.  And as always, if you don't comment, I can't come check out your Trim Up Tuesday blog, so please don't forget to comment!

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Basic Info&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;b&gt;New For This Version (1.5)&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;No new items!  Gimme some FEEDBACK!  (please?)
&lt;/ul&gt;

&lt;br /&gt;
&lt;b&gt;Don't forget to leave a comment!&lt;/b&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var weightStart = document.getElementById('weightStart').value;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var numTimes = document.getElementById('numTimes').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightAfter) &amp;&amp; weightFormat.test(weightStart)){
	blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
	blogString += "&lt;ul&gt;";
  weightDesc = getWeightDiffOverAll(weightAfter, weightStart);
  blogString += "&lt;li /&gt; "+weightDesc;
  weightTopics = true;
}//end overall weight tracking
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
    if(!weightTopics){
    blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
    blogString += "&lt;ul&gt;";
    }else{
      blogString += "&lt;br /&gt;";
    }
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end test for ideal weight vs. today's weight

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(twoDigitFormat.test(numTimes)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
blogString += "&lt;li /&gt; I worked out "+numTimes+" time(s) this week.";
exerciseTopics = true;
}

if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

function getWeightDiffOverAll(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I have not lost any weight yet.";
}else if(weightDiff &gt;= 0){
   weightDesc = "I have lost "+weightDiff+" pound(s) since I started!";
}else{
   weightDesc = "I have gained "+Math.abs(weightDiff)+" pound(s) since I started.";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Beginning Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightStart" id="weightStart" size="5" maxlength="5" 
title="Weight when you first started exercise regimine." /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Exercised:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="numTimes" id="numTimes" size="1" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm still looking for ideas for the next version.  I'm toying with adding steps per day to tool.  I also need to somehow get the picture automatically added in.
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-7668437989396607177?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/7668437989396607177/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=7668437989396607177&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/7668437989396607177'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/7668437989396607177'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/08/trim-up-tuesday-version-110-08192008_18.html' title='Trim Up Tuesday (Version 1.10)  08/19/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-1983287816126137096</id><published>2008-08-05T09:48:00.001-05:00</published><updated>2008-08-05T09:48:38.757-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.9)  08/05/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;br /&gt;&lt;br /&gt;
Trim Up Tuesday isn't just for those who are trying to lose weight.  Anyone who wants to focus on better nutrition and/or fitness should give it a try!  We're not picky here at Trim Up Tuesday, so pick any aspect you like and ignore those you don't.  And as always, if you don't comment, I can't come check out your Trim Up Tuesday blog, so please don't forget to comment!

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Basic Info&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;b&gt;New For This Version (1.5)&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;No new items!  Gimme some FEEDBACK!  (please?)
&lt;/ul&gt;

&lt;br /&gt;
&lt;b&gt;Don't forget to leave a comment!&lt;/b&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var weightStart = document.getElementById('weightStart').value;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var numTimes = document.getElementById('numTimes').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightAfter) &amp;&amp; weightFormat.test(weightStart)){
	blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
	blogString += "&lt;ul&gt;";
  weightDesc = getWeightDiffOverAll(weightAfter, weightStart);
  blogString += "&lt;li /&gt; "+weightDesc;
  weightTopics = true;
}//end overall weight tracking
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
    if(!weightTopics){
    blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
    blogString += "&lt;ul&gt;";
    }else{
      blogString += "&lt;br /&gt;";
    }
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end test for ideal weight vs. today's weight

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(twoDigitFormat.test(numTimes)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
blogString += "&lt;li /&gt; I worked out "+numTimes+" time(s) this week.";
exerciseTopics = true;
}

if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

function getWeightDiffOverAll(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I have not lost any weight yet.";
}else if(weightDiff &gt;= 0){
   weightDesc = "I have lost "+weightDiff+" pound(s) since I started!";
}else{
   weightDesc = "I have gained "+Math.abs(weightDiff)+" pound(s) since I started.";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Beginning Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightStart" id="weightStart" size="5" maxlength="5" 
title="Weight when you first started exercise regimine." /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Exercised:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="numTimes" id="numTimes" size="1" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm still looking for ideas for the next version.  I'm toying with adding steps per day to tool.  I also need to somehow get the picture automatically added in.
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-1983287816126137096?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/1983287816126137096/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=1983287816126137096&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/1983287816126137096'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/1983287816126137096'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/08/trim-up-tuesday-version-19-08052008.html' title='Trim Up Tuesday (Version 1.9)  08/05/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-5484080042239186381</id><published>2008-07-29T07:51:00.003-05:00</published><updated>2008-07-29T07:54:05.175-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.8)  07/29/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;br /&gt;&lt;br /&gt;
Trim Up Tuesday isn't just for those who are trying to lose weight.  Anyone who wants to focus on better nutrition and/or fitness should give it a try!  We're not picky here at Trim Up Tuesday, so pick any aspect you like and ignore those you don't.  And as always, if you don't comment, I can't come check out your Trim Up Tuesday blog, so please don't forget to comment!

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Basic Info&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;b&gt;New For This Version (1.5)&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;No new items!  Gimme some FEEDBACK!  (please?)
&lt;/ul&gt;

&lt;br /&gt;
&lt;b&gt;Don't forget to leave a comment!&lt;/b&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var weightStart = document.getElementById('weightStart').value;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var numTimes = document.getElementById('numTimes').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightAfter) &amp;&amp; weightFormat.test(weightStart)){
	blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
	blogString += "&lt;ul&gt;";
  weightDesc = getWeightDiffOverAll(weightAfter, weightStart);
  blogString += "&lt;li /&gt; "+weightDesc;
  weightTopics = true;
}//end overall weight tracking
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
    if(!weightTopics){
    blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
    blogString += "&lt;ul&gt;";
    }else{
      blogString += "&lt;br /&gt;";
    }
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end test for ideal weight vs. today's weight

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(twoDigitFormat.test(numTimes)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
blogString += "&lt;li /&gt; I worked out "+numTimes+" time(s) this week.";
exerciseTopics = true;
}

if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

function getWeightDiffOverAll(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I have not lost any weight yet.";
}else if(weightDiff &gt;= 0){
   weightDesc = "I have lost "+weightDiff+" pound(s) since I started!";
}else{
   weightDesc = "I have gained "+Math.abs(weightDiff)+" pound(s) since I started.";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Beginning Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightStart" id="weightStart" size="5" maxlength="5" 
title="Weight when you first started exercise regimine." /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Exercised:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="numTimes" id="numTimes" size="1" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm still looking for ideas for the next version.  I'm toying with adding steps per day to tool.  I also need to somehow get the picture automatically added in.
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-5484080042239186381?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/5484080042239186381/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=5484080042239186381&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/5484080042239186381'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/5484080042239186381'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/07/trim-up-tuesday-version-18-07292008.html' title='Trim Up Tuesday (Version 1.8)  07/29/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-5153207311071527802</id><published>2008-07-22T08:42:00.002-05:00</published><updated>2008-07-29T07:50:49.481-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.7)  07/22/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;br /&gt;&lt;br /&gt;
Happy Tuesday!  Thanks for stopping by, please don't forget to comment!

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Basic Info&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;b&gt;New For This Version (1.5)&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;No new items!  Gimme some FEEDBACK!  (please?)
&lt;/ul&gt;

&lt;br /&gt;
&lt;b&gt;Don't forget to leave a comment!&lt;/b&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var weightStart = document.getElementById('weightStart').value;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var numTimes = document.getElementById('numTimes').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightAfter) &amp;&amp; weightFormat.test(weightStart)){
	blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
	blogString += "&lt;ul&gt;";
  weightDesc = getWeightDiffOverAll(weightAfter, weightStart);
  blogString += "&lt;li /&gt; "+weightDesc;
  weightTopics = true;
}//end overall weight tracking
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
    if(!weightTopics){
    blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
    blogString += "&lt;ul&gt;";
    }else{
      blogString += "&lt;br /&gt;";
    }
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end test for ideal weight vs. today's weight

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(twoDigitFormat.test(numTimes)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
blogString += "&lt;li /&gt; I worked out "+numTimes+" time(s) this week.";
exerciseTopics = true;
}

if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

function getWeightDiffOverAll(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I have not lost any weight yet.";
}else if(weightDiff &gt;= 0){
   weightDesc = "I have lost "+weightDiff+" pound(s) since I started!";
}else{
   weightDesc = "I have gained "+Math.abs(weightDiff)+" pound(s) since I started.";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Beginning Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightStart" id="weightStart" size="5" maxlength="5" 
title="Weight when you first started exercise regimine." /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Exercised:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="numTimes" id="numTimes" size="1" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm still looking for ideas for the next version.  I'm toying with adding steps per day to tool.  I also need to somehow get the picture automatically added in.
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-5153207311071527802?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/5153207311071527802/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=5153207311071527802&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/5153207311071527802'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/5153207311071527802'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/07/trim-up-tuesday-version-16-07222008.html' title='Trim Up Tuesday (Version 1.7)  07/22/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-8058776174038860910</id><published>2008-07-15T07:52:00.002-05:00</published><updated>2008-07-15T07:55:13.014-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.6)  07/15/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;br /&gt;&lt;br /&gt;
Welcome back to Trim Up Tuesday!  Since there's only a couple users right now, I think you already know why we haven't done Trim Up Tuesday in a while.  But it's time now to get back into shape!  

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Basic Info&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;b&gt;New For This Version (1.5)&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;No new items!  Gimme some FEEDBACK!  (please?)
&lt;/ul&gt;

&lt;br /&gt;
&lt;b&gt;Don't forget to leave a comment!&lt;/b&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var weightStart = document.getElementById('weightStart').value;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var numTimes = document.getElementById('numTimes').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightAfter) &amp;&amp; weightFormat.test(weightStart)){
	blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
	blogString += "&lt;ul&gt;";
  weightDesc = getWeightDiffOverAll(weightAfter, weightStart);
  blogString += "&lt;li /&gt; "+weightDesc;
  weightTopics = true;
}//end overall weight tracking
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
    if(!weightTopics){
    blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
    blogString += "&lt;ul&gt;";
    }else{
      blogString += "&lt;br /&gt;";
    }
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end test for ideal weight vs. today's weight

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(twoDigitFormat.test(numTimes)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
blogString += "&lt;li /&gt; I worked out "+numTimes+" time(s) this week.";
exerciseTopics = true;
}

if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

function getWeightDiffOverAll(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I have not lost any weight yet.";
}else if(weightDiff &gt;= 0){
   weightDesc = "I have lost "+weightDiff+" pound(s) since I started!";
}else{
   weightDesc = "I have gained "+Math.abs(weightDiff)+" pound(s) since I started.";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Beginning Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightStart" id="weightStart" size="5" maxlength="5" 
title="Weight when you first started exercise regimine." /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Exercised:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="numTimes" id="numTimes" size="1" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm still looking for ideas for the next version.  I'm toying with adding steps per day to tool.  I also need to somehow get the picture automatically added in.
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-8058776174038860910?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/8058776174038860910/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=8058776174038860910&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/8058776174038860910'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/8058776174038860910'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/07/trim-up-tuesday-version-16-07152008.html' title='Trim Up Tuesday (Version 1.6)  07/15/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-6566531165332129094</id><published>2008-04-29T07:39:00.000-05:00</published><updated>2008-04-29T07:40:19.244-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.5)  04/29/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;b&gt;Basic Info&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;b&gt;New For This Version (1.5)&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;No new items!  Gimme some FEEDBACK!  (please?)
&lt;/ul&gt;

&lt;br /&gt;
&lt;b&gt;Don't forget to leave a comment!&lt;/b&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var weightStart = document.getElementById('weightStart').value;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var numTimes = document.getElementById('numTimes').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightAfter) &amp;&amp; weightFormat.test(weightStart)){
	blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
	blogString += "&lt;ul&gt;";
  weightDesc = getWeightDiffOverAll(weightAfter, weightStart);
  blogString += "&lt;li /&gt; "+weightDesc;
  weightTopics = true;
}//end overall weight tracking
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
    if(!weightTopics){
    blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
    blogString += "&lt;ul&gt;";
    }else{
      blogString += "&lt;br /&gt;";
    }
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end test for ideal weight vs. today's weight

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(twoDigitFormat.test(numTimes)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
blogString += "&lt;li /&gt; I worked out "+numTimes+" time(s) this week.";
exerciseTopics = true;
}

if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

function getWeightDiffOverAll(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I have not lost any weight yet.";
}else if(weightDiff &gt;= 0){
   weightDesc = "I have lost "+weightDiff+" pound(s) since I started!";
}else{
   weightDesc = "I have gained "+Math.abs(weightDiff)+" pound(s) since I started.";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Beginning Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightStart" id="weightStart" size="5" maxlength="5" 
title="Weight when you first started exercise regimine." /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Exercised:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="numTimes" id="numTimes" size="1" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm still looking for ideas for the next version.  I'm toying with adding steps per day to tool.  I also need to somehow get the picture automatically added in.
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-6566531165332129094?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/6566531165332129094/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=6566531165332129094&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/6566531165332129094'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/6566531165332129094'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/04/trim-up-tuesday-version-15-04292008.html' title='Trim Up Tuesday (Version 1.5)  04/29/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-1211321505264309208</id><published>2008-04-22T07:21:00.001-05:00</published><updated>2008-04-22T07:23:33.771-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.4)  04/22/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;b&gt;Basic Info&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;b&gt;New For This Version (1.4)&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;No new items!  Gimme some FEEDBACK!  (please?)
&lt;/ul&gt;

&lt;br /&gt;
&lt;b&gt;Don't forget to leave a comment!&lt;/b&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var weightStart = document.getElementById('weightStart').value;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var numTimes = document.getElementById('numTimes').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightAfter) &amp;&amp; weightFormat.test(weightStart)){
	blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
	blogString += "&lt;ul&gt;";
  weightDesc = getWeightDiffOverAll(weightAfter, weightStart);
  blogString += "&lt;li /&gt; "+weightDesc;
  weightTopics = true;
}//end overall weight tracking
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
    if(!weightTopics){
    blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
    blogString += "&lt;ul&gt;";
    }else{
      blogString += "&lt;br /&gt;";
    }
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end test for ideal weight vs. today's weight

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(twoDigitFormat.test(numTimes)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
blogString += "&lt;li /&gt; I worked out "+numTimes+" time(s) this week.";
exerciseTopics = true;
}

if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

function getWeightDiffOverAll(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I have not lost any weight yet.";
}else if(weightDiff &gt;= 0){
   weightDesc = "I have lost "+weightDiff+" pound(s) since I started!";
}else{
   weightDesc = "I have gained "+Math.abs(weightDiff)+" pound(s) since I started.";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Beginning Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightStart" id="weightStart" size="5" maxlength="5" 
title="Weight when you first started exercise regimine." /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Exercised:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="numTimes" id="numTimes" size="1" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm still looking for ideas for the next version.  I'm toying with adding steps per day to tool.  I also need to somehow get the picture automatically added in.
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-1211321505264309208?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/1211321505264309208/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=1211321505264309208&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/1211321505264309208'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/1211321505264309208'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/04/trim-up-tuesday-version-14-04222008.html' title='Trim Up Tuesday (Version 1.4)  04/22/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-242493303576607240</id><published>2008-04-14T14:15:00.004-05:00</published><updated>2008-04-14T14:19:24.097-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.3)  04/15/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;b&gt;Basic Info&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;b&gt;New For This Version (1.3)&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;No new items!  Gimme some FEEDBACK!  (please?)
&lt;/ul&gt;

&lt;br /&gt;
&lt;b&gt;Don't forget to leave a comment!&lt;/b&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var weightStart = document.getElementById('weightStart').value;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var numTimes = document.getElementById('numTimes').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightAfter) &amp;&amp; weightFormat.test(weightStart)){
	blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
	blogString += "&lt;ul&gt;";
  weightDesc = getWeightDiffOverAll(weightAfter, weightStart);
  blogString += "&lt;li /&gt; "+weightDesc;
  weightTopics = true;
}//end overall weight tracking
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
    if(!weightTopics){
    blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
    blogString += "&lt;ul&gt;";
    }else{
      blogString += "&lt;br /&gt;";
    }
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end test for ideal weight vs. today's weight

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(twoDigitFormat.test(numTimes)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
blogString += "&lt;li /&gt; I worked out "+numTimes+" time(s) this week.";
exerciseTopics = true;
}

if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

function getWeightDiffOverAll(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I have not lost any weight yet.";
}else if(weightDiff &gt;= 0){
   weightDesc = "I have lost "+weightDiff+" pound(s) since I started!";
}else{
   weightDesc = "I have gained "+Math.abs(weightDiff)+" pound(s) since I started.";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Beginning Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightStart" id="weightStart" size="5" maxlength="5" 
title="Weight when you first started exercise regimine." /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Exercised:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="numTimes" id="numTimes" size="1" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm still looking for ideas for the next version.  I'm toying with adding steps per day to tool.  I also need to somehow get the picture automatically added in.
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-242493303576607240?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/242493303576607240/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=242493303576607240&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/242493303576607240'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/242493303576607240'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/04/trim-up-tuesday-version-13-04152008.html' title='Trim Up Tuesday (Version 1.3)  04/15/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-5791798481404736296</id><published>2008-04-07T08:33:00.003-05:00</published><updated>2008-04-07T15:43:57.500-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.2)  04/08/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;b&gt;Basic Info&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;b&gt;New For This Version (1.2)&lt;/b&gt;
&lt;ul&gt;
&lt;li /&gt;Record your beginning weight to keep track of your weight loss over time. 
&lt;li /&gt;Record number of time(s) exercised this week.
&lt;li /&gt;&lt;em&gt;NOTE&lt;/em&gt;: All new features are optional.  ALL input fields are optional.
&lt;/ul&gt;

&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var weightStart = document.getElementById('weightStart').value;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var numTimes = document.getElementById('numTimes').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightAfter) &amp;&amp; weightFormat.test(weightStart)){
	blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
	blogString += "&lt;ul&gt;";
  weightDesc = getWeightDiffOverAll(weightAfter, weightStart);
  blogString += "&lt;li /&gt; "+weightDesc;
  weightTopics = true;
}//end overall weight tracking
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
    if(!weightTopics){
    blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
    blogString += "&lt;ul&gt;";
    }else{
      blogString += "&lt;br /&gt;";
    }
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end test for ideal weight vs. today's weight

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(twoDigitFormat.test(numTimes)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
blogString += "&lt;li /&gt; I worked out "+numTimes+" time(s) this week.";
exerciseTopics = true;
}

if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

function getWeightDiffOverAll(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I have not lost any weight yet.";
}else if(weightDiff &gt;= 0){
   weightDesc = "I have lost "+weightDiff+" pound(s) since I started!";
}else{
   weightDesc = "I have gained "+Math.abs(weightDiff)+" pound(s) since I started.";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Beginning Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightStart" id="weightStart" size="5" maxlength="5" 
title="Weight when you first started exercise regimine." /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Exercised:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="numTimes" id="numTimes" size="1" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm still looking for ideas for the next version.  I'm toying with adding steps per day to tool.  I also need to somehow get the picture automatically added in.
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-5791798481404736296?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/5791798481404736296/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=5791798481404736296&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/5791798481404736296'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/5791798481404736296'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/04/trim-up-tuesday-version-12.html' title='Trim Up Tuesday (Version 1.2)  04/08/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-6177479101092812359</id><published>2008-03-31T15:17:00.030-05:00</published><updated>2008-04-07T15:41:55.701-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.1)  04/01/2008</title><content type='html'>&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184090197626985714" /&gt;&lt;/a&gt;

&lt;ul&gt;
&lt;li /&gt;To learn more about Trim Up Tuesday, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html"&gt;here&lt;/a&gt;.
&lt;li /&gt;To get the images for your post &amp; sidebar, go &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;here&lt;/a&gt;.
&lt;/ul&gt;

&lt;br /&gt;

&lt;b&gt;Directions&lt;/b&gt;
&lt;br /&gt;
Fill in any information you want. You can skip anything you want to. If you skip it, it simply won't be displayed. Your weight will not be displayed so don't let that stop you from using that portion of the form. Once you are done filling out your info, click "Create Blog". A window will popup, showing you what your blog will look like.  Although the background is white, when you paste it into the blog it will blend into your personal blog template.  If you're satisfied with it, simply copy the code in the box and paste it into blog post and publish it. If you need to you can close the popup, edit your information, and click the button again. 
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var cardio = document.getElementById('cardio').value;
var cardioMins = document.getElementById('cardioMins').value;
var weights = document.getElementById('weights').value;
var weightsMins = document.getElementById('weightsMins').value;
var activities = document.getElementById('activities').value;
var actMins = document.getElementById('actMins').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end 

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(exerciseFormat.test(cardio) || exerciseFormat.test(cardioMins)){
if(!exerciseFormat.test(cardio)){
cardio = 0;
}else if(!exerciseFormat.test(cardioMins)){
cardioMins = 0;
}
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I did "+cardio+" hour(s) and "+cardioMins+" minutes ";
blogString += "of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights) || exerciseFormat.test(weightsMins)){
    if(!exerciseFormat.test(weights)){
       weights = 0;
    }else if (!exerciseFormat.test(weightsMins)){
        weightsMins = 0;
    }

	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" hour(s) and "+weightsMins+" minutes ";
blogString += "of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities) || exerciseFormat.test(actMins) ){
     if(!exerciseFormat.test(activities)){
          activities = 0;
      }else if(!exerciseFormat.test(actMins)){
          actMins = 0;
      }
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" hour(s) and "+actMins+" minutes "; 
blogString += "of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="cardioMins" id="cardioMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="weightsMins" id="weightsMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="1" maxlength="2" /&gt; hr
&lt;input type="text" name="wactMins" id="actMins" size="1" maxlength="2" /&gt; min
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;

&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Participation&lt;/b&gt;
&lt;br /&gt;
Please leave a comment to let me know you participated and I'll stop by.  If you add my button to your page, I'll add you to my blogroll (updated weekly, and yes, it will be prettier in the future).
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Next Version&lt;/b&gt;
&lt;br /&gt;
I'm sorry Lynda! The total weight loss &amp; number times exercised per week will have to wait until the next release.  I kinda ran out of time and I needs me some sleeps. *oops*
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Finally ... &lt;/b&gt;
&lt;br /&gt;
And, as always, I'm not a mind reader over here, so if you want something done or changed, you gotta ask for it! Please don't be shy, I WANT to make the tool better for everyone who wants to use it.  And if *gasp* you happen to find a bug, please describe it in as much detail as possible so I can try to find &amp; fix it.
&lt;br /&gt;&lt;br /&gt;
Until next week ...  &lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-6177479101092812359?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/6177479101092812359/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=6177479101092812359&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/6177479101092812359'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/6177479101092812359'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-version-11.html' title='Trim Up Tuesday (Version 1.1)  04/01/2008'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GWkXkkHPI/AAAAAAAAAFI/Nc-rZxDFp_U/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-4400753011278184274</id><published>2008-03-31T15:07:00.005-05:00</published><updated>2008-03-31T20:50:13.073-05:00</updated><title type='text'>Trim Up Tuesday Images</title><content type='html'>I have had a lot of trouble lately with Blogger and its imaging system.  It's really annoying, difficult to work with, and unreliable.  I'd host this on Flickr, but Flickr doesn't give me a dedicated page to the logo, which is what I need.  Any suggestions are more than welcome, just leave a comment.  In the meantime, please right click the image below and hit "Save As."  Then use Blogger's image tool to add it in, and enclose it in a link to: http://trimUpTuesday.blogspot.com.  
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Large (for blog post):&lt;/b&gt;
&lt;br /&gt;
&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GRpXkkHNI/AAAAAAAAAE4/J0b2eGkaJa4/s1600-h/trimUpTuesdayLogo.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GRpXkkHNI/AAAAAAAAAE4/J0b2eGkaJa4/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184084785968192722" /&gt;&lt;/a&gt;
&lt;br /&gt;&lt;br /&gt;
&lt;b&gt;Small (for sidebar):&lt;/b&gt;
&lt;br /&gt;
&lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R_GUpXkkHOI/AAAAAAAAAFA/BCSldzCYyAA/s1600-h/trimUpTuesdayLogoMini.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R_GUpXkkHOI/AAAAAAAAAFA/BCSldzCYyAA/s400/trimUpTuesdayLogoMini.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5184088084503076066" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-4400753011278184274?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/4400753011278184274/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=4400753011278184274&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/4400753011278184274'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/4400753011278184274'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html' title='Trim Up Tuesday Images'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R_GRpXkkHNI/AAAAAAAAAE4/J0b2eGkaJa4/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-1746385143167439452</id><published>2008-03-31T15:06:00.005-05:00</published><updated>2008-04-29T10:13:55.316-05:00</updated><title type='text'>Blogroll</title><content type='html'>&lt;ul&gt;
&lt;li /&gt;&lt;a href="http://icybluerose.blogspot.com"&gt;Brandie&lt;/a&gt;
&lt;li /&gt;&lt;a href="http://divaindachantixhouse.blogspot.com/"&gt;Diva&lt;/a&gt;
&lt;li /&gt;&lt;a href="http://liferushesby.blogspot.com"&gt;Lynda&lt;/a&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-1746385143167439452?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/1746385143167439452/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=1746385143167439452&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/1746385143167439452'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/1746385143167439452'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/03/blogroll.html' title='Blogroll'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-4692165089209308912</id><published>2008-03-31T14:51:00.006-05:00</published><updated>2008-03-31T21:31:04.875-05:00</updated><title type='text'>Welcome to Trim Up Tuesday!</title><content type='html'>I'm here to kick your butt into shape by making you accountable to all 
the people who are reading your blog and rooting you on. Many of us have
quit smoking and thus put on pounds, but others just want to be healthier.  
No matter what your goal may be: health, fitness, or weight; this is the place for you.

There are 3 simple steps to participating.  Join any time you want!

&lt;ul&gt;
&lt;li /&gt;#1 &amp;nbsp; &lt;a href="http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-images.html"&gt;Add an image to your blog to be added to the blogroll&lt;/a&gt;.
&lt;li /&gt;#2 &amp;nbsp; &lt;a href="http://trimuptuesday.blogspot.com"&gt;Use the tool to create your blog post&lt;/a&gt;.
&lt;li /&gt;#3 &amp;nbsp; &lt;a href="http://trimuptuesday.blogspot.com"&gt;Leave a comment on the post so I can visit your blog&lt;/a&gt;.
&lt;/ul&gt;

&lt;br /&gt;
Thanks for participating in Trim Up Tuesday!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-4692165089209308912?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/4692165089209308912/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=4692165089209308912&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/4692165089209308912'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/4692165089209308912'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/03/welcome-to-trim-up-tuesday.html' title='Welcome to Trim Up Tuesday!'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8238555369142194186.post-6544141187692279454</id><published>2008-03-24T12:55:00.012-05:00</published><updated>2008-03-31T14:54:35.437-05:00</updated><title type='text'>Trim Up Tuesday (Version 1.0)</title><content type='html'>&lt;a href="http://trimuptuesday.blogspot.com"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R-cF13kkHBI/AAAAAAAAADI/ga2WhSUkn2o/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5181116319321562130" /&gt;&lt;/a&gt;
&lt;br /&gt;&lt;br /&gt;

&lt;script language="javascript"&gt;
function createBlog(){
var blogString = "&lt;div&gt;";
var weightFormat = /^[0-9]{3}\.{0,1}[0-9]{0,1}$/;
var feetFormat = /^[0-9]{1}$/;
var twoDigitFormat = /^[0-9]{1,2}$/;
var exerciseFormat = /^[0-9]{1,4}$/;
var idealWeight = document.getElementById('idealWeight').value;
var weightBefore = document.getElementById('weightBefore').value;
var weightAfter = document.getElementById('weightAfter').value;
var feet = document.getElementById('heightFeet').value;
var inches = document.getElementById('heightInches').value;
var newGoal = trim(document.getElementById('newGoal').value);
var oldGoal = trim(document.getElementById('oldGoal').value);
var fastFood = document.getElementById('fastFood').value;
var snacks = document.getElementById('snacks').value;
var soda = document.getElementById('soda').value;
var cardio = document.getElementById('cardio').value;
var weights = document.getElementById('weights').value;
var activities = document.getElementById('activities').value;
var goalCheck = getCheckedValue();
var heightInInches = "";
var idealDiff = "";
var weightDiff = "";
var weightDesc = "";
var idealDesc = "";
var bmiDesc = "";
var bmi = "";
var weightTopics = false;
var goalTopics = false;
var dietTopics = false;
var exerciseTopics = false;

//Get Weight Info
if(weightFormat.test(weightBefore) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;Weight&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
weightDiff = weightAfter - weightBefore;
weightDesc = getWeightDiffDesc(weightBefore, weightAfter);
blogString += "&lt;li&gt;"+weightDesc;
weightTopics = true;
}
if(weightFormat.test(idealWeight) &amp;&amp; weightFormat.test(weightAfter)){
   if(!weightTopics){
   blogString +="&lt;h3&gt;Weight Stuffs&lt;/h3&gt;";
   blogString += "&lt;ul&gt;";
   }else{
     blogString += "&lt;br /&gt;";
   }
idealDiff = idealWeight - weightAfter;
idealDesc = getIdealDiffDesc(idealWeight, weightAfter);
blogString += "&lt;li /&gt;"+idealDesc;
weightTopics = true;
}//end 

if(weightTopics){ //Close weight list
blogString += "&lt;/ul&gt;";
}

//Get BMI Info
if(feetFormat.test(feet) &amp;&amp; twoDigitFormat.test(inches) &amp;&amp; weightFormat.test(weightAfter)){
blogString +="&lt;h3&gt;BMI&lt;/h3&gt;";
blogString += "&lt;ul&gt;";
heightInInches = getHeightInInches(feet, inches);
bmi = getBMI(weightAfter, heightInInches);
bmiDesc = getBMIDesc(bmi);
blogString += "&lt;li /&gt;"+bmiDesc;
blogString += "&lt;/ul&gt;";
}

//Get Diet Info
if(twoDigitFormat.test(fastFood)){
blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I ate out "+fastFood+" time(s) this week";
dietTopics = true;
}

if(twoDigitFormat.test(snacks)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I ate an average of "+snacks+" snack(s) per day";
dietTopics = true;
}

if(twoDigitFormat.test(soda)){
	if(!dietTopics){
		blogString += "&lt;h3&gt;Diet&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I drank an average of "+soda+" calorie-filled drink(s) per day";
dietTopics = true;
}

if(dietTopics){
blogString += "&lt;/ul&gt;";
}

//Get Exercise Info
if(exerciseFormat.test(cardio)){
blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
blogString += "&lt;ul&gt;";

blogString += "&lt;li /&gt;I did "+cardio+" minutes of cardio this week";

exerciseTopics = true;
}

if(exerciseFormat.test(weights)){
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	}
blogString += "&lt;li /&gt;I did "+weights+" minutes of strength training this week";
exerciseTopics = true;
}

if(exerciseFormat.test(activities)){
	if(!exerciseTopics){
		blogString += "&lt;h3&gt;Exercise&lt;/h3&gt;";
		blogString += "&lt;ul&gt;";
	} 
blogString += "&lt;li /&gt;I did "+activities+" minutes of brisk activity this week";
exerciseTopics = true;
}

if(exerciseTopics){
blogString += "&lt;/ul&gt;";
}


//Get Goals Info
if(goalCheck != null 
	&amp;&amp; (goalCheck == "yes" || goalCheck == "no")){
  blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
  blogString += "&lt;ul&gt;";
  blogString += "&lt;li /&gt;I did ";
	if(goalCheck == "no"){
	  blogString += "not ";
	}
  blogString += "meet my last goal"; 	
  goalTopics = true;
}

if(oldGoal != null &amp;&amp; oldGoal.length &gt; 0){
	if(!goalTopics){	
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;br /&gt;
To be added to the future blogroll, please add the button below to your blog.  
&lt;br /&gt;
Don't forget to leave a comment on the post (with url) so I know who you are!
&lt;br /&gt;&lt;br /&gt;
&lt;a href="http://trimuptuesday.blogspot.com/"&gt;
&lt;img style="display:block; margin:0px auto 10px; text-align:left;cursor:pointer; cursor:hand;" 
src="http://bp0.blogger.com/_eCAZ8scZe20/R-cWq3kkHDI/AAAAAAAAADU/lQEW-5KGkwA/s400/trimUpTuesdayLogoMini.jpg" 
border="0" alt=""id="BLOGGER_PHOTO_ID_5181134822040673330" /&gt;&lt;/a&gt;
&lt;br /&gt;
&lt;textarea rows="4" cols="30"&gt;
&lt;a href="http://trimuptuesday.blogspot.com"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;" src="http://bp0.blogger.com/_eCAZ8scZe20/R-cF13kkHBI/AAAAAAAAADI/ga2WhSUkn2o/s400/trimUpTuesdayLogo.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5181116319321562130" /&gt;&lt;/a&gt;
&lt;/textarea&gt;
&lt;br /&gt;
If you have problems with this image, try saving it directly.  You can find the picture &lt;a href="http://bp0.blogger.com/_eCAZ8scZe20/R-cF13kkHBI/AAAAAAAAADI/ga2WhSUkn2o/s400/trimUpTuesdayLogo.jpg"&gt;here&lt;/a&gt;
&lt;br /&gt;&lt;br /&gt;

I can't stress enough that this is only the first version.  If you have suggestions,
if you'd like to see anything at all changed, or added, or taken away, PLEASE COMMENT.
I can't read minds over here, so I need your help.  If you don't like it, or you do like
it, tell me why!  I have many more ideas for this -- we're just getting started!

&lt;br /&gt;&lt;br /&gt;
Thanks for participating in Trim Up Tuesday!  Come back next week!";
    }
	blogString += "&lt;li /&gt;My Last Goal Was: "+oldGoal;
  goalTopics = true;
}

if(newGoal.length &gt; 0){
  if(!goalTopics){
     blogString += "&lt;h3&gt;Goals&lt;/h3&gt;";
	 blogString += "&lt;ul&gt;";
  }
blogString += "&lt;li /&gt;My new goal is: "+newGoal;
goalTopics = true;
}

if(goalTopics){
blogString += "&lt;/ul&gt;";
}

//Write to new window
blogString += "&lt;/div&gt;";
win3 = window.open("", "Window3", "width=500,height=500,scrollbars=yes");
win3.document.writeln("&lt;h2&gt;&lt;u&gt;Here is what your blog will look like: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln(blogString);
win3.document.writeln("&lt;br /&gt;&lt;br /&gt;&lt;h2&gt;&lt;u&gt;Copy &amp; Paste Code Into Your Blog: &lt;/u&gt;&lt;/h2&gt;");
win3.document.writeln("&lt;textarea rows='7'");
win3.document.writeln("cols='50'&gt;"+blogString+"&lt;/textarea&gt;");

}//end createBlog

//This function determines the selected checkbox (if any)
function getCheckedValue(){
var selectedVal = "";
var len = document.forms.healthForm.goalCheck.length;

for(x=0; x&lt;len; x++){
  if(document.forms.healthForm.goalCheck[x].checked){
	selectedVal = document.forms.healthForm.goalCheck[x].value;
	break;
  }
}
return selectedVal;
}

//This function returns a string for weight difference between two weeks
function getWeightDiffDesc(weightBefore, weightAfter){
var weightDesc = "";
var weightDiff = weightAfter - weightBefore;
if(weightDiff == 0){
   weightDesc = "I am the same weight as last week. (Hey, that's better than gaining!)";
}else if(weightDiff &gt;= 0){
   weightDesc = "I am "+weightDiff+" pound(s) heavier than last week.";
}else{
   weightDesc = "I lost "+Math.abs(weightDiff)+" pound(s) this week!";
}

return weightDesc;
}

//This function returns a string for weight difference between ideal and
//actual weight
function getIdealDiffDesc(idealWeight, actualWeight){
var weightDesc = "";
var weightDiff = idealWeight - actualWeight;
if(weightDiff == 0){
   weightDesc = "I have reached my ideal weight!";
}else if(weightDiff &lt; 0){
   weightDesc = "I am "+Math.abs(weightDiff)+" pound(s) away from my ideal weight.";
}else{
   weightDesc = "I have surpassed my ideal weight by "+weightDiff+" pound(s)!";
}

return weightDesc;


}

function getBMIDesc(bmi){
var bmiDesc = "My BMI is: "+bmi+". This is considered ";

  if(bmi &lt; 18.5){
 bmiDesc += "underweight.";
  }else if (bmi &gt;= 18.5 &amp;&amp; bmi &lt;= 24.9){
 bmiDesc += "normal.";
  }else if (bmi &gt;= 25 &amp;&amp; bmi &lt;= 29.9){
 bmiDesc += "overweight.";
  }else{
 bmiDesc += "obese.";
  }
return bmiDesc;
}

function getHeightInInches(numFeet, numInches){
   return ((numFeet *12) + numInches);
}

function getBMI(currentWeight, heightInInches){
 
  var bmi = (currentWeight/heightInInches)*100;
  bmi =  Math.round(bmi*Math.pow(10,1))/Math.pow(10,1);
  return (bmi);
}

function trim(stringToTrim) {
	return stringToTrim.replace(/^\s+|\s+$/g,"");
}
&lt;/script&gt;

&lt;form name="healthForm" method="POST"&gt;

&lt;table border="0"&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;WEIGHT &amp; BMI&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Ideal Weight: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="idealWeight" id="idealWeight" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
My Height: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="heightFeet" id="heightFeet" size="1" maxlength="1"&gt;
&lt;b&gt;'&lt;/b&gt;
&amp;nbsp;
&lt;input type="text" name="heightInches" id="heightInches" size="2" maxlength="2"&gt;
&lt;b&gt;"&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td valign="top"&gt;
Weight Last Week: 

&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightBefore" id="weightBefore" size="5" maxlength="5" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Weight This Week: 
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weightAfter" id="weightAfter" size="5" maxlength="5"&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;DIET&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Times I Ate Out This Week:&amp;nbsp;
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="fastFood" id="fastFood" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Snacks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="snacks" id="snacks" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
# Calorie Drinks Per Day:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="soda" id="soda" size="2" maxlength="2" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;EXERCISE (Minutes Per Week)&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Cardio:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="cardio" id="cardio" size="3" maxlength="4" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Strength Training:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="weights" id="weights" size="3" maxlength="4" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Other Brisk Activities:
&lt;/td&gt;
&lt;td&gt;
&lt;input type="text" name="activities" id="activities" size="3" maxlength="4" /&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;b&gt;GOALS&lt;/b&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td colspan="2"&gt;
My goal for this week is:
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="newGoal" id="newGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
Last week's goal was:
&lt;/td&gt;
&lt;td&gt;
Goal Met?
&lt;br /&gt;
&lt;input type="radio" name="goalCheck" value="yes" &gt;Yes
&lt;input type="radio" name="goalCheck" value="no" &gt;No
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td colspan="2"&gt;
&lt;textarea name="oldGoal" id="oldGoal" rows="2" cols="30"&gt;
&lt;/textarea&gt;
&lt;/td&gt;
&lt;/tr&gt;

&lt;tr&gt;
&lt;td&gt;
&lt;input type="button" value="Create Blog" onclick="createBlog()"&gt;
&lt;/td&gt;
&lt;td&gt;&amp;nbsp;&lt;/td&gt;
&lt;/table&gt;
&lt;br /&gt;
&lt;/form&gt;
&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8238555369142194186-6544141187692279454?l=trimuptuesday.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://trimuptuesday.blogspot.com/feeds/6544141187692279454/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8238555369142194186&amp;postID=6544141187692279454&amp;isPopup=true' title='5 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/6544141187692279454'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8238555369142194186/posts/default/6544141187692279454'/><link rel='alternate' type='text/html' href='http://trimuptuesday.blogspot.com/2008/03/trim-up-tuesday-version-10_24.html' title='Trim Up Tuesday (Version 1.0)'/><author><name>Brandie</name><uri>http://www.blogger.com/profile/17979255140890156113</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='24' height='32' src='http://bp2.blogger.com/_eCAZ8scZe20/R9LlqJteDdI/AAAAAAAAABE/rNjoj2PLpRU/S220/Picture+108.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://bp0.blogger.com/_eCAZ8scZe20/R-cF13kkHBI/AAAAAAAAADI/ga2WhSUkn2o/s72-c/trimUpTuesdayLogo.jpg' height='72' width='72'/><thr:total>5</thr:total></entry></feed>
