ActionScript 2.0 :: Main Navigation Buttons - Dynamic Page Indicator

Jun 21, 2004

I have a website, basic overview. I have my main movie, which contains the logo and navigation. I have a blank movieclip created with actionscript that loads the individual movie swf files. That works fine. What I want to do is dynamically have the main navigation buttons' text indicate what page you the user is on. Right now the code is on each button instance, example:

Code:
//work button Definition
on(press){
if(_root.pageHolder != "work") {
_root.pageHolder = "work";
_root.mcContainer.loadMovie(_root.pageHolder+".swf", this);
[Code] .....

Each button has the same code, just pointing to their respective pages. Here is the code in the first frame for setCurrentMarker()n function:
var aMenu = new Array(home, jschaer, work, contact);
function setCurrentMarker(){
for(i=0; i<= (_root.aMenu.length-1); i++){
if(_root.aMenu[i] == pageHolder){
[Code] .....

So the variable aMenu holds the moveclip names of the buttons. PageHolder holds the the name of the current page that is loaded. Thats how I change the pages to be loaded. To explain, if you look at the button code, the text for each button is by default greay and when you rollover it becomes black and off and it becomes gray again. That is on the first frame.

On the second frame the text is black. In the code I tried to make the black dynamically, but it didn't work, so I settled for going to the second frame and stopping. How do you get those little scroll boxes where you can put code. I guess its preference, but is it generally good to put the code on each instance of a button or put in in the main frame where your code lies. Is there any benefit either way?

View 5 Replies


Similar Posts:


ActionScript 2.0 :: Flash Website / Dynamic Page Indicator

Jun 21, 2004

I have my main movie, which contains the logo and navigation.I have a blank movieclip created with actionscript that loads the individual movie swf files.That works fine.What I want to do, and which I can't figure out is dynamically have the main navigation buttons' text indicate what page you the user is on. Right now the code is on each button instance, example:[code]so the variable aMenu holds the moveclip names of the buttons. pageHolder holds the the name of the current page that is loaded.Thats how I change the pages to be loaded. To explain, if you look at the button code, the text for each button is by default greay and when you rollover it becomes black and off and it becomes gray again. That is on the first frame. On the second frame the text is black.In the code I tried to make the black dynamically, but it didn't work, so I settled for going to the second frame and stopping.My second question(much shorter I promise).I guess its preference, but is it generally good to put the code on each instance of a button or put in in the main frame where your code lies.

View 5 Replies

ActionScript 3.0 :: Buttons On The Main Page Doesn't Goto And Stop At Other Frames In The Main Scene

Jun 14, 2010

I added a website preloader in a separate scene to the main frame of my website and scripted it to go to and Play the main scene or frame of the website when finished loading. I then put a command in the first frame of the main scene for the movie to stop (); at that point. The problem is that now the buttons on the main page don't respond to any behaviour commands to go to and stop at other frames in the main scene. I'm not sure if this is a conflict between the stop(); command in the main scene and the button behaviour command to go to and stop at another frame or an error with the way I'm identifying the scene and frame.

View 5 Replies

ActionScript 3.0 :: Main .swf With Buttons On A Navigation Menu That Loads External .swf(s)?

Dec 18, 2011

I am using a main .swf with buttons on a navigation menu that loads external .swf(s) - these load external videos (I use them as their backgrounds).In the main .FLA I have used the following code (in the first and unique frame):

CODE

var Xpos:Number = 110;
var Ypos:Number = 180;
var swf:MovieClip;
var loader:Loader = new Loader();
var defaultSWF:URLRequest = new URLRequest("swfs/eyesClosed.swf");[code].....


I can make each button on the menu load each external .swf correctly with videos included - but when I leave that .swf using the navigation buttons to go to another section, the video and audio keep working in the background.

View 4 Replies

ActionScript 3.0 :: Three Buttons - Changing Page For User Navigation

Apr 4, 2011

I have 2 versions of the same code, both to make 3 simple buttons work to move the timeline to a keyframe to change the page for user navigation. What is the difference? Is one way better than the other?

HTML Code:
stop();
var button1:SimpleButton;
var button2:SimpleButton;
var button3:SimpleButton;
function handleCLICK( pEvent:MouseEvent):void {
[Code] .....

View 2 Replies

ActionScript 3.0 :: Add Several FLA Videos On The Same Flash Page And Control Them With Different Navigation Buttons?

Aug 12, 2010

I am trying to add several FLA videos on the same flash page and control them with different navigation buttons.So, Button 1 to play video 1, Button 2 to play video 2, etc .I have already put two navigation buttons and added two videos.However, I need to know Action Script to enable navigation button to do above.

View 6 Replies

ActionScript 2.0 :: Collapsing Navigation - Make The Main Button Not Sense The Rollovers Of The Internal Buttons

Feb 3, 2005

My problem that I'm having is I am trying to build a menu consisting 3 buttons, side by side that open and reveal subnavigation buttons on rollover. Then on rollout of the main container button, they close back to where they were. I have built the buttons and everything works great, the only problem is that on rollover of the internal buttons, the main button senses this as a roll out and plays the rollout animation event (closes the button). How can I make the main button not sense the rollovers of the internal buttons and only play the rollout event on rollout of the main button?

View 2 Replies

ActionScript 2.0 :: Dynamic Numbers Display For Page Navigation?

Oct 13, 2006

We are developing a dynamic image slide show which display images dynamically from XML data. We need display the numbers like (1 2 3 4 5 ) from the xml file as per the number of records for images with hyperlinks to their corresponding images. (We also need to display 10 numbers at a time )

View 1 Replies

ActionScript 2.0 :: SWFs + GetURL + Current Page Indicator On Nav Button?

Aug 8, 2006

I have a .swf file containing a navigation bar and also an animation. I was going to use getURL on the nav buttons so that a different html page would launch onRelease. The animation in the swf file that contains the nav buttons plays as soon as the swf is loaded and there's also a movie clip in the file which continues its animation even after the file has loaded and played. As each of the nav buttons are pressed and the correct html page loads, I don't want the entire swf file to reload and therefore play the entire animation again as it did on the home page, but instead I just want it to appear as though it's already loaded but I do want the separate movie clip in the swf file to continue to play. Is there any way to make this happen?

Also, I wondered what code I'd need to make the current page nav button appear in a different state to all the other buttons to make a "you are here" effect.

View 3 Replies

ActionScript 3.0 :: This Array / Position - Change The Page Indicator When The User Scrolls

Feb 26, 2009

I have a scroll pane component with SWFs loaded in them vertically like a PDF viewer. I need to be able to change the page indicator when the user scrolls. I have an event listener on the scroll pane listening for scroll. I have an array of the Y values of each page; looks something like this: 0,800,1600,2400,3200 etc What kind of equation would I do to determine the correct number. My scroll event looks like this:

[Code]...

View 6 Replies

Professional :: 12 Movie Clip Buttons On The Main Page?

Aug 25, 2010

I have 12 movie clip buttons on the main page (3 rows of 4 buttons).When a button is pressed,it gives the answer to a question which remains visible.On this answer screen, there is another button to click for further information. I pointed to this button to go to another frame within the same movieclip (containing the further information).However, this "further information" shows up  UNDERNEATH the 12 buttons, and you can't read it.

View 14 Replies

Professional :: Adding Music - Stop And Play Buttons On Main Page

Nov 9, 2010

I have my mp3 audio clip and made my play and stop button. I am using cs4 and as3. I want to have the play and stop button on my main page but still have the music play when the users clicks onto one of the buttons which takes them to a new page.

View 6 Replies

ActionScript 2.0 :: Buttons Load The External Swfs Except When Click On The Contact Button That Is In The Main Flash Page

Feb 23, 2011

I am loading swfs into a movie clip. However, the contact button is not a loaded swf any longer. It's in the main flash page. This is what I want to do. All the buttons load the external swfs except when I click on the contact button that is in the main flash page. I need to get the other buttons to load after I click the contact flash button. Below is the code for the contact button and the one under for one of the other buttons.

[Code]....

View 3 Replies

On Button Click Page Flashes Back To Main Page

Oct 23, 2009

I have a movie clip that loads in the main timeline, when i click on any of my buttons theres a quick flash of the main page. Im loading my movies on level 1 so i guess my question is, how do i get rid of the movie on the main time line?

View 2 Replies

ActionScript 2.0 :: Load External Swf Into Main Page And Remove When Nav To New Page

Jan 7, 2009

I am trying to load an external swf with a number of quotes into an empty movie clip on the home page. then I want it to obviously disappear when nav to any other page.

1) know that you need a loaderEmpty_mc to load the swf into

2) don't know code for how to get it to load on entering the home page

3) don't know how to cdde for leaving the home page and making it disappear

View 3 Replies

ActionScript 2.0 :: Load Multiple Swfs Into One Swf Via A MAIN Navigation Swf?

May 12, 2002

I want to load multiple swfs into one swf via a MAIN Navigation swf.

Right now I have 5 sections in Main Navigation swf.

I want each different section to open in the same external swf.

View 4 Replies

Flash8 Page Turn And Navigation?

Nov 27, 2009

I have created what looks like a book in flash.There is a corner turned over at the top right so when you click it the page turns. This is fine, however, what i want to beable to do is when I click it the page turns and goes to a new page. ( i have made all the other pages)I tried an on(release) but it just doesnt go to the page, it plays the movie clip but I cant get it to navigate aswell..

View 14 Replies

ActionScript 3.0 :: Script For Page Navigation?

Jan 6, 2009

Can anyone tell me the script for navigating from one frame to another? I'm developing a web site in Flash CS4 and haven't yet adjusted.

View 4 Replies

ActionScript 3.0 :: Keyboard Navigation In Main Timeline Not Working Properly

Mar 15, 2012

I am new to actionscript. I was trying to make a slide show frame by frame. I have my main timeline with the following code in first frame.

stage.addEventListener(KeyboardEvent.KEY_DOWN, fl_changeSlide);
function fl_changeSlide(evt:KeyboardEvent):void{
if (evt.keyCode = 37) // LEFT{
gotoAndStop(this.currentFrame-1);
}else if (evt.keyCode == 39 || evt.keyCode == 32){
gotoAndStop(this.currentFrame+1);
}}

In the third frame I am trying to load an external swf by clicking a button 'rrbutton' and unload the same when the user clicks left arrow.
var loadit = new Loader();
function ack(evt.keyboardEvent):void {
if(evt.keyCode == 37){
loadit.unloadAndStop();
stage.addEventListener(KeyboardEvent.KEY_DOWN, fl_changeSlide);
[Code] .....

The external swf loads on clicking the button and unloads when left arrow is pressed and the main time line frame appears. But thereafter the keyboard navigation in the main timeline(through function fl_changeSlide) is not working properly.

View 1 Replies

ActionScript 2.0 :: Loading Main Navigation In External SWF Through Container Movie

Dec 30, 2008

I have attached two pictures. Basically I am making a website. The main navigation loads in external swf's through a container movie. For this I have used this tutorial : [URL]. What I want to do is- when you rollover the navigation bar, be it the text or the coloured block- I want it to scroll down and reveal the 'sub navigation'. (pic2) It's like a drop down menu but kind of the other way around. Then, when you either rolloff of the navigation bar or click on a menu button, it slides back up to its original state. (Pic1). I have played around and only managed a sloppy version which doesn't work very well, especially when you resize. I think a simple answer to this is if I could get my buttons to work inside a movie clip. I had tried this but then the swfs wouldn't load properly.

View 3 Replies

Movie - Hiding The Navigation Menu On The Page

Aug 22, 2010

I have uploaded a movie, great, no problem but. it is hiding the navigation menu on the page.

View 1 Replies

ActionScript 2.0 :: Curl Page On Navigation Change

Jun 21, 2010

i have an swf file to cause a page curl when i click a different link in my site, but as of now it is a blank curl over the page i navigate to. i want to make the current page curl revealing the 1 i am navigating to. how would i go about this?

View 5 Replies

Flash 10 :: Page Navigation From Instances On Stage

Nov 5, 2011

From this example image attached, I have created many instances on my stage, let's say that for each instance I would like to go to a new section that has a different layout. What is the action script that will move my frame to the right location for example, let's say on one of the instance I have a button that says contact. On one of the buttons, what action script to I have to put in so that it navigates there when someone press it, I would think "on press" go to instance tab contact something of that nature.

View 3 Replies

ActionScript 2.0 :: Flash MX Navigation On Html Page

Apr 30, 2004

I have a Flash MX navigation on an html page and I want to set up the buttons so that onRelease they will go to named sections on that html page; Thru the use of the <A NAME></A> <A HREF></A> tags.

View 2 Replies

ActionScript 2.0 :: Highlighting Current Page In Navigation?

Dec 14, 2006

I want to highlight the current page in my navigation.

I have the code below (duplicated for each button on the page) which changes the colour of the text in the nav when you rollover and then back when you rollout. I'd like to have the text stay on the rollover colour if it is the current page.

I've been messing around with variables and have added the bit onto the onRelease function which displays the "page" variable in a dynamic text box. This works fine, but I'm now stuck on how to use this variable, everything I've tried hasn't worked.

I can understand the principle of what I want to do as I can do it in PHP or CSS. I need some kind of conditional statement, for example (in laymans terms):

if page equals 1 then make text colour red or if page equals 2 then make text colour red and so on...

Code:
var up = "0xC5B9B3";
var over = "0xC6006F";
_root.nav.button_1.onRollOut = function() {

[Code]....

View 2 Replies

ActionScript 3.0 :: Converting Navigation In Main Movie That Loads External Swf Files

Aug 19, 2009

I am diving in to learn AS3 and converting my site over to AS3. The majority of my code is for my navigation in my main movie that loads external swf files. Here is what I have and I don't know where to start to convert it. I know I need to do this in steps. So the audio is not important now or my other swf files.

[Code]...

View 10 Replies

ActionScript 3.0 :: Using Child Navigation To Load AddChild Main Time Line

Jan 23, 2009

Using Child Navigation to load main time line.I am new to AS3 and have done pretty well but have been caught up this area.I have been loading swfs into a loader (imageLoader) which has been added to the stage using addChild. Then with buttons and functions I load other swfs into the same loader which replace each other. I now have an swf "testProject3a.swf" loaded into (imageLoader) which has icons for navigation and when each icon is clicked I need it to load another swf into (imageLoader) and replace it's self "testProject3a.swf" with "portalB.swf".I've tried adding removeChild code to the loaded swf but it removes the original (imageLoader) and the other buttons have nothing to load into.[code]

View 3 Replies

ActionScript 2.0 :: UnloadMovie Command - Load In An Empty Container The Swf's Of The Main Navigation

Feb 26, 2005

i have a little problem with the unloadMovie command. i have a button which is mc2_about here is the code

[Code]...

where i want to unload level1 which is a scrollbar with a text and load the portfolio section in an empty container... my structure i want to load in an empty container the swf's of the main navigation (home- portfolio,etc) and the sub-menus of it's categories[about me-print-web design) into levels. is there a simpliest way of doing that?

View 3 Replies

Make The Buttons On Each Page Load The Next Page (sprite) From The Library?

Jun 29, 2011

My basic aim is to create a newspaper that consists of four pages. Each page i have created and are sitting in the library as sprites. Each page has buttons that need linking so that when pressed it loads the next page or page that i want. This is the part i am confused with =/ how do i make the buttons on each page load the next page (sprite) from the library??

View 2 Replies

ActionScript 3.0 :: Flash Navigation Menu On A Html Page?

Apr 2, 2009

I am working on a project that I need to create a flash navigation bar for a html site. There will be a drop down menu when you rollover the buttons on the nav bar, which means the drop down menu will be overlaying on top of the html pages. I saw websites were done like this before, but I personally don't know how to do it.

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved