PSD-Tutorials.de
Forum für Design, Fotografie & Bildbearbeitung
Tutkit
Agentur
Hilfe
Kontakt
Start
Forum
Aktuelles
Besonderer Inhalt
Foren durchsuchen
Tutorials
News
Anmelden
Kostenlos registrieren
Aktuelles
Suche
Suche
Nur Titel durchsuchen
Von:
Menü
Anmelden
Kostenlos registrieren
App installieren
Installieren
JavaScript ist deaktiviert. Für eine bessere Darstellung aktiviere bitte JavaScript in deinem Browser, bevor du fortfährst.
Du verwendest einen veralteten Browser. Es ist möglich, dass diese oder andere Websites nicht korrekt angezeigt werden.
Du solltest ein Upgrade durchführen oder einen
alternativen Browser
verwenden.
Antworten auf deine Fragen:
Neues Thema erstellen
Start
Forum
Sonstiges
Webdesign, Webentwicklung & Programmierung
PHP, Javascript, jQuery, Ajax, nodeJS, MySQL...
Hilfe bei mathematischer Berechnung
Beitrag
<blockquote data-quote="d4y" data-source="post: 2199138" data-attributes="member: 377643"><p><strong>AW: Hilfe bei mathematischer Berechnung</strong></p><p></p><p>@Duddle</p><p></p><p>Danke ist eine simple Berechnung ohne extra Daten a*b*c*d+e werde mich mal durch das Pdf arbeiten. Nochmals vielen Dank fuer die Hilfe</p><p></p><p>Habe folgendes gebastelt:</p><p></p><p>[HTML]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"></p><p><html xmlns="http://www.w3.org/1999/xhtml"></p><p><head></p><p><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /></p><p><title>Untitled Document</title></p><p></p><p></p><p></head></p><p><script type="text/javascript"></p><p><!-- Begin</p><p>/* This script and many more are available free online at</p><p>The JavaScript Source!! http://www.javascriptsource.com</p><p>Based on a script Created by: Matthew Ogden :: http://www.home.earthlink.net/~ogden1972/ */</p><p></p><p>function d(){</p><p> var a = document.form1.hight.value;</p><p> var b = document.form1.length.value;</p><p> var c = document.form1.depth.value;</p><p> var costb = document.form1.chem.value;</p><p> var cost = document.form1.cost.value;</p><p> mpg=(a*b*c*cost)-(-costb);</p><p> mpg= Math.round(mpg*10)/10;</p><p> </p><p> document.form1.results.value="You spent "+mpg+" Euros to refill your pool.";</p><p>}</p><p>// End --></p><p></script>// JavaScript Document</p><p></p><p></p><p></p><p><body></p><p></p><p><div align="center"></p><p><h3>Cost calculation for refilling a poolr</h3></p><p></p><p><form name="form1"></p><p><strong>Pool length</strong>**</p><p><input type="text" size="4" name="hight"><strong> m</strong><br><br>**</p><p><strong>Pool with</strong>**</p><p><input type="text" size="4" name="length"><strong> m</strong><br><br>**</p><p><strong>Pool depth</strong></p><p><input type="text" size="4" name="cost"><strong> m</strong><br><br>**</p><p><strong>Water price per m3</strong></p><p><input type="text" size="4" name="depth"><strong> Euro</strong><br><br></p><p><strong>Price for Chemicals</strong></p><p><input type="text" size="4" name="chem"><strong> Euro</strong><br><br></p><p><input type="button" value="Calculate" onclick="d()">*<input type="Reset" value="Clear"><br><br></p><p><strong>Results</strong><br></p><p><textarea name="results" rows="5" cols="55" wrap style="border-width:0;overflow:hidden"onfocus="this.blur()"></p><p></textarea></p><p></form></p><p></div></p><p></body></p><p></html>[/HTML]</p><p></p><p>Auf einer einfachen html Seite funktioniert es, nun besteht meine Seite aber aus einem css template und wenn ich den Code einfüge funktioniert weder die Berechnung noch der "Clear" Button nicht mehr. Es kommt auch keine Fehlermeldung.</p><p></p><p>Bitte helft Mir</p></blockquote><p></p>
[QUOTE="d4y, post: 2199138, member: 377643"] [b]AW: Hilfe bei mathematischer Berechnung[/b] @Duddle Danke ist eine simple Berechnung ohne extra Daten a*b*c*d+e werde mich mal durch das Pdf arbeiten. Nochmals vielen Dank fuer die Hilfe Habe folgendes gebastelt: [HTML]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Untitled Document</title> </head> <script type="text/javascript"> <!-- Begin /* This script and many more are available free online at The JavaScript Source!! http://www.javascriptsource.com Based on a script Created by: Matthew Ogden :: http://www.home.earthlink.net/~ogden1972/ */ function d(){ var a = document.form1.hight.value; var b = document.form1.length.value; var c = document.form1.depth.value; var costb = document.form1.chem.value; var cost = document.form1.cost.value; mpg=(a*b*c*cost)-(-costb); mpg= Math.round(mpg*10)/10; document.form1.results.value="You spent "+mpg+" Euros to refill your pool."; } // End --> </script>// JavaScript Document <body> <div align="center"> <h3>Cost calculation for refilling a poolr</h3> <form name="form1"> <strong>Pool length</strong>** <input type="text" size="4" name="hight"><strong> m</strong><br><br>** <strong>Pool with</strong>** <input type="text" size="4" name="length"><strong> m</strong><br><br>** <strong>Pool depth</strong> <input type="text" size="4" name="cost"><strong> m</strong><br><br>** <strong>Water price per m3</strong> <input type="text" size="4" name="depth"><strong> Euro</strong><br><br> <strong>Price for Chemicals</strong> <input type="text" size="4" name="chem"><strong> Euro</strong><br><br> <input type="button" value="Calculate" onclick="d()">*<input type="Reset" value="Clear"><br><br> <strong>Results</strong><br> <textarea name="results" rows="5" cols="55" wrap style="border-width:0;overflow:hidden"onfocus="this.blur()"> </textarea> </form> </div> </body> </html>[/HTML] Auf einer einfachen html Seite funktioniert es, nun besteht meine Seite aber aus einem css template und wenn ich den Code einfüge funktioniert weder die Berechnung noch der "Clear" Button nicht mehr. Es kommt auch keine Fehlermeldung. Bitte helft Mir [/QUOTE]
Bilder bitte
hier hochladen
und danach über das Bild-Icon (Direktlink vorher kopieren) platzieren.
Zitate einfügen…
Authentifizierung
Wenn ▲ = 5, ▼ = 2 und ■ = 7, was ist ▲ × ▼ + ■?
Antworten
Start
Forum
Sonstiges
Webdesign, Webentwicklung & Programmierung
PHP, Javascript, jQuery, Ajax, nodeJS, MySQL...
Hilfe bei mathematischer Berechnung
Oben