Safari WIndows and Transparent Flash

后端 未结 2 1583
爱一瞬间的悲伤
爱一瞬间的悲伤 2021-01-19 10:55

// Edit: The issue now appears to be confined to Safari for Windows.

Around the time Safari for Windows 4 came out I started hearing from users that wmode=transpare

2条回答
  •  北海茫月
    2021-01-19 11:55

    UPDATE: The problem is with the flash player for windows safari but has been solved after Flash Player version 10.0.45.2

    Yes, It is only with Safari on Windows! And it's interesting that there is not much written about this on the internet I've been experiencing the same issue, I guessed at first that it has a default value of #FFFFFF for bgcolor and I tried setting it to transparent (not wmode but bgcolor!). it still works in every other browser but it had a green color in Safari (so don't try that! and no the bug is not with the word transparent not being defined! I tried!). Seems that we have to wait for apple to fix it in the next versions but if you want to change the background color if you only have a solid color underneath you can use:

    if you're using the adobe script or javascript to display the flash (recommended)

    
    
    
    >

    else if youre using embed and or for the

    
     
    

    ...aslo

    
     
    
    if you wanna detect safari on windows and not display it - or maybe give the the least zindex:
    
    //Javascript: 
    var isSafari = (navigator.userAgent.indexOf("Safari") != -1) ? true : false;
    var isWindows = (navigator.userAgent.indexOf("Windows") != -1) ? true : false;
    if (isSafari && isWindows) document.getElementById('yourflashid').style.display = 'none';
    if (isSafari && isWindows) document.getElementById('yourflashid').style.Zindex = '-1000';
    
    > if you have php it's better to do it with php as changing DOM elements with js makes page load slower and requires javascript

    
    
    #myflash {display:none;}
    #verisignflash {z-index:-100; /* for example I already made #000 bgcolor for this and looks right*/
    <?php } //All Safari's }

    ... and then the code for Safari in general as the rest seem to be compatible! however you can add and else statement here and seperat them

    If someone finds a better option I will be glad to read it here!

提交回复
热议问题