Copy link to clipboard
Copied
Hello!
I have created a website in Flash with four different buttons leading to four different pages. Everything works fine when clicking the buttons in the order they appear. But as soon as I reach the last page (contact) and click on the first button (home) the content of both pages (contact and home) seem to overlap! Does anyone know what this means, what I am doing wrong and how to fix it?
I've used code snippets (Click to Go to Frame and Play) for each button.
Thanks for your help!
Copy link to clipboard
Copied
CAn you explain how you have designed things relative to the timeline and include a screenshot of the timeline?
Copy link to clipboard
Copied
Hi Ned, thanks for your response!
I have four different pages (home, about, film, contact) and four buttons with the same name.
The whole timeline is 90 frames long. 'Home' begins at frame 10; 'about': frame 30; 'film': frame 50; 'contact': frame 70.
At the end of each page I have used the code snippet Click to Go to Frame and Play to switch to the following page by clicking the button.
The code snippet is placed in frame 29, 49, 69 and 89.
The actionscript of frame 29 for example looks like this:
And as I said, the website works fine as long as I click on each button in the same order as they appear but as soon as I switch from contact to film, for instance, the content of both web pages overlap:
Thank you for looking into it!
Copy link to clipboard
Copied
For the timeline design as you have it I do not see any way that content that is manually placed in the timeline can end up displaying in other sections. What can cause that to happen is when you add content dynamically and do not child it to something that has been manually planted onstage. Do you have any code that adds content dynamically like maybe whatever is in that fbook layer in the contact section?
As far as the code you show goes, that could be problematic for you if you are repeating it in various frames. If the buttons are on the "buttons" layer, and they always do the same thing, then they only need to have event listeners assigned once, and there only needs to be one event handler function for each of those event listeners. If you are assigning new event listeners in each frame as you indicate, then each one you add stays and still works, so you can end up with 4 listeners for each button... you only need one for each.
Copy link to clipboard
Copied
Those facebook, vimeo, tumblr, ophelia layers contain links to other websites (is that what you mean by dynamic content?)
Copy link to clipboard
Copied
I just realized that this error is only happening in 'test movie'. In Publish preview -html it's working fine! Thanks a lot for the effort you made Ned!
Find more inspiration, events, and resources on the new Adobe Community
Explore Now