FORUMS: list search recent posts

How do I? Flash Website, etc

COW Forums : Adobe Flash

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Ryan McGinn
How do I? Flash Website, etc
on Nov 20, 2008 at 5:49:43 am


I'm somewhat new to flash, and I am interested in designing a website using either AS2 or AS3 for my photography business. I like the format of this website:


How difficult is it to make this type of page?

I've made a small page using AS2 in the past. Basically, what I did was create a flash file that had a "holder" movie clip in it that would simply play other swf's that were loaded into it. So for example, when you clicked on "about me" code would run to trigger the loading for the aboutme.swf that was a separate flash file.

Anyways, some main questions I have about the above page are:

1. When the buttons are clicked, how are they made to stay in the "over" state so they look like a tab instead of an unclicked button?

2. What is the best method for creating a page like this?

3. With the portfolio section, how do you dynamically load images to decrease the initial loading time?

4. Should I use AS2 or AS3 for this project?

5. Any good pages or tutorials to view?


Return to posts index

Sam Mattern
Re: How do I? Flash Website, etc
on Nov 26, 2008 at 3:59:41 pm

1. To keep the active button on the on state, you need to put a conditional in the onRollOver/onRollOut statements. Basically, you set a global variable up like this:
var curPg:Number = 0;//current page

When a button is pressed, you set curPg to the new page (Ex. 0 for home, 1 for portfolio, 2 for about me, etc). Then your button code would look like:
portfolio_btn.onRollOver = function():Void{
if( curPg != 2 ){
}else portfolio_btn.gotoAndStop("on");

You just set up labels at the different keyframes of the button code so that you can refer to them more easily.

2. The best method is the easiest way you can think of to do it. I'd put the buttons on one layer first frame, the content on another, with a different frame for each page. The buttons just control what frame you're on.

3. The best way (not easiest) to load pictures that are external is to use a MovieClipLoader. Looks like this:
var picLoader:MovieClipLoader = new MovieClipLoader();
var picListener:Object = new Object();
picLoader.loadClip("pic.jpg", someExistingMovieClip);

That's the basics. It replaces "someExistingMovieClip" with the picture. That only gets you one picture into one holder.


5.Describing dynamic loading/naming techniques would take me at least the length of this reply. Hint:
You want to use CreateEmptyMovieClip(this, "picHolder"+i, etc) to create multiple pic holders. Try searching for dynamic image gallery. I know has an XML based tutorial that will be of some help, though might be confusing getting around the XML stuff.


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2018 All Rights Reserved