FORUMS: list search recent posts

Loading an external swf in a flash website

COW Forums : Adobe Flash

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Jan Lee
Loading an external swf in a flash website
on Oct 8, 2009 at 9:30:17 pm

I am working on an a website for a local Gallery. It is a flash website created in Flash CS4, Action Script 3. Everything is working fine except for the "Galleries" page. On the Gallery page that shows the artists work I have 3 categories, one for each of three different artists. Each artists can have an unlimited number of pieces. There is the typical selection of thumb nails that when you click on them a larger view appears in the main gallery frame. I bought a flash gallery online and was able to configure everything the way I wanted it to work. It works perfectly until I load it into the Flash website.
I tried numerous ways of loading the site from examples in books, and examples on this form. This is the script I used that made it finally show up where I wanted it.

var swf:MovieClip;
var loader:Loader = new Loader();

var defaultSWF:URLRequest = new URLRequest("Gallery.swf");
loader.load(defaultSWF);
addChild(loader);
loader.x=-260;
loader.y=-185;

This shows up where and how I want it, except now when I click on a thumbnail the picture in the main gallery frame does not change.

As I mentioned the website is AS 3, but I noticed the external flash gallery is AS2. Would this be presenting a conflict that causes the gallery not to work properly? SHould I look for a different gallery script that is AS3? I am new to Flash. This website is my first project. Help please.


Return to posts index

demetri tashie
Re: Loading an external swf in a flash website
on Oct 10, 2009 at 12:52:29 am

AS2 and AS3 are really different animals, and don't play nice with each other.

you can load an AS2 swf into an AS3 'host' , but not the other way around.

your AS2 swf can work and function on its own, as a self contained unit. the problem comes when you try to communicate between the 2.

it CAN be done using a 'local connection' . not for the faint of heart nor for someone doing their first project. my advice is to let the AS2 gallery go, and create one in AS3 . you can do great galleries in AS3.

its confusing enough just communicating between loaded swfs and host swf in the same scripting language, why complicate it? relax and enjoy learning AS3 !


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2017 CreativeCOW.net All Rights Reserved
[TOP]