Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.javascript > #32153
| Newsgroups | comp.lang.javascript |
|---|---|
| Subject | Re: onkeyup in Firefox (was: onkeyup not working for me in FireFox 50.1.0) |
| From | "Evertjan." <exxjxw.hannivoort@inter.nl.net> |
| References | <edfu3kFkfvbU1@mid.individual.net> <7279249.NyiUUSuA9g@PointedEars.de> <edgj5vFp050U1@mid.individual.net> <XnsA6F8632E65743eejj99@194.109.6.166> <edhve0F53soU1@mid.individual.net> |
| Date | 2017-01-09 19:19 +0100 |
| Message-ID | <XnsA6F8C496F75C1eejj99@194.109.6.166> (permalink) |
"Mel Smith" <syntel@cox.net> wrote on 09 Jan 2017 in comp.lang.javascript:
> Evertjan said:
>
>>> function chkforret(el) {
>>
>> Where do you use this el ????
>
> I did use 'el' in several previous iterations of testing, but do not
> do
> so now, and forgot to remove it. (Will do so today)
>
> Also, checked out Safari Version 5.1.7 (7534.57.2) on my dev PC
> today,
> and it works 'correctly'.
>
> So that leaves FF as 'odd-man-out' for now. (I haven't got Opera on
> my
> system because it is not frequently used in North America, and even less
> frequently among my 613 potential clients.)
>
>>
>>> // alert("in chkforret() now") ;
>>
>>> var e = event ;
>>> if (e===null) e = window.event ;
>>
>> Use instead:
>>
>> var e = event || window.event ;
>>
>
> Yes, will change this. Thanks !
>
>> BUT perhaps you ment:
>>
>> function chkforret(el) {
>> el = el || window.event;
>> ...
>>
>> ====
>>
>>> if (e.keyCode=="13") {
>>> gotret = true ;
>>> return false ;
>>> }
>>> gotret = false ;
>>> return true ;
>>>}
>>
>> Use instead:
>>
>> return ! (gotret = e.keyCode == 13);
>>
> O.K., will use this too. (but should I not use ""13"" instead ?
Why?
Does e.keyCode return a string?
Doesn't == do an automatic conversion,
while === is more strict?
>> Did you var gotret globally??
>
> YES
>
>> Do you use the return value?
>>
> I use the value of 'gotret' when returning to the 'onkeyup' clause
> to 'blur'. Then, the onblur clause operates.
So your answer is "no"?
> btw, thru my server software I read html templates, build, and send
> pages to clients, access and manipulate databases. I use the Harbour
> language for this (a Hi-C type of language). www.whosaway.com
Well, firefox is clientside, so that does not matter,
and serverside coding is off-topic here if it is not Javascript.
[I use serverside Javascript regularily]
> Next, I will be scratching my head and trying to re-learn AJAX.
Why?
> Used it
> a few years ago successfully. Since then, I've lost a lot of what I
> knew, and what I knew was then incomplete, wrong and now certainly
> out-of-date.
There is not much to learn, it is just interaction with a serverside page,
without leaving the clientside page.
> I am still bothered that 'onkeyup' is invisible to FF, whereas the
> three others I tested work for me
I really do not believe you on your word,
it would have been world news for the last 20 years.
Wouldn't it be that your code is faulty, and that other browsers are more
forgiving? Did you debug?
This works fine here, also in Firefox:
<textarea onkeyup='alert("Hi!");'></textarea>
> as Iexpected.
MS-Ie?
> Thanks for all the constructive suggestions above ! Will ensure they
> are implemented as you detailed.
NO! You should not ensuredly implement it, but
1 try to understand it.
2 then test it thoroughly.
Don't trust me, I might make an error like anyone else.
[even while some might think they do not]
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
onkeyup not working for me in FireFox 50.1.0 "Mel Smith" <syntel@cox.net> - 2017-01-08 15:51 -0700
onkeyup in Firefox (was: onkeyup not working for me in FireFox 50.1.0) Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-01-09 00:30 +0100
Re: onkeyup in Firefox (was: onkeyup not working for me in FireFox 50.1.0) "Mel Smith" <syntel@cox.net> - 2017-01-08 21:51 -0700
Re: onkeyup in Firefox (was: onkeyup not working for me in FireFox 50.1.0) "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2017-01-09 09:44 +0100
Re: onkeyup in Firefox (was: onkeyup not working for me in FireFox 50.1.0) "Mel Smith" <syntel@cox.net> - 2017-01-09 10:26 -0700
Re: onkeyup in Firefox (was: onkeyup not working for me in FireFox 50.1.0) "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2017-01-09 19:19 +0100
Re: onkeyup in Firefox Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2017-01-09 19:09 +0100
csiph-web