Ta strona została wykonana z użyciem technologii Flash. Posiadasz starszą
wersję Flash Player'a,
która nie potrafi poprawnie wyświetlić zawartości strony, którą
stworzyliśmy.
Dlaczego nie zaktualizować do najnowszej wersji teraz? To
zajmie tylko chwilę.
Wybierz system operacyjny oraz przeglądarkę i zainstaluj Flash'a. To łatwe!
Zapraszamy na www.redglobe.pl!
This web site makes use of Flash software. You have an old version of Flash
Player
that cannot play the content we've created.
Why not download and install the latest version now? It will
only take a moment.
Choose operating system and browser and install Flash. It's easy!
We invite to www.redglobe.pl!
PL Wykrywanie wersji flasha -
poniżej info tylko dla zainteresowanych webmasterów (Działa pod Win, Mac,
Lnx).
EN Flash Player version detection - below information
only for interested webmasters (It works on Win, Mac, Lnx):
<html>
<head>
<script type="text/JavaScript" src="AC_FL_RunContent_detection.js">
</script>
<script type="text/javascript" src="AC_RunActiveContent.js">
</script>
<script type="text/javascript" src="AC_ActiveX.js">
</script> //ta linia z AC_ActiveX.js nie jest niezbedna, jest potrzebna tylko dla IE,
ale AC_ActiveX.js jest instalowany wraz z nowym Flash Player'em/this line with AC_ActiveX.js is not essential!
It is needed for IE browser, but AC_ActiveX.js installed by downloading new Flash Player for IE.
</head>
<body>
<!--url's used in the movie--><script type="text/JavaScript" src="swf_file_loader.js">
</script> <noscript>
<p class="noscript1">Ta animacja wymaga<br />
Macromedia Flash Player<br />
oraz włączonej obsługi JavaScript.<br />
/This animation requires<br />
the Macromedia Flash Player<br />
and the JavaScript service on.<br />
<a href="http://www.macromedia.com/go/getflash/">Pobierz Flash/Get Flash</a></p>
</noscript>
</body>
</html>
PL A teraz kolejno zawartość skryptów z sekcji head i
body. Należy je umieścić w oddzielnych plikach z rozszerzeniem *.js
EN And now in turn content of scripts from head and body
sections. It has to put them in separate files with file extension *.js:
//head:
//AC_FL_RunContent_detection.js:
AC_FL_RunContent = 0;
DetectFlashVer = 0;
// -----------------------------------------------------------------------------
// Ogólne/General
// Wymagana jest nowsza wersja programu Flash/newer Flash version required
var requiredMajorVersion = 9;
// Wymagana jest starsza wersja programu Flash/older Flash version required
var requiredMinorVersion = 0;
// Wymagana jest poprawiona wersja programu Flash/better Flash version required
var requiredRevision = 45;
// -----------------------------------------------------------------------------
//AC_RunActiveContent.js:
//v1.7
// Flash Player Version Detection
// Detect Client Browser type
// Copyright 2005-2007 Adobe Systems Incorporated. All rights reserved.
var isIE = (navigator.appVersion.indexOf("MSIE") != -1) ? true : false;
var isWin = (navigator.appVersion.toLowerCase().indexOf("win") != -1) ? true : false;
var isOpera = (navigator.userAgent.indexOf("Opera") != -1) ? true : false;
function ControlVersion()
{
var version;
var axo;
var e;
// NOTE : new ActiveXObject(strFoo) throws an exception if strFoo isn't in the registry
try {
// version will be set for 7.X or greater players
axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");
version = axo.GetVariable("$version");
} catch (e) {
}
if (!version)
{
try {
// version will be set for 6.X players only
axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");
// installed player is some revision of 6.0
// GetVariable("$version") crashes for versions 6.0.22 through 6.0.29,
// so we have to be careful.
// default to the first public version
version = "WIN 6,0,21,0";
// throws if AllowScripAccess does not exist (introduced in 6.0r47)
axo.AllowScriptAccess = "always";
// safe to call for 6.0r47 or greater
version = axo.GetVariable("$version");
} catch (e) {
}
}
if (!version)
{
try {
// version will be set for 4.X or 5.X player
axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.3");
version = axo.GetVariable("$version");
} catch (e) {
}
}
if (!version)
{
try {
// version will be set for 3.X player
axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.3");
version = "WIN 3,0,18,0";
} catch (e) {
}
}
if (!version)
{
try {
// version will be set for 2.X player
axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash");
version = "WIN 2,0,0,11";
} catch (e) {
version = -1;
}
}
return version;
}
// JavaScript helper required to detect Flash Player PlugIn version information
function GetSwfVer(){
// NS/Opera version >= 3 check for Flash plugin in plugin array
var flashVer = -1;
if (navigator.plugins != null && navigator.plugins.length > 0) {
if (navigator.plugins["Shockwave Flash 2.0"] || navigator.plugins["Shockwave Flash"]) {
var swVer2 = navigator.plugins["Shockwave Flash 2.0"] ? " 2.0" : "";
var flashDescription = navigator.plugins["Shockwave Flash" + swVer2].description;
var descArray = flashDescription.split(" ");
var tempArrayMajor = descArray[2].split(".");
var versionMajor = tempArrayMajor[0];
var versionMinor = tempArrayMajor[1];
var versionRevision = descArray[3];
if (versionRevision == "") {
versionRevision = descArray[4];
}
if (versionRevision[0] == "d") {
versionRevision = versionRevision.substring(1);
} else if (versionRevision[0] == "r") {
versionRevision = versionRevision.substring(1);
if (versionRevision.indexOf("d") > 0) {
versionRevision = versionRevision.substring(0, versionRevision.indexOf("d"));
}
}
var flashVer = versionMajor + "." + versionMinor + "." + versionRevision;
}
}
// MSN/WebTV 2.6 supports Flash 4
else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.6") != -1) flashVer = 4;
// WebTV 2.5 supports Flash 3
else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.5") != -1) flashVer = 3;
// older WebTV supports Flash 2
else if (navigator.userAgent.toLowerCase().indexOf("webtv") != -1) flashVer = 2;
else if ( isIE && isWin && !isOpera ) {
flashVer = ControlVersion();
}
return flashVer;
}
// When called with reqMajorVer, reqMinorVer, reqRevision returns true if that version or greater is available
function DetectFlashVer(reqMajorVer, reqMinorVer, reqRevision)
{
versionStr = GetSwfVer();
if (versionStr == -1 ) {
return false;
} else if (versionStr != 0) {
if(isIE && isWin && !isOpera) {
// Given "WIN 2,0,0,11"
tempArray = versionStr.split(" "); // ["WIN", "2,0,0,11"]
tempString = tempArray[1]; // "2,0,0,11"
versionArray = tempString.split(","); // ['2', '0', '0', '11']
} else {
versionArray = versionStr.split(".");
}
var versionMajor = versionArray[0];
var versionMinor = versionArray[1];
var versionRevision = versionArray[2];
// is the major.revision >= requested major.revision AND the minor version >= requested minor
if (versionMajor > parseFloat(reqMajorVer)) {
return true;
} else if (versionMajor == parseFloat(reqMajorVer)) {
if (versionMinor > parseFloat(reqMinorVer))
return true;
else if (versionMinor == parseFloat(reqMinorVer)) {
if (versionRevision >= parseFloat(reqRevision))
return true;
}
}
return false;
}
}
function AC_AddExtension(src, ext)
{
if (src.indexOf('?') != -1)
return src.replace(/\?/, ext+'?');
else
return src + ext;
}
function AC_Generateobj(objAttrs, params, embedAttrs)
{
var str = '';
if (isIE && isWin && !isOpera)
{
str += '<object ';
for (var i in objAttrs)
{
str += i + '="' + objAttrs[i] + '" ';
}
str += '>';
for (var i in params)
{
str += '<param name="' + i + '" value="' + params[i] + '" /> ';
}
str += '</object>';
}
else
{
str += '<embed ';
for (var i in embedAttrs)
{
str += i + '="' + embedAttrs[i] + '" ';
}
str += '> </embed>';
}
document.write(str);
}
function AC_FL_RunContent(){
var ret =
AC_GetArgs
( arguments, ".swf", "movie", "clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"
, "application/x-shockwave-flash"
);
AC_Generateobj(ret.objAttrs, ret.params, ret.embedAttrs);
}
function AC_SW_RunContent(){
var ret =
AC_GetArgs
( arguments, ".dcr", "src", "clsid:166B1BCA-3F9C-11CF-8075-444553540000"
, null
);
AC_Generateobj(ret.objAttrs, ret.params, ret.embedAttrs);
}
function AC_GetArgs(args, ext, srcParamName, classid, mimeType){
var ret = new Object();
ret.embedAttrs = new Object();
ret.params = new Object();
ret.objAttrs = new Object();
for (var i=0; i < args.length; i=i+2){
var currArg = args[i].toLowerCase();
switch (currArg){
case "classid":
break;
case "pluginspage":
ret.embedAttrs[args[i]] = args[i+1];
break;
case "src":
case "movie":
args[i+1] = AC_AddExtension(args[i+1], ext);
ret.embedAttrs["src"] = args[i+1];
ret.params[srcParamName] = args[i+1];
break;
case "onafterupdate":
case "onbeforeupdate":
case "onblur":
case "oncellchange":
case "onclick":
case "ondblclick":
case "ondrag":
case "ondragend":
case "ondragenter":
case "ondragleave":
case "ondragover":
case "ondrop":
case "onfinish":
case "onfocus":
case "onhelp":
case "onmousedown":
case "onmouseup":
case "onmouseover":
case "onmousemove":
case "onmouseout":
case "onkeypress":
case "onkeydown":
case "onkeyup":
case "onload":
case "onlosecapture":
case "onpropertychange":
case "onreadystatechange":
case "onrowsdelete":
case "onrowenter":
case "onrowexit":
case "onrowsinserted":
case "onstart":
case "onscroll":
case "onbeforeeditfocus":
case "onactivate":
case "onbeforedeactivate":
case "ondeactivate":
case "type":
case "codebase":
case "id":
ret.objAttrs[args[i]] = args[i+1];
break;
case "width":
case "height":
case "align":
case "vspace":
case "hspace":
case "class":
case "title":
case "accesskey":
case "name":
case "tabindex":
ret.embedAttrs[args[i]] = ret.objAttrs[args[i]] = args[i+1];
break;
default:
ret.embedAttrs[args[i]] = ret.params[args[i]] = args[i+1];
}
}
ret.objAttrs["classid"] = classid;
if (mimeType) ret.embedAttrs["type"] = mimeType;
return ret;
}
//AC_ActiveX.js:
//v1.1
//Copyright 2006 Adobe Systems, Inc. All rights reserved.
function AC_AX_RunContent(){
var ret = AC_AX_GetArgs(arguments);
AC_Generateobj(ret.objAttrs, ret.params, ret.embedAttrs);
}
function AC_AX_GetArgs(args){
var ret = new Object();
ret.embedAttrs = new Object();
ret.params = new Object();
ret.objAttrs = new Object();
for (var i=0; i < args.length; i=i+2){
var currArg = args[i].toLowerCase();
switch (currArg){
case "pluginspage":
case "type":
case "src":
ret.embedAttrs[args[i]] = args[i+1];
break;
case "data":
case "codebase":
case "classid":
case "id":
case "onafterupdate":
case "onbeforeupdate":
case "onblur":
case "oncellchange":
case "onclick":
case "ondblClick":
case "ondrag":
case "ondragend":
case "ondragenter":
case "ondragleave":
case "ondragover":
case "ondrop":
case "onfinish":
case "onfocus":
case "onhelp":
case "onmousedown":
case "onmouseup":
case "onmouseover":
case "onmousemove":
case "onmouseout":
case "onkeypress":
case "onkeydown":
case "onkeyup":
case "onload":
case "onlosecapture":
case "onpropertychange":
case "onreadystatechange":
case "onrowsdelete":
case "onrowenter":
case "onrowexit":
case "onrowsinserted":
case "onstart":
case "onscroll":
case "onbeforeeditfocus":
case "onactivate":
case "onbeforedeactivate":
case "ondeactivate":
ret.objAttrs[args[i]] = args[i+1];
break;
case "width":
case "height":
case "align":
case "vspace":
case "hspace":
case "class":
case "title":
case "accesskey":
case "name":
case "tabindex":
ret.embedAttrs[args[i]] = ret.objAttrs[args[i]] = args[i+1];
break;
default:
ret.embedAttrs[args[i]] = ret.params[args[i]] = args[i+1];
}
}
return ret;
}
//body:
//swf_loader.js:
if (AC_FL_RunContent == 0 || DetectFlashVer == 0) {
alert("This website requires AC_RunActiveContent.js. Ta strona wymaga skryptu AC_RunActiveContent.js.");
} else {
var hasRightVersion = DetectFlashVer(requiredMajorVersion, requiredMinorVersion, requiredRevision);
if(hasRightVersion) { // if accepted version detected/jeśli została wykryta wersja akceptowalna
// load movie/osadź film flash; wartości zmiennych w skrypcie można zmieniać
/variable's value in script can be changed
AC_FL_RunContent(
'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,45,0',
'width', '100%',
'height', '300',
'src', 'name_of_your_movie',
'quality', 'best',
'pluginspage', 'http://www.macromedia.com/go/getflashplayer',
'align', 'middle',
'play', 'true',
'loop', 'true',
'scale', 'showall',
'wmode', 'transparent',
'devicefont', 'false',
'id', 'name_of_your_movie',
'bgcolor', '#ffffff',
'name', 'name_of_your_movie',
'menu', 'false',
'allowScriptAccess','sameDomain',
'movie', 'name_of_your_movie',
'salign', ''
); //end AC code
} else { // wersja programu Flash jest zbyt stara lub nie wykryto wtyczki/Flash version too old
or plugin not detected
var alternateContent = 'This content requires Adobe Flash Player. '
+ 'Ta zawartość wymaga programu Adobe Flash Player. '
+ '<a href="http://www.macromedia.com/go/getflash/">Pobierz Flash/Get Flash</a></p>';
document.write(alternateContent); // Wstaw zawartość z innego programu niż Flash/put in other content
}
}
//PL - wartość 'showall' parametru 'scale' umożliwia wyświetlenie swf w dowolnym rozmiarze według
ustalonych wartości width i height. Aby skrypt wyświetlał swf tylko w jednym ustalonym w czasie
jego tworzenia w programie Flash 8 rozmiarze należy dla parametru 'scale' ustalić wartość 'noscale'.
Skrypt powinien wyświetlać swf z przezroczystym tłem.
EN - value 'showall' of 'scale' parameter can play swf in any size according
to established values width and height. So as script played swf only in one size established during
it's rise in Flash 8 it is necessary to establish for parameter 'scale' value 'noscale'.
Script has to play swf with transparent background.
PL Po zrobieniu plików ze skryptami *.js należy w programie Flash 8 zrobić plik swf o następującym wyglądzie i parametrach.
EN After *.js files preparation make in Flash 8 swf file with following appearance and parameters:

