aria_roles.html 1000 B

123456789101112131415161718192021222324252627282930
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <title>ARIA roles test</title>
  5. <meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/>
  6. </head>
  7. <body>
  8. This page tests selected ARIA roles<br />
  9. (see <a href="http://www.w3.org/TR/wai-aria/">http://www.w3.org/TR/wai-aria/</a>)
  10. <div id="hidden-element-toggle-button" role="button">Toggle</div>
  11. <div id="hidden-element" style="display:none;">This content's visibility is changed by clicking the Toggle Button.</div>
  12. <!-- This link is created programmatically -->
  13. <div id="link-element"></div>
  14. <script language="javascript" type="text/javascript" src="js/jquery-1.6.2-min.js"></script>
  15. <script language="javascript" type="text/javascript">
  16. $(document).ready(function() {
  17. $('#hidden-element-toggle-button').click(function() {
  18. $('#hidden-element').toggle();
  19. });
  20. $('#link-element').attr('role', 'link').text('Go to Index').click(function() {
  21. window.location.href = 'index.html';
  22. });
  23. });
  24. </script>
  25. </body>
  26. </html>