signman
12-26-2010, 02:00 PM
Hello, I wonder if you guys.girls would be kind enough to help me. I have some code, but I need to make the " Total price will be :$xx " text to be in bold.
Here is the code I have atm
<script type=text/javascript>
function getTotal(){
var form=document.theForm;
var inputs=form.getElementsByTagName('input');
var length=inputs.length;
var total='0';
for(i=0;i<length-1;i++){
if(inputs[i].type=='radio'){
var checked=inputs[i].checked?1:0;
if(checked){
var value=inputs[i].value.split("~~")[0];
total-=-value;
}
}
}
document.getElementById('totalspan').innerHTML="Total price will be: $"+total
total='0';
}
</script>
</html>
Here is the code I have atm
<script type=text/javascript>
function getTotal(){
var form=document.theForm;
var inputs=form.getElementsByTagName('input');
var length=inputs.length;
var total='0';
for(i=0;i<length-1;i++){
if(inputs[i].type=='radio'){
var checked=inputs[i].checked?1:0;
if(checked){
var value=inputs[i].value.split("~~")[0];
total-=-value;
}
}
}
document.getElementById('totalspan').innerHTML="Total price will be: $"+total
total='0';
}
</script>
</html>