Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

JavaScript Checkbox Addition

Status
Not open for further replies.

nainil

IS-IT--Management
Jun 18, 2005
6
US
Hi,

I am a newbiee in JavaScript.
minn-pt-questionnaire-checkbox.jpg

I am attaching an image which will explain exactly wat I want. Firstly I have 4 rows (namely 0, 1, 2, 3). I want only 1 checkbox to be selected from amongst these at any given point of time. Once the visitor checks all the rows the rows should have an individual sum. Plus all the individual sums should be added together into the TOTAL.

How would the code look in JavaScript? Please help.

Nainil C.
 
If you only want one in the group to be checked, use a radio button.

Jon

"I don't regret this, but I both rue and lament it.
 
Thanks. But even if I use a Radio Button ... how would I be able to do the Additions? I am not much aware of the coding for the same.

And the reason why I am using the check boxes is that they look better when they are printed while the radio buttons don't.

Nainil C.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top