Difference between revisions of "Test"

From Fellrnr.com, Running tips
Jump to: navigation, search
User:Fellrnr (User talk:Fellrnr | contribs)
User:Fellrnr (User talk:Fellrnr | contribs)
Line 5: Line 5:
 
var trimps=new Array();
 
var trimps=new Array();
 
var total = 0;
 
var total = 0;
for(i=1; i<=5; i++)
+
for(j=0; j<=5; j++)
 
{
 
{
if(document.getElementById('0'+i).checked)
+
for(i=1; i<=5; i++)
 
{
 
{
total += document.getElementById('0'+i).value;
+
if(document.getElementById(j+""+i).checked)
 +
{
 +
total += Number(document.getElementById(j+""+i).value);
 +
}
 
}
 
}
 
}
 
}
Line 28: Line 31:
 
       <tr>
 
       <tr>
 
       <td>I slept well last night</td>
 
       <td>I slept well last night</td>
         <td><input type="radio" name="slept" value="1" id="01"/></td>
+
         <td><input type="radio" name="0" value="1" id="01"/></td>
         <td><input type="radio" name="slept" value="2" id="02"/></td>
+
         <td><input type="radio" name="0" value="2" id="02"/></td>
         <td><input type="radio" name="slept" value="3" id="03"/></td>
+
         <td><input type="radio" name="0" value="3" id="03"/></td>
         <td><input type="radio" name="slept" value="4" id="04"/></td>
+
         <td><input type="radio" name="0" value="4" id="04"/></td>
         <td><input type="radio" name="slept" value="5" id="05"/></td>
+
         <td><input type="radio" name="0" value="5" id="05"/></td>
 +
      </tr>
 +
      <tr>
 +
      <td>I am looking forward to today's workout</td>
 +
        <td><input type="radio" name="1" value="1" id="11"/></td>
 +
        <td><input type="radio" name="1" value="2" id="12"/></td>
 +
        <td><input type="radio" name="1" value="3" id="13"/></td>
 +
        <td><input type="radio" name="1" value="4" id="14"/></td>
 +
        <td><input type="radio" name="1" value="5" id="15"/></td>
 +
      </tr>
 +
      <tr>
 +
      <td>I am optimistic about my future performance</td>
 +
        <td><input type="radio" name="2" value="1" id="21"/></td>
 +
        <td><input type="radio" name="2" value="2" id="22"/></td>
 +
        <td><input type="radio" name="2" value="3" id="23"/></td>
 +
        <td><input type="radio" name="2" value="4" id="24"/></td>
 +
        <td><input type="radio" name="2" value="5" id="25"/></td>
 +
      </tr>
 +
      <tr>
 +
      <td>I feel vigorous and energetic</td>
 +
        <td><input type="radio" name="3" value="1" id="31"/></td>
 +
        <td><input type="radio" name="3" value="2" id="32"/></td>
 +
        <td><input type="radio" name="3" value="3" id="33"/></td>
 +
        <td><input type="radio" name="3" value="4" id="34"/></td>
 +
        <td><input type="radio" name="3" value="5" id="35"/></td>
 +
      </tr>
 +
      <tr>
 +
      <td>My appetite is great</td>
 +
        <td><input type="radio" name="4" value="1" id="41"/></td>
 +
        <td><input type="radio" name="4" value="2" id="42"/></td>
 +
        <td><input type="radio" name="4" value="3" id="43"/></td>
 +
        <td><input type="radio" name="4" value="4" id="44"/></td>
 +
        <td><input type="radio" name="4" value="5" id="45"/></td>
 +
      </tr>
 +
      <tr>
 +
      <td>I have little muscle soreness</td>
 +
        <td><input type="radio" name="5" value="1" id="51"/></td>
 +
        <td><input type="radio" name="5" value="2" id="52"/></td>
 +
        <td><input type="radio" name="5" value="3" id="53"/></td>
 +
        <td><input type="radio" name="5" value="4" id="54"/></td>
 +
        <td><input type="radio" name="5" value="5" id="55"/></td>
 
       </tr>
 
       </tr>
 
   </table>
 
   </table>

Revision as of 21:10, 6 March 2012

Question strongly disagree disagree neutral agree strongly agree
I slept well last night
I am looking forward to today's workout
I am optimistic about my future performance
I feel vigorous and energetic
My appetite is great
I have little muscle soreness