Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #26840

Re: FireFox onclick problem

From "Mel Smith" <syntel@cox.net>
Newsgroups comp.lang.javascript
Subject Re: FireFox onclick problem
Date 2015-02-10 14:55 -0700
Message-ID <cjvd2sFbke3U1@mid.individual.net> (permalink)
References <cjuvd1F7thrU1@mid.individual.net> <XnsA43DD0F0D8751eejj99@194.109.133.133>

Show all headers | View raw


Evertjan said:
> Works fine here also in FF.
>
> ==============
>
> I would use a more general solution for the function,
> if the <input> is a always direct child:
>
> <script type='text/javascript'>
> function hideParent(x) {
>   x.parentNode.style.display = "none";
> };
> </script>
>
> <div>
> <input type="button" onclick="hideParent(this);" value="Hide Parent">
> lots of text and <br> here
> </div>

Hi Evertjan:

    Tried your general method above. Same failed result.

    Again, current versions of IE and Chrome work correctly, immediately 
hiding the 'notice' division. But using FF: nothing happens.

    So, I reverted to my original code (as shown in my original post) for 
now, and will try 'debugging'.  But its so simple and the other browsers 
work and have worked for years with this code. Sigh ...

-Mel

Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

FireFox onclick problem "Mel Smith" <syntel@cox.net> - 2015-02-10 11:02 -0700
  Re: FireFox onclick problem "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2015-02-10 20:32 +0100
    Re: FireFox onclick problem "Mel Smith" <syntel@cox.net> - 2015-02-10 14:55 -0700
  Re: FireFox onclick problem Joao Rodrigues <groups_jr-1@yahoo.com.br> - 2015-02-10 19:34 -0200
    Re: FireFox onclick problem "Mel Smith" <syntel@cox.net> - 2015-02-10 15:21 -0700
  Re: FireFox onclick problem "Christoph M. Becker" <cmbecker69@arcor.de> - 2015-02-10 23:37 +0100
    Re: FireFox onclick problem "Mel Smith" <syntel@cox.net> - 2015-02-10 16:21 -0700

csiph-web