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
Similar Posts:
Jan 28, 2011
this is the first time I have used flash pro.I just edited the menu and everything works perfectly except for the highlighting of the link on the current page. If im on the home page, home is correctly highlighted. However after that it skips the next button (about). So when I am on the about page the next button (events) is highlighted.
View 4 Replies
Jan 20, 2010
I'm creating a new look for the xspf player: [URL]The playlist highlights the current song being played. I'd like to change the color but can't find where that option is listed in the .flv file, or in the actionscript file.
View 2 Replies
Oct 19, 2010
I'm working on a pretty basic interactive children's book. I have it set up so that each page has audio relating to that specific page. Going forward, there is no issue with sound overlapping from the current and next pages. Going backward, however, there is an issue with sound playing on both the current and previous pages. How do I stop this?
Here is the script I'm using-
ActionScript Code:
stop();
import flash.events.MouseEvent;
[Code].....
View 3 Replies
Jan 8, 2009
I bought one of those templates, and i was able to get around most of the stuff. But one last thing that I have issue with is that there is an AS2 script for a button, where you can change the page that you want to be updated. But every time that I click that button, it opens the new page. but then if I use the same button in the new page, and click on it, another page will open and that current page will get closed.
[Code]...
View 1 Replies
Jul 28, 2010
I need to get the value from the current page url, (the value is sent by javascript)?
View 4 Replies
May 23, 2010
I need to sitelock a swf to All of the sitelock solutions I've found only lock the domain that the swf loads from, which means a user can still copy the source code of the page and load the page locally and alter the swf params (since the swf still loads from the same url
View 1 Replies
Sep 15, 2009
How do I determine the URL of the current page from within Flex?
View 7 Replies
May 16, 2010
there is no tags on flex paper. so make tag on flex paper.
How do i get the page number in flex paper. I want to add some events when page is changed.And i also want some events on particular some pages. so i need that current page number which is viewing by the user in flex paper.
View 2 Replies
Jul 13, 2010
Is it possible to get page URL into flash ?
Without using ExternalInteface.call('window.location')
trace(this.loaderInfo.url) simply return URL from where flash was loaded.
View 2 Replies
Aug 17, 2009
I have built a pagination gallery and am having some trouble calculating the current set of pages from the current page (and whether it is the last set and if so does the last set have a full set or less than a full set).[code]...
View 2 Replies
Jan 14, 2010
I am building a flash component to be embedded on an html side - the flash will include buttons to 'share' - i.e. on facebook, twitter, etc. I want to be able to grab the URL of the page and put it into the coding on the button.
Currently the button says:
tweetbtn.onRelease = function() {
getURL("http://twitter.com/home?status=Check Out This Company at www.thiscompany.com",
[code]......
View 1 Replies
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
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
Aug 4, 2009
I have managed to create some buttons movie clips and understand how to link pages. The only question i have is how do you make the button/link for the current page highlight so the user can know what page they are on? Is there a way to have a current page indicator in flash as you can do with html/css?
View 2 Replies
Jul 25, 2006
I want to print the current page (web page) when user clicks on a button.
View 14 Replies
Oct 8, 2011
I am using a Flexbook which contains 2 BorderContainer. The code is shown below
<controls:FlexBook id="book" x="20" y="20"
width="100%" height="100%" horizontalCenter="0"
animateCurrentPageIndex="true"
showCornerTease="true" animatePagesOnTurn="true"
[Code]...
This code shows page1 as current page. I want to show the BorderContainer (id= page2) as my current page dynamically on a button click. I tried setting currentPageIndex = 1, but I get a blank page by doing this.
View 1 Replies
Jul 31, 2008
whenever I put a link in Flash to another URL, the page always opens in a separate window. How do I change this?
View 1 Replies
Jun 12, 2009
I currently creating a website which content some pages. example of homepage and aboutpage.I want to make it as below.
If the user clicks the 'home_mc' button i want it to disable to the content cant be loaded twice. If the user clicks 'products_mc' i want 'home_mc' to be enable again, and then disable 'products_mc'.This to prevent user to currently reading on homepage when click on the home_mc button again will cause the homepage animate in again.
but i still cant figure out how to make it. can we use some code like
if(nextPage == currentPage)
{
//disable the mouseEvent listener of the currentTarget button?
}
[Code].....
View 7 Replies
Apr 15, 2010
how to copy current page's URL in clipboard on Right-click menu like they do in in2media website? Also I noticed that they incorporated Back and Next options in their Right-Click menu.(Is that possible only by using Flash?)
I already use SWFAddress in my project for DeepLinking and I am aware of the ContextMenu class.
View 2 Replies
Aug 22, 2010
I have uploaded a movie, great, no problem but. it is hiding the navigation menu on the page.
View 1 Replies
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
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
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
Apr 9, 2010
Any way to work with .swf files exported from InDesign (with page curl effect in tact)? I'd like to add a zoom feature, and need the ability to keep track of the currently viewed page.
View 5 Replies
Jun 14, 2010
How to find current page url from flash without calling javascript function. I was trying to get the url of the current page where my player has been embeded. I wrote this function.
function getCurrentUrl():String{
var Url:String = ExternalInterface.call("function get_url(){return document.location.href;}");
return Url;
}
This function works in firefox and chrome but doesn't works in IE.
View 0 Replies
Jun 15, 2007
I have a button that animates when you rollover and animates when you roll off. Let's say it is my home button. But I don't know how or what code to have so that my home button stays paused or stopped at the end of my rollover animation when the movie clip page associated with the button is currently displayed. And then if I click on another button like the 'About Us' button to make the 'about us' page load, to have my home button stop being highlighted when the home page is not displayed anymore.
So far this is my button code:
home_mc.onRollOver = function () {
home_mc.gotoAndPlay ("_on");
} home_mc.onRollOut = function () {
home_mc.gotoAndPlay ("_over");
}
View 2 Replies
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
Aug 30, 2009
I am using the following code for my Navigation in a FLash CS4 file:
stop ();
function buttons(event:MouseEvent):void{
gotoAndStop(event.target.name);
}
home.addEventListener(MouseEvent.CLICK,buttons);
services.addEventListener(MouseEvent.CLICK,buttons);
about.addEventListener(MouseEvent.CLICK,buttons);
contact.addEventListener(MouseEvent.CLICK,buttons);
It works great when I am on the home page, but stops working once I navigate to any of the other pages. I have an Actions layer and that layer extends the full length of all pages/frames of the timeline.
I have the frames labeled as such: home, services, about, and contact. (All are "Type:Name")
each button is named as such: home/ instance of "home", services/instance of "services", etc.
View 1 Replies
Aug 30, 2011
I'm attempting to recreate some flash transition effects with html/ajax. How feasible is it to do a full-page cross-fade?
View 1 Replies