Ich habe mal eine Test-Datei angelegt, um mein Problem zu verdeutlichen:
<html>
<head>
<title>Unbenanntes Dokument</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script type="text/javascript">
<!--
function berech(ein_1,ein_2,ein_3,ein_4,aus_1,aus_2)
{
aus_1 = ein_1+ein_2+ein_3+ein_4;
aus_2 = ein_1*wert_1+ein_2*wert_2+ein_3*wert_3+ein_4*wert_4;
alert(aus_1);
alert(aus_2);
}
//-->
</script>
</head>
<body background="grafik/hg-blau.jpg" text="white" link="white" vlink="white" alink="white">
<form name="form1" action="#">
<input name="test_1" onkeyup="berech(this.value,text_2,text_3,text_4,wert_1,wert_2,ausgabe_1,ausgabe_2)" value="5" type="text" size="5">Test-1<br>
<input name="test_2" onkeyup="berech(this.value,text_1,text_3,text_4,wert_1,wert_2,ausgabe_1,ausgabe_2)" value="6" type="text" size="5">Test-2<br>
<input name="test_3" onkeyup="berech(this.value,text_1,text_2,text_4,wert_1,wert_2,ausgabe_1,ausgabe_2)" value="7" type="text" size="5">Test-3<br>
<input name="test_4" onkeyup="berech(this.value,text_1,text_2,text_3,wert_1,wert_2,ausgabe_1,ausgabe_2)" value="8" type="text" size="5">Test-4<br><br>
<input name="wert_1" value="3" type="hidden" size="5">
<input name="wert_2" value="4" type="hidden" size="5">
<input name="ausgabe_1" value="10" type="text" size="5">Ausgabe<br>
<input name="ausgabe_2" value="20" type="text" size="5">Ausgabe<br><br>
</form>
</body>
</html>
als Antwort auf: [#230650]