Difference between revisions of "Test"
From Fellrnr.com, Running tips
User:Fellrnr (User talk:Fellrnr | contribs) (Created page with "<html> <script type="text/javascript"> var isArray = function (obj) { return Object.prototype.toString.call(obj) === "[object Array]"; }, getNumWithSetDec = function( num, numOf...") |
User:Fellrnr (User talk:Fellrnr | contribs) |
||
Line 37: | Line 37: | ||
function doCalc() | function doCalc() | ||
{ | { | ||
− | + | var d1 = document.getElementById('dur_1').innerHTML; | |
+ | alert(d1); | ||
+ | var c1 = document.getElementById('cr10_1').innerHTML; | ||
+ | alert(c1); | ||
+ | var t1 = d1 * c1; | ||
+ | alert(t1); | ||
+ | document.getElementById('trimp_1').innerHTML = t1; | ||
} | } | ||
</script> | </script> | ||
− | <form | + | <form style="font-family: Helvetica,Arial,sans-serif;" id="Monotony"> |
− | <table border="1" cellpadding="1" cellspacing="1"> | + | <table style="text-align: left;" border="1" cellpadding="1" cellspacing="1"> |
<tr> | <tr> | ||
<th>Day</th> | <th>Day</th> | ||
Line 51: | Line 57: | ||
<tr> | <tr> | ||
<td>1</td> | <td>1</td> | ||
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="Dur_1" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="cr10_1" value="0"></td> |
− | <td>< | + | <td><label id="trimp_1"></label></td> |
</tr> | </tr> | ||
<tr> | <tr> | ||
<td>2</td> | <td>2</td> | ||
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="Dur_2" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="cr10_2" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="trimp_2" value="0" readonly="readonly"></td> |
</tr> | </tr> | ||
<tr> | <tr> | ||
<td>3</td> | <td>3</td> | ||
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="Dur_3" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="cr10_3" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="trimp_3" value="0" readonly="readonly"></td> |
</tr> | </tr> | ||
<tr> | <tr> | ||
<td>4</td> | <td>4</td> | ||
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="Dur_4" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="cr10_4" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="trimp_4" value="0" readonly="readonly"></td> |
</tr> | </tr> | ||
<tr> | <tr> | ||
<td>5</td> | <td>5</td> | ||
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="Dur_5" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="cr10_5" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="trimp_5" value="0" readonly="readonly"></td> |
</tr> | </tr> | ||
<tr> | <tr> | ||
<td>6</td> | <td>6</td> | ||
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="Dur_6" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="cr10_6" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="trimp_6" value="0" readonly="readonly"></td> |
</tr> | </tr> | ||
<tr> | <tr> | ||
<td>7</td> | <td>7</td> | ||
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="Dur_7" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="cr10_7" value="0"></td> |
− | <td><input maxlength="3" size="3" | + | <td><input maxlength="3" size="3" id="trimp_7" value="0" readonly="readonly"></td> |
</tr> | </tr> | ||
</table> | </table> | ||
− | <label | + | <label id="Monotony">Monotony:</label> |
<br> | <br> | ||
− | <input type="button" value="Calculate" | + | <input type="button" value="Calculate" onclick="doCalc()"/> |
− | |||
</html> | </html> |
Revision as of 18:34, 22 February 2012