jquery - Piecemaker fallback -


i wondering if there way include fallback functionality piecemaker, when website viewed on mobile, page falls using javascript based slider.

any appreciated.

so think found way around following crayon1's vein of thought , changing how embeds flash fallback child html can included. requires changing 2 files:

javascriptflashgateway.js &

piecemaker-main.php (assuming we're talking wordpress plugin)

in javascriptflashgateway.js, find code:

function flashtag(src, width, height) {     this.src       = src;     this.width     = width;     this.height    = height;     this.version   = '9,0,0';     this.id        = null;     this.salign = "tl";     this.scale = "noscale";     this.allowscriptaccess = "always";     this.allowfullscreen = "true";     this.bgcolor   = 'ffffff';     this.flashvars = null;     this.wmode     = null; } 

and change this:

function flashtag(src, width, height, fallback) {     this.src       = src;     this.width     = width;     this.height    = height;     this.fallback  = fallback;     this.version   = '9,0,0';     this.id        = null;     this.salign = "tl";     this.scale = "noscale";     this.allowscriptaccess = "always";     this.allowfullscreen = "true";     this.bgcolor   = 'ffffff';     this.flashvars = null;     this.wmode     = null; } 

then further down find line: "flashtag.prototype.tostring = function()"

and replace entire function this:

flashtag.prototype.tostring = function() {     var ie = (navigator.appname.indexof ("microsoft") != -1) ? 1 : 0;     var flashtag = new string();     flashtag += '<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" ';     if (this.id != null)     {         flashtag += 'id="'+this.id+'" ';     }     flashtag += 'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version='+this.version+'" ';     flashtag += 'width="'+this.width+'" ';     flashtag += 'height="'+this.height+'">';     flashtag += '<param name="movie" value="'+this.src+'"/>';     flashtag += '<param name="quality" value="high"/>';     flashtag += '<param name="bgcolor" value="#'+this.bgcolor+'"/>';     flashtag += '<param name="scale" value="noscale"/>';     flashtag += '<param name="allowscriptaccess" value="always"/>';     flashtag += '<param name="salign" value="tl"/>';     flashtag += '<param name="allowfullscreen" value="true"/>';     flashtag += '<param name="wmode" value="transparent"/>';     if (this.flashvars != null)     {         flashtag += '<param name="flashvars" value="'+this.flashvars+'"/>';     }     if(!ie) {         flashtag += '<object type="application/x-shockwave-flash" ';         flashtag += 'data="'+this.src+'" ';         flashtag += 'width="'+this.width+'" ';         flashtag += 'height="'+this.height+'">';         flashtag += '<param name="movie" value="'+this.src+'"/>';         flashtag += '<param name="quality" value="high"/>';         flashtag += '<param name="bgcolor" value="#'+this.bgcolor+'"/>';         flashtag += '<param name="scale" value="noscale"/>';         flashtag += '<param name="allowscriptaccess" value="always"/>';         flashtag += '<param name="salign" value="tl"/>';         flashtag += '<param name="allowfullscreen" value="true"/>';         flashtag += '<param name="wmode" value="transparent"/>';         if (this.flashvars != null)         {             flashtag += '<param name="flashvars" value="'+this.flashvars+'"/>';         }     }     flashtag += this.fallback;     if(!ie) {         flashtag += '</object>';     }     flashtag += '</object>';     return flashtag; } 

then in piecemaker-main.php, find line: "var tag = new flashtag('{$this->piecemakerswf}', {$att['width']}+50, {$att['height']}+100, '9,0,0');"

and replace '9,0,0' whatever fallback html need.

then you're set! hope helps :)


Comments

Popular posts from this blog

java - SNMP4J General Variable Binding Error -

windows - Python Service Installation - "Could not find PythonClass entry" -

Determine if a XmlNode is empty or null in C#? -