<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "
http://www.w3.org/TR/html4/loose.dtd"><html><head><meta http-equiv="content-type" content="text/html; charset=iso-8859-1"><title>Ingen titel</title>
<style type="text/css">html,body{height:100%;}</style>
<script type="text/javascript">
function calcinps(f){
inps=document.forms.formnavn.getElementsByTagName("input");
newvalue=0;
for(i=0;i<inps.length;i++){
if(inps[i].name.indexOf("felt_")==0)newvalue+=+inps[i].value;
}
alert(newvalue);
}
</script></head>
<body leftmargin="0" rightmargin="0" topmargin="0">
<form name="formnavn">
<input type="text" name="felt_1" value="12"><br>
<input type="text" name="felt_423" value="1"><br>
<input type="text" name="haha" value="1231342"><br>
<input type="text" name="felt_1232" value="2"><br>
<input type="text" name="felt_3456456" value="4"><br>
<b onclick="calcinps();">Sammentæl inputs med navn felt_etellerandet</b>
</form>
</body></html>