• 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
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

JSP : 508 Compliant

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a JSP, its a multiple search criteria page. I provided 5 checkboxes where user can select any number of checkboxes to continue with search process.

When the user select any search criteia thru checkbox, The drop-down list has been deisplayed which allow the user to select options. I am using Javascript to make the dropdown visible/invisible as per checkbox checked.

Now, when I put my webpage for 508 compliance, the problem is, On the JSP page I have all the dropdowns and its just invisible but when the audio plays it speaks all the dropdowns apart from the fact if it was selected by checkbox creteria.

so i need suggestion, how can only generate that HTML from jsp whose checkbox is checked for selection creteria.
 
maverick Mohan
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is there a way? In which I can check if the Checkbox has been checked on the JSP and put a "IF" condition around my dropdowns in JSP, so they will only be generated in HTML if checkbox is checked.

I know how to know if checkbox is checked using Javascript, but I think I have to submit a page to know if checkbox is checked using Java.

or can i do something with pagecontext parameter of JSP, please let me know, your suggestions
 
Sheriff
Posts: 67752
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

Originally posted by maverick Mohan:
Is there a way? In which I can check if the Checkbox has been checked on the JSP and put a "IF" condition around my dropdowns in JSP, so they will only be generated in HTML if checkbox is checked.

No. The JSP is processed on the server before it is sent to the browser. So by the time the user can interact with the checkbox, all JSP activity is long over. You'll need to use JavaScript for all client-side activity.

Please see this article for information on how JSPs are processed.
 
author & internet detective
Posts: 42003
911
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Maverick,
Welcome to JavaRanch!

There are other ways to make things 508 complaint. I'd make a suggestion, but I don't follow what is in your form and their relationships. Which might be a sign that things are complicated. (or your description doesn't include certain information.) If the form is complicated, it could have usability issues that go beyond 508.

Can you explain a couple of steps of what the user clicks and what they should see?
 
maverick Mohan
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Jeanne,

I understand the solution with the last post. But I need one small suggestion for 508 Compliance. I am using struts <html:text> tag.

I need to put some information about the text box, which is long enough e.g: the format of dates, or if its a required field and etc.

Do you recommend , that I should use "title" or "alt", to put information which is about a sentence long for my <html:text> textbox.
 
Jeanne Boyarsky
author & internet detective
Posts: 42003
911
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Maverick,
Title. (We use alt for short things to read for forms.) Anything long should be a title.

Note that you should also use the label tag to link form fields to the "label" describing what they are on screen. This checklist gives more tips including some others for forms.
 
I have gone to look for myself. If I should return before I get back, keep me here with this tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic