Body Fat Calculator3. Javascript |
|
Join the DiscussionMore of this FeatureThe final step is to install the Javascript that does the actual calculations for the body fat calculator. All you need to do is to copy the following code and save it as fatcalc.js. Most of that code is needed to validate the values that your visitor enters into the form in order to make sure that the values are numeric and within a reasonable range. The actual calculations themselves (if you are interested in what those formula actually are) can be found in the maleFat() and femaleFat() functions. |

