Opera 6 setTimeout not working?

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
User avatar
JAB Creations
DevNet Resident
Posts: 2341
Joined: Thu Jan 13, 2005 6:44 pm
Location: Sarasota Florida
Contact:

Opera 6 setTimeout not working?

Post by JAB Creations »

feyd | Please use

Code: Select all

,

Code: Select all

and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read:  [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]


The code works great in Opera 6 but only without the timeout. Old versions of [url=http://www.oldapps.com/opera.htm]Opera[/url] are available to download.

[b]Original JS Code[/b]
[syntax="javascript"]function hideDiv(divID_as_a_string) {
 var myReference = getRefToDiv(divID_as_a_string);
 if( !myReference ) { window.alert('Nothing works in this browser'); return; }
 if( myReference.style ) { myReference.style.visibility = 'hidden'; } else {
  if( myReference.visibility ) { myReference.visibility = 'hide'; } else {
   window.alert('Nothing works in this browser'); return; } }
}
Latest JS Attempt

Code: Select all

function hideTimedDiv(divID_as_a_string) {
setTimeout ("hideTimedDiv('" + divID_as_a_string + "',3000);"); {
var myReference = getRefToDiv(divID_as_a_string);
if(!myReference ) { window.alert('Nothing works in this browser'); return; }
if( myReference.style ) { myReference.style.visibility = 'hidden'; } else {
if( myReference.visibility ) { myReference.visibility = 'hide'; } else {
window.alert('Nothing works in this browser'); return; } }
}
}
HTML Event
<element onEVENT="hideTimedDiv('exampleb8');"

feyd | Please use[/syntax]

Code: Select all

,

Code: Select all

and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read:  [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
User avatar
AKA Panama Jack
Forum Regular
Posts: 878
Joined: Mon Nov 14, 2005 4:21 pm

Post by AKA Panama Jack »

Man, Opera 6 is OLD. Supporting Opera 6 would be like supporting IE 4 or Netscape 1. I mean we are up to Opera 9.

The last version of Opera 6 was released in 2002 or more than 4 years ago and it isn't really supported. You should move on to supporting more recent versions.
User avatar
JAB Creations
DevNet Resident
Posts: 2341
Joined: Thu Jan 13, 2005 6:44 pm
Location: Sarasota Florida
Contact:

Post by JAB Creations »

If you're not helping towards a solution you're working towards a problem.

IE 4, Netscape4, and Opera 5 and up all have enough CSS support that simple patches can make them work almost or as well as more modern browsers.

My question still stands unanswered.
Post Reply