misha.korolcov,
<div id="ezmain">
<fieldset class="bordformt" style="border: 2px solid #0066B3;">
<legend class="bordformt" align="center" style="border: 0px solid #0066B3; padding:
5px 20px; margin- left: 20px;">
<center>Camarilla Pivot Trading Calculator</center>
</legend></fieldset>
</br>
<form id="campivot" name="campivot" style="background-color: white;">
<div id="ezchild">
<fieldset class="bordformt" style="border: 1px solid #0066B3;">
<legend class="bordformt" align="left" style="border: 1px solid #0066B3; padding: 4px 11px; margin- left: 20px;">Camarilla Trade Range</legend>
<table width='100%'>
<tr>
<td width='40%'>Camarilla Level- H4 ↑</td>
<td width='60%' ><input id="res4" class="widgetext"></td>
</tr>
<tr>
<td width=‘40%’>Camarilla Level- H3 ↓</td>
<td width=‘60%’>: <input class="widgetext" id="res3" name="res3" size="30" type="text" /></td>
</tr>
<tr>
<td width=‘40%’>Camarilla Level- H2 ↔</td>
<td width=‘60%’>: <input class="widgetext" id="res2" name="res2" size="30" type="text" /></td>
</tr>
<tr>
<td width=‘40%’>Camarilla Level- H1 ↔</td>
<td width=‘60%’>: <input class="widgetext" id="res1" name="res1" size="30" type="text" /></td>
</tr>
<tr>
<td width=‘40%’>Camarilla Level- L1 ↔</td>
<td width=‘60%’>: <input class="widgetext" id="sup1" name="sup1" size="30" type="text" /></td>
</tr>
<tr>
<td width=‘40%’>Camarilla Level- L2 ↔</td>
<td width=‘60%’>: <input class="widgetext" id="sup2" name="sup2" size="30" type="text" /></td>
</tr>
<tr>
<td width=‘40%’>Camarilla Level- L3 ↑</td>
<td width=‘60%’>: <input class="widgetext" id="sup3" name="sup3" size="30" type="text" /></td>
</tr>
<tr>
<td width=‘40%’>Camarilla Level- L4 ↓</td>
<td width=‘60%’>: <input class="widgetext" id="sup4" name="sup4" size="30" type="text" /></td>
</tr>
<tr></tr>
<tr></tr>
</table>
</fieldset>
<br />
<fieldset class="bordformt" style="border: 1px solid #0066B3;">
<legend class="bordformt" align="left" style="border: 1px solid #0066B3; padding: 4px 11px; margin- left: 20px;">Enter The Current Price</legend>
<table width='100%'>
<tr>
<th width="30%">High Price :</th>
<th width="30%">Low Price :</th>
<th width="30%">Close Price :</th>
</tr>
<tr>
<td width="30%"><input class="widgetext" id="price2" name="price2" placeholder="5650" type="text" title="High Price" /></td>
<td width="30%"><input class="widgetext" id="price3" name="price3" placeholder="5560" type="text" title="Low Price" /></td>
<td width="30%"><input class="widgetext" id="price4" name="price4" placeholder="5610" type="text" title="Close Price" /></td>
</tr>
<tr></tr>
<tr></tr>
</table>
</fieldset>
<br />
<fieldset class="bordformt" style="border: 1px solid #0066B3;">
<legend class="bordformt" align="left" style="border: 1px solid #0066B3; padding: 4px 11px; margin- left: 20px;">Calculate the Level</legend>
</br>
<center>
<input onclick='calcamrlia(campivot);' value='Calculate' style='font-size:16px;width:115px;line-height:25px;font-weight:bold;' type='button' value='Camarilla Pivot Calculator' />
<input onclick='formreset();' value='Reset' style='font-size:16px;width:115px;line-height:25px;font-weight:bold;' type='button' value='Reset Calculator' />
</center>
</fieldset>
<br/>
</div>
</form></div>
<script>
function formreset() {
document.getElementById("campivot").reset();
}
function calcamrlia() {
var campivot = document.campivot;
if (!campivot.price2.value) {
alert("Please type the value in High Price field !");
return false;
} else if (!campivot.price3.value) {
alert("Please type the value in Low Price field !");
return false;
} else if (!campivot.price4.value) {
alert("Please type the value in Close price field !");
return false;
}
campivot.sup1.value = Math.round((1 * campivot.price4.value - (1 * campivot.price2.value - 1 * campivot.price3.value) * 1.1 / 12) * 1000) / 1000;
campivot.sup2.value = Math.round((1 * campivot.price4.value - (1 * campivot.price2.value - 1 * campivot.price3.value) * 1.1 / 6) * 1000) / 1000;
campivot.sup3.value = Math.round((1 * campivot.price4.value - (1 * campivot.price2.value - 1 * campivot.price3.value) * 1.1 / 4) * 1000) / 1000;
campivot.sup4.value = Math.round((1 * campivot.price4.value - (1 * campivot.price2.value - 1 * campivot.price3.value) * 1.1 / 2) * 1000) / 1000;
campivot.res1.value = Math.round((1 * campivot.price4.value + (1 * campivot.price2.value - 1 * campivot.price3.value) * 1.1 / 12) * 1000) / 1000;
campivot.res2.value = Math.round((1 * campivot.price4.value + (1 * campivot.price2.value - 1 * campivot.price3.value) * 1.1 / 6) * 1000) / 1000;
campivot.res3.value = Math.round((1 * campivot.price4.value + (1 * campivot.price2.value - 1 * campivot.price3.value) * 1.1 / 4) * 1000) / 1000;
campivot.res4.value = Math.round((1 * campivot.price4.value + (1 * campivot.price2.value - 1 * campivot.price3.value) * 1.1 / 2) * 1000) / 1000;
}
</script>