• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Checkbox usage

 
Ranch Hand
Posts: 237
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am trying to use a checkbox. The value for the checkboxes are generated dynamically from a database.
I tried creating the checkboxes using plain HTML but that doesn't seem to give the correct answers. On checking some web sites, I noticed that most of them are using JavaScript to do the same.
Can someone tell me, if JavaScript is absolutely essential in order to get this done? Or, if I can do it using plain HTML?
I'd appreciate feedback at the earliest.
Thanks,
Saket
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What are you trying to do?? You seemed to have seat around the bush with what you are trying to accomplish
Eric
 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
No JavaScript is necessary for straight-forward checkbox usage.
You haven't really explained what it is you are trying to do, and what's not working for you.
bear
 
Saket Barve
Ranch Hand
Posts: 237
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My apologies for being unclear. Thanks for you initiative to help me out.
The web page I am workig on consists of the following fields, in a table:
Number Applicant Name ...... Checkbox.
1 A
2 B
.. .. ..
The checkbox contains one value from one of the fields above, the rest are sent in as hidden values.
All the data (viz. NUmber, Applicant Name, etc.) is retrieved dynamically from a database.
I notice that the dynamically generated data, sent as values of the checkbox option to a new page doesn't display the correct values.
For e.g. regardless of where I may have clicked on the checkbox, it'll show the same value over and over again. Page refresh, cookie deletion, clearing old files is all done to get get the same response.
Any ideas?
Saket
 
Bear Bibeault
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Still not clear but if the value you think you are setting for your checkbox is not correct, it may be as simple as malformed HTML being generated by whatever means you are using on the server (JSP perhaps?).
Why not do a "view source" in your browser, cut and paste the relevant part of the HTML page, and post it here for inspection (be sure to use the UBB code tags to preserve its formatting).
hth,
bear
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic