I found a cm/inches/feet converter, and have altered it into a converter for calculating pack sizes for flooring ( see below)
Now here's the tricky bit, each of the flooring products has a different pack size (sqm), and in the properties tab we created a variable for that figure. Now, instead of having to manually change the pack meterage each time and adding it to each separate product, is it possible to use <actinic:variable name="PackMeterage" /> instead of a number in the calculations so I can just add it to the extended info layout for flooring?! Help would be greatly appreciated!!
- Suzy
<TABLE cellSpacing=0 cellPadding=0 width=250 border=0>
<FORM name=sqmpacks>
<TBODY>
<TR>
<TD>
<FONT face="Arial Narrow"><INPUT
onblur=sqmconvert() value=2.54 name=sqm> </FONT><FONT face="Arial Narrow"
size=-1>sqm</FONT></TD>
</TR>
<TR>
<TD>
<FONT face="Arial Narrow"><INPUT
onblur=packsconvert() value=1 name=packs> </FONT><FONT face=Arial
size=-1>packs</FONT></TD>
</TR>
<TR>
<TD width="50%">
<p align="center"><input type="button" value="Submit" name="B3"></p>
</TD>
</TR></TBODY></FORM></TABLE>
<SCRIPT language=JavaScript>
/*
cm/inch/feet converter - credit must stay intact for use
By Ada Shimar ada@chalktv.com
For this script and more,
Visit http://javascriptkit.com
*/
function roundit(which){
return Math.round(which*100)/100
}
function sqmconvert(){
with (document.sqmpacks){
packs.value = roundit(sqm.value/2.54);
}
}
function packsconvert(){
with (document.sqmpacks){
sqm.value = roundit(packs.value*2.54);
}
}
</SCRIPT>
<FORM name=sqmpacks>
<TBODY>
<TR>
<TD>
<FONT face="Arial Narrow"><INPUT
onblur=sqmconvert() value=2.54 name=sqm> </FONT><FONT face="Arial Narrow"
size=-1>sqm</FONT></TD>
</TR>
<TR>
<TD>
<FONT face="Arial Narrow"><INPUT
onblur=packsconvert() value=1 name=packs> </FONT><FONT face=Arial
size=-1>packs</FONT></TD>
</TR>
<TR>
<TD width="50%">
<p align="center"><input type="button" value="Submit" name="B3"></p>
</TD>
</TR></TBODY></FORM></TABLE>
<SCRIPT language=JavaScript>
/*
cm/inch/feet converter - credit must stay intact for use
By Ada Shimar ada@chalktv.com
For this script and more,
Visit http://javascriptkit.com
*/
function roundit(which){
return Math.round(which*100)/100
}
function sqmconvert(){
with (document.sqmpacks){
packs.value = roundit(sqm.value/2.54);
}
}
function packsconvert(){
with (document.sqmpacks){
sqm.value = roundit(packs.value*2.54);
}
}
</SCRIPT>
- Suzy
Comment