PL Plik swf wykonujemy następująco:
Po otwarciu nowego dokumentu w programie FLash 8 we właściwościach ustalamy rozmiary (szerokość, długość) całego dokumentu
np. 158px x 158px. Następnie wybieramy narzędzie "Text Tool" (A) i tworzymy dwa pola tekstowe w polu roboczym:
1) u góry pola roboczego robimy pole tekstowe o wymiarach W=148,0 H=26,4 i położeniu X=5.0 Y=0.5.
We właściwościach (Properties) wybieramy kolejno opcje: Dynamic text, pod tym wpisujemy słowo - vers, rodzina czcionki - _sans,
rozmiar czcionki 20, kolor czcionki dowolny (np. #ff0000), wybieramy wyśrodkowanie tekstu, wybieramy typ lini (Line type)
jako Single line, reszta bez zmian.
2) poniżej robimy pole tekstowe o wymiarach W=148,0 H=130.7 i położeniu X=5.0 Y=26.9.
We właściwościach (Properties) wybieramy kolejno opcje: Dynamic text, pod tym wpisujemy słowo - feedback, rodzina czcionki - _sans,
rozmiar czcionki 12, kolor czcionki dowolny (np. #000000), wybieramy wyśrodkowanie tekstu, wybieramy typ lini (Line type)
jako Multiline, reszta bez zmian.
Tak zrobiony dokument zapisujemy jako np. flash_detection.fla plik programu Flash 8.
Następnie w pustym okienku opcji Actions wklejamy następujący Action script:
EN We make swf file as follows:
After opened new Flash document in Flash 8 in Properties we establish sizes (width, height) for all document
for example 158px x 158px. We select "Text Tool" (A) and make two text areas in working area:
1) in the top of working area we make first text area with sizes W=148,0 H=26,4 and with position X=5.0 Y=0.5.
In Properties we select options as follows: Dynamic text, under it we write word - vers, font family - _sans,
font size 20, font color any (example #ff0000), we select for text Align center, we select Line type
as Single line, the rest changes none.
2) Below we make second text area with sizes W=148,0 H=130.7 and with position X=5.0 Y=26.9.
In Properties we select options as follows: Dynamic text, under it we write word - feedback, font family - _sans,
font size 12, font color any (example #000000), we select for text Align center, we select Line type
as Multiline, the rest changes none.
Such document we save as for example flash_detection.fla file of Flash 8
and then in blank window of Actions we paste following Action script:
//Action script:
//trace(eval("$version"));
version = eval("$version");
//The operating system: WIN, MAC, LNX
var osType;
//The player versions. 9,0,115,0
var majorVersion; 9
var majorRevision; 0
var minorVersion; 115
var minorRevision; 0
vers.text = version;
osArray = version.split(' ');
osType = osArray[0];
versionArray = osArray[1].split(',');
majorVersion = versionArray[0];
majorRevision = versionArray[1];
minorVersion = versionArray[2];
minorRevision = versionArray[3];
feedback.text = "Operating System: "+osType + "\n" +
"Major Version: "+majorVersion + "\n" +
"Major Revision: "+majorRevision + "\n" +
"Minor Version: "+minorVersion + "\n" +
"Minor Revision: "+minorRevision;
trace("Operating System: "+osType);
trace("Major Version: "+majorVersion);
trace("Major Revision: "+majorRevision);
trace("Minor Version: "+minorVersion);
trace("Minor Revision: "+minorRevision);
PL Zapisany jako flash_detection.fla dokument publikujemy/eksportujemy jako plik swf: flash_detection.swf.
W ustawieniach publikowania (Publish settings) wybieramy jako Tryb okna (Window Mode) opcję Przezroczystość (Transparent Windowless)
oraz wyrównanie zawartości granego swf jako Flash alignment - horizontal i vertical center.
Nazwę flash_detection.swf wpisujemy zamiast 'name_of_your_movie' w skrypcie swf_loader.js.
EN Flash 8 document saved as flash_detection.fla we publish/export to swf file: flash_detection.swf.
In Publish settings we select in Window Mode Transparent Windowless and Flash alignment - horizontal and vertical both as center.
The name flash_detection.swf we write instead 'name_of_your_movie' in script swf_loader.js.
PL Jeśli chcemy, by po wykryciu wersji Flash Player'a starszej niż 10,0,42,34 automatycznie
otworzyła się w nowym oknie strona z propozycją aktualizaji Flash Player'a (podobna do tej)
do powyższego skryptu należy dodać na końcu:
EN If we want new website (similar with this) automatically opened in new window after detection
Flash version older than 10,0,42,34 we have to add in the End to above script following instruction:
if (majorVersion<10 || minorVersion<42) { getURL("info.html", "_blank"); } else { stop();}
PL - należy zrobić też stronkę o nazwie np. info.html z informacją o aktualizaji Flash Player'a,
żeby miało się co otworzyć;). Można też umieścić plik swf bezpośrednio na swojej stronie
wraz z sugestią aktualizaji, gdy Flash Player zbyt stary i linkiem do aktualizacji.
EN - you have to make website with name for example info.html with information about update Flash Player,
for something to open;). You can also put swf file directly in your website
with update suggestion, if Flash Player too old and with link to update.
