Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    Regular Coder
    Join Date
    Jun 2007
    Location
    Los Angeles
    Posts
    545
    Thanks
    81
    Thanked 5 Times in 5 Posts

    Disabling button in Firefox trick?

    Is there a trick to being able to disable a button in FF3? The following code works in IE7 but not FF3 or Safari:

    PHP Code:
    document.getElementById("update_button").disabled true
    RalphF
    Business Text Messaging Services
    https://www.MobileTextingService.com

  • #2
    Regular Coder
    Join Date
    Mar 2006
    Posts
    726
    Thanks
    35
    Thanked 132 Times in 123 Posts
    document.getElementById("update_button").disabled = 'disabled';

    Not all browsers have a default visual style for disabled- you may need to define it yourself.

    You can use css to apply a custom style to buttons with the 'disabled' attribute,
    or use js to change the style (or className) of a button inline, when you disable it.
    Last edited by mrhoo; 08-03-2008 at 11:16 PM.

  • Users who have thanked mrhoo for this post:

    rfresh (08-04-2008)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •