accessKey 属性可设置或返回访问单选按钮的快捷键。
注释:请使用 Alt + accessKey 为拥有指定快捷键的元素赋予焦点。
radioObject.accessKey=accesskey
下面的例子可返回单选按钮的快捷键:
<html> <body> <form> Male: <input id="male" accesskey="m" type="radio" name="Sex" value="Male" /> <br /> Female: <input id="female" accesskey="f" type="radio" name="Sex" value="Female" /> </form> <p>The access key for the radio buttons are: <script type="text/javascript"> document.write(document.getElementById('male').accessKey
); document.write(" and "); document.write(document.getElementById('female').accessKey
); </script></p> </body> </html>
如对本文有疑问,请提交到交流论坛,广大热心网友会为你解答!! 点击进入论坛
Powered by 365建站网 RSS地图 HTML地图
copyright © 2013-2024 版权所有 鄂ICP备17013400号