Page 1 of 1

How to insert a swf animation

Posted: Thu Aug 07, 2008 1:39 pm
by kayleghsparks
I am using CMSMS version 1.4 and I am trying to put a flash swf onto my home page.

The swf is an animated banner which is going to sit just above the main content of the page however I cannot get anything to show anything when I view the site. When I am putting Javascript code in to embed the swf the editor eats half of the code for example I put in

Code: Select all

<__script__ type="text/javascript">
AC_FL_RunContent( 'codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0','width','900','height','200','title','swf test','src','swf/Untitled-1 test','quality','high','pluginspage','http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash','movie','swf/Untitled-1 test' ); //end AC code
</__script><noscript><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="900" height="200" title="swf test">
  <param name="movie" value="swf/Untitled-1 test.swf">
  <param name="quality" value="high">
  <embed src="swf/Untitled-1 test.swf" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="900" height="200"></embed>
</object></noscript>

and the editor then leaves this after I click update

Code: Select all

<object width="900" height="200" data="http://www.domainname.com/images/flashfilename.swf" type="application/x-shockwave-flash">
</object>
How can I get a swf animation to show?

Re: How to insert a swf animation

Posted: Thu Aug 07, 2008 1:45 pm
by Dr.CSS
Have you looked into the Objecttag?...

Re: How to insert a swf animation

Posted: Thu Aug 07, 2008 2:01 pm
by kayleghsparks
Hi

Yes I have looked at it but it doesnt look like a module and has no documentation for it. How do you use the downloaded php file once you have it?

Re: How to insert a swf animation

Posted: Thu Aug 07, 2008 2:38 pm
by Zoorlat
The SWFObject tag is a tag, not a module.  :P Just upload the php-file (function.swfobject.php) to your plugins-directory. In the admin panel you will then see it under Extensions > Tags. There you will also be able to view the help-info.

/Z

Re: How to insert a swf animation

Posted: Thu Aug 07, 2008 2:43 pm
by kayleghsparks
Hi

I just spotted that and have put it in (feeling a bit stupid now  :-[ ) however I am now getting this error

string(123) "Smarty error: [in content:content_en line 1]: syntax error: unrecognized tag 'object' (Smarty_Compiler.class.php, line 590)" string(123) "Smarty error: [in content:content_en line 1]: syntax error: unrecognized tag 'object' (Smarty_Compiler.class.php, line 590)"

I have copied the php part into the User Defined Tags and this

{object src='swf/homepage_banner.swf' height='200' width='900' class='flashplayer'} {object src='swf/homepage_banner.swf' height='200' width='900' param='quality::high||bgcolor::#ffffff' alt='Download Flash Player'}

into the home page.

Re: How to insert a swf animation

Posted: Thu Aug 07, 2008 6:30 pm
by Zoorlat
Hi again,

First of all, upload the whole "function.swfobject.php" to your plugins directory, and then find it under Tags (rather than creating a user-defined tag for this).

Then, the correct call is {swfobject src='swf/homepage_banner.swf' height='200' width='900' class='flashplayer'}

Hope this gets it working for you.
/Z

Re: How to insert a swf animation

Posted: Thu Aug 07, 2008 7:05 pm
by viebig
You are not understanding each other.


Object Tag is one thing, SWFObject Tag is another thing.

The Object tag dont depends on Javascript and has accessibility and SEO support. Servers flash, media player and quicktime objects.

The SWFObject Tag depends on javascript.

The code you wrote using the Object Tag is absolutelly right

Code: Select all

{object src='swf/homepage_banner.swf' height='200' width='900' class='flashplayer'} 
{object src='swf/homepage_banner.swf' height='200' width='900' param='quality::high||bgcolor::#ffffff' alt='Download Flash Player'}
but you need to download the function.object.php and put it inside your /plugins folder

then it will work and you´ll not receive that error message

Re: How to insert a swf animation

Posted: Fri Aug 08, 2008 8:40 am
by kayleghsparks
Hi guys

i have uploaded the php file to the /plugin folder and put the code in my homepage and it works!

Thanks for all the help :)

Re: How to insert a swf animation

Posted: Fri Aug 08, 2008 5:21 pm
by Dr.CSS
Pleeze to insert [solved] in subject line first post, hit modify...