Hi
I am trying to toggle class for any click in form textboxes click.it is working fine in IE 9 but not in Chrome and Firefox!
Can you please let me know why this code is not working in Chrome and Firefox?
- <script type="text/x-javascript">
- $(document).ready(function() {
- $("#txt_1").bind('focus blur',function(){
- $("div.TextBox_Box1").toggleClass('bgcol');
- });
- });
- </script>
txt_1 is a TextBox which is surronded by a div called bgcol
bgcol is a class in CSS as:
- .bgcol{
background-color:#FFF7c0;
}
Thanks for your help