Cytat(pys1986 @ 2005-03-07 17:29:33)
Czy moze mi ktos napisac jak zrobic aby: w kwadracie o wymiarach np. 100x200 przesowaly sie obrazki tak jak napisy koncowe na filmie, to maja byc reklamy ktore beda jezdzily w kolko?
Tu masz scrypt do toplayera:
Kod
<script language="JavaScript">
/*
detekcja przegl±darek
*/
msie_50 = ( navigator.appName.indexOf('Explorer')!=-1 && navigator.appVersion.substr(navigator.appVersion.indexOf("MSIE")+5,3) >= 5.0 && navigator.appVersion.substr(navigator.appVersion.indexOf("MSIE")+5,3) < 5.5 ) ? true : false;
msie_55 = ( navigator.appName.indexOf('Explorer')!=-1 && navigator.appVersion.substr(navigator.appVersion.indexOf("MSIE")+5,3) >= 5.5 && navigator.appVersion.substr(navigator.appVersion.indexOf("MSIE")+5,3) < 6.0 ) ? true : false;
msie_50_and_greater = ( navigator.appName.indexOf('Explorer')!=-1 && navigator.appVersion.substr(navigator.appVersion.indexOf("MSIE")+5,3) >= 5.0) ? true : false;
/*
funkcja do pokazywania warstwy z toplayerem
*/
function ShowToplayer(){
document.getElementById("Toplayer").style.visibility = "visible"
}
/*
funkcja do ukrywania warstwy z toplayerem
- uruchamiana po kliknieciu na zamknij w swf'ie toplayer.swf
*/
function HideToplayer(){
document.getElementById("Toplayer").style.visibility = "hidden"
}
/*
funkcja do otwierania strony http://forum.php.pl/index.php?
- uruchamiana po kliknięciu na sprawdĄ szczegóły w swf'ie toplayer.swf
*/
function openURL(){
window.open('http://forum.php.pl/index.php?', '','')
}
</script>
<body onLoad="ShowToplayer();">
<script language="JavaScript">
if (msie_50 || msie_55 || msie_50_and_greater){
document.write('<div id="Toplayer" style="position:absolute; top:60px; left:300px; width:370px; height:320px; z-index:5; visibility: hidden;">');
document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="370" height="320">')
document.write('<param name="movie" value="http://reklama.onet.pl/bannery/fiat/top/banner_range.swf">')
document.write('<param name="quality" value="high">')
document.write('<param name="wmode" value="transparent">')
document.write('</object>')
document.write('</div>')
}
</script>
</body>