Connecting Tech Pros Worldwide Forums | Help | Site Map

odd javascript behaviour with Safari??

Geoff Cox
Guest
 
Posts: n/a
#1: Jun 27 '08
Hello,

I am using Safari (v3.1.1) on a PC and click on an image to play a
sound. Once the sound is finished 2 images appear and the user has to
select one of them.

This works perfectly well with IE, FF and Opera but with Safari the 2
images only appear if you move the mouse cursor after the sound has
finished!!

Why?

Cheers

Geoff
Evertjan.
Guest
 
Posts: n/a
#2: Jun 27 '08

re: odd javascript behaviour with Safari??


Geoff Cox wrote on 15 mei 2008 in comp.lang.javascript:
Quote:
I am using Safari (v3.1.1) on a PC and click on an image to play a
sound. Once the sound is finished 2 images appear and the user has to
select one of them.
>
This works perfectly well with IE, FF and Opera but with Safari the 2
images only appear if you move the mouse cursor after the sound has
finished!!
>
Why?
Since we just all lost our christal balls,
better post the relevant code.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Geoff Cox
Guest
 
Posts: n/a
#3: Jun 27 '08

re: odd javascript behaviour with Safari??


On 15 May 2008 20:26:58 GMT, "Evertjan."
<exjxw.hannivoort@interxnl.netwrote:
Quote:
>Geoff Cox wrote on 15 mei 2008 in comp.lang.javascript:
>
Quote:
>I am using Safari (v3.1.1) on a PC and click on an image to play a
>sound. Once the sound is finished 2 images appear and the user has to
>select one of them.
>>
>This works perfectly well with IE, FF and Opera but with Safari the 2
>images only appear if you move the mouse cursor after the sound has
>finished!!
>>
>Why?
>
>Since we just all lost our christal balls,
>better post the relevant code.
OK!

t = what.id.substring(1,2);
what.onclick = '';
what.src = played.src;
soundManager.createSound({
id:'mySound'+t,
url:'../assets/audio/Track' + (+t) + '.mp3',
onfinish:function(){document.getElementById('test' +t+1).className =
'visibleDiv2'} });
soundManager.play('mySound'+t);
count++;

it appears that to get the onfinish part to work you have to move the
cursor. I am being told by others that Safari has a bug related to
this. Know of anything?

Cheers

Geoff
Evertjan.
Guest
 
Posts: n/a
#4: Jun 27 '08

re: odd javascript behaviour with Safari??


Geoff Cox wrote on 15 mei 2008 in comp.lang.javascript:
Quote:
On 15 May 2008 20:26:58 GMT, "Evertjan."
<exjxw.hannivoort@interxnl.netwrote:
>
Quote:
>>Geoff Cox wrote on 15 mei 2008 in comp.lang.javascript:
>>
Quote:
>>I am using Safari (v3.1.1) on a PC and click on an image to play a
>>sound. Once the sound is finished 2 images appear and the user has to
>>select one of them.
>>>
>>This works perfectly well with IE, FF and Opera but with Safari the 2
>>images only appear if you move the mouse cursor after the sound has
>>finished!!
>>>
>>Why?
>>
>>Since we just all lost our christal balls,
>>better post the relevant code.
>
OK!
>
t = what.id.substring(1,2);
what.onclick = '';
what.src = played.src;
soundManager.createSound({
id:'mySound'+t,
url:'../assets/audio/Track' + (+t) + '.mp3',
onfinish:function(){document.getElementById('test' +t+1).className =
'visibleDiv2'} });
soundManager.play('mySound'+t);
count++;
>
it appears that to get the onfinish part to work you have to move the
cursor. I am being told by others that Safari has a bug related to
this. Know of anything?
It will depend on what soundManager means.

On the web iI read:
"SoundManager has been deprecated in favour of SoundManager 2"

Would that help?

Anyway, you will need a specialist on flash, not on javascript, meseems,
as in your code there is no <img>, no onmousemove=.

I think wrong NG.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Geoff Cox
Guest
 
Posts: n/a
#5: Jun 27 '08

re: odd javascript behaviour with Safari??


On 15 May 2008 21:56:15 GMT, "Evertjan."
<exjxw.hannivoort@interxnl.netwrote:
Quote:
>Geoff Cox wrote on 15 mei 2008 in comp.lang.javascript:
>
Quote:
>On 15 May 2008 20:26:58 GMT, "Evertjan."
><exjxw.hannivoort@interxnl.netwrote:
>>
Quote:
>>>Geoff Cox wrote on 15 mei 2008 in comp.lang.javascript:
>>>
>>>I am using Safari (v3.1.1) on a PC and click on an image to play a
>>>sound. Once the sound is finished 2 images appear and the user has to
>>>select one of them.
>>>>
>>>This works perfectly well with IE, FF and Opera but with Safari the 2
>>>images only appear if you move the mouse cursor after the sound has
>>>finished!!
>>>>
>>>Why?
>>>
>>>Since we just all lost our christal balls,
>>>better post the relevant code.
>>
>OK!
>>
>t = what.id.substring(1,2);
>what.onclick = '';
>what.src = played.src;
>soundManager.createSound({
>id:'mySound'+t,
>url:'../assets/audio/Track' + (+t) + '.mp3',
>onfinish:function(){document.getElementById('test '+t+1).className =
>'visibleDiv2'} });
>soundManager.play('mySound'+t);
>count++;
>>
>it appears that to get the onfinish part to work you have to move the
>cursor. I am being told by others that Safari has a bug related to
>this. Know of anything?
>
>It will depend on what soundManager means.
>
>On the web iI read:
>"SoundManager has been deprecated in favour of SoundManager 2"
>
>Would that help?
No, 'afraid not, soundManager is OK, the other files are
soundmanager2.js and soundmanager2.swf.

Thanks anyway,

Cheers

Geoff

Quote:
>
>Anyway, you will need a specialist on flash, not on javascript, meseems,
>as in your code there is no <img>, no onmousemove=.
>
>I think wrong NG.
Closed Thread