This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
playground:playground [2019/07/10 13:26] – created fachet | playground:playground [2023/04/04 16:21] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ~~NOCACHE~~ | + | ====== |
- | ====== | + | |
- | < | + | |
- | <!-- präsentiert von kostenlose-javascripts.de --> | + | |
- | <script type=' | + | |
- | function berechnen() { | + | |
- | var bmi; | + | |
- | var weight = document.bmiform.gewicht.value; | + | |
- | var height = document.bmiform.groesse.value; | + | |
- | if (weight < 10 || weight > 200) { alert(" | + | |
- | if (height < 50 || height > 250) { alert(" | + | |
- | bmi = Math.round(weight / (Math.pow((height/ | + | |
- | | + | |
- | if (bmi < 18) output += "Sie haben starkes Untergewicht."; | + | |
- | if (bmi == 18) output += "Sie haben deutliches Untergewicht."; | + | |
- | if (bmi == 19) output += "Sie haben leichtes Untergewicht."; | + | |
- | if (bmi >= 20 && bmi <= 24) output += "Dies liegt im idealen Bereich."; | + | |
- | if (bmi >= 25 && bmi <= 29) output += "Sie haben leichtes bis mässiges Übergewicht."; | + | |
- | if (bmi >= 30 && bmi <= 39) output += "Sie haben deutliches Übergewicht."; | + | |
- | if (bmi >= 40) output += "Sie haben sehr starkes Übergewicht."; | + | |
- | | + | |
- | } | + | |
- | //--> | + | |
- | </ | + | |
- | <form name=" | + | |
- | <input type=" | + | |
- | Größe in cm<br /> | + | |
- | <input type=" | + | |
- | Gewicht in kg<br /> | + | |
- | <input type=" | + | |
- | <br /> | + | |
- | </ | + | |
- | <br /> | + | |
- | </ | + | |