Page 1 of 1

[SOLVED]swapping swf header for static one for iPhone & iPad

Posted: Sun Jun 26, 2011 7:56 pm
by quazimoto
Hi - Love this CMSMS!

I have inherited a CMSMS site; ver 1.8.2 to deal with. The owner of the site, a friend of mine from way back wants to see if I can find a clean CSS, HTML or other solution that swaps the animated .swf header for a static one when a "iThing" comes to the site. I can not get the original flash files to make a different type of animated format as they were trashed in a crash some time ago.

My programming skills are dismal, but I said I would give it a shot. So, can anyone point to a path as my searches are only showing complete second site solutions? Or am I asking the wrong questions? Or is there no other choice but use a agent and make a second home page? The owner of the site likes the way her site works on iStuff stuff except for this one header on the home page.

Thanks in advance for your interest!

Re: swapping swf header for static one for iPhone & iPad

Posted: Mon Jun 27, 2011 10:44 pm
by quazimoto
From Goran I got this email; and this resolves my issue, thanks!

Hi,

look at BrowserTools plugin. http://dev.cmsmadesimple.org/projects/browsertools
With it you can use something like this.

{capture assign='isMobile'}{browsertools action='isMobile'}{/capture}
{if $isMobile == true}
<img src=“yourstaticimage.jpg“ />
{else}
your flash
{/if}



This is untested, but basically you should get the idea.

Regards,
Goran

Re: [SOLVED]swapping swf header for static one for iPhone &

Posted: Sat Sep 17, 2011 6:53 pm
by a1Websites
I need to get the variable from {browsertools action="isMobile"} but I have failed miserably!!!

I found this in the forum

{capture assign='isMobile'}{browsertools action='isMobile'}{/capture}
{if $isMobile == true}
dog
{else}
cat
{/if}

I used dog and cat for a whim to see if the rascal would work but it does not pick up the variable which will be either true of false ( I need it to distinguish between iPhone and other normal browsers) I plonked the code into the template and it will not pick up the variable.

Can anyone help as I am now going quietly mad!!!

Frank