View Full Version : Different links activating multiple "layered" flash movies

05-03-2010, 12:17 PM
I have a customer the likes the fact that with flash websites clicking a link brings up the new contents without having to reload the whole page. I was thinking about having a set of links that load different flash movies in a div. As I click each link it runs the new flash movie in that div. No idea how to do this, but thinking that clicking a link activates the needed flash and "brings it to the front".

Hopefully you get what I mean.

Any help / pointers appreciated.

05-03-2010, 01:12 PM
It would be easier to do the whole thing in flash wouldn't it?

05-03-2010, 01:38 PM
If I knew how to ceate a website using Flash, maybe!

Without getting too bogged down with Flash and simplifying things, how do I have, say, different images "coming to the front" in a div based on different links being selected.

05-03-2010, 02:02 PM
Perhaps you should think of talking the whole Flash thing out of the customers head. If you want that this site eventually will be indexed good by search engines, than you need to know how to do this right All the images, js files, stylesheets, etc. will be cached by the browser anyway.

An alternative for loading different images in a div without reloading the whole page is by using AJAX.

Google 'loading content in a div with AJAX'

05-03-2010, 02:53 PM
Yeah, that's one reason for not going down the Flash route. Only started learning Web stuff a few weeks ago. Using Dreamweaver. Understand the fundamentals of programming, but still scratching the surface of CSS and HTML. Was hoping someone could give me some sample code that I can use... This site shows what I'm trying to achieve: http://www.mcregg.com/ccc/

What I'm thinking now is that if I can change the z-index for a div based on what the user clicks (a link, a button, etc.) then I will be able to bring that div to the top. So in my example as shown in the link above, clicking on Link1 will make the z-index 2 for div id="ViewForLink1" and 1 for the other divs.

I could be completely barking up the wrong tree here, but any input MUCH appreciated.

05-03-2010, 02:58 PM
I have a customer


Only started learning Web stuff a few weeks ago. Using Dreamweaver.

= :shock:

05-03-2010, 03:57 PM
There's no benefit for the client to do this. Asking for a page that does not load new page means exactly that. Search engines are going to see just one page. It would be near impossible for people to bookmark certain information etc. What's most important for the client; a usable website, or a 'cool' effect?

05-03-2010, 06:39 PM
Don't think I'm explaining myself well. Please forget the Flash, the customer, the effects... I get your points and appreciate them. I'm trying to go up a learning curve. What I need are some pointers to change a z-index based on an action. I imagine this is quite simple.

05-03-2010, 07:43 PM
What I need are some pointers to change a z-index based on an action. I imagine this is quite simple.

It doesn't work like that. Dis the div's with position absolute and z-indexes. You should use apdivs to a bare minimum and only in case if you need to place an element outside the 'document flow'.

What you want can be accomplished with AJAX (jQuery, Spry, Mootools, etc), but what we're trying to explain to you is that you really must understand the basics of web development before you start even looking for customers.

AJAX demo: http://res.nodstrum.com/jQueryPHPContent/index.html


05-04-2010, 12:32 AM
You have two approaches.
One is using Ajax like Gentleone suggested, which will load the content into the same url. This will load faster, but the majority of your content will not be what we call accessible.

The other approach is to preload all the info into the page, and then simply showing and hiding the content. This will cause a longer load time, but all the information will be present on the page. Like gentleone said though, this is not done through z-index.

You can use anything you want to show and hide elements. Some come with DW, you can use a JS framework, and for those with the skills they could just write their own.

<whisper> Third option is to make a regular webpage and learn that first 8)</>

05-04-2010, 01:25 AM
I was only using AP divs to illustrate what I was trying to achieve. Read many times that one should not use them. I explored the Javascript route and achieved what I was looking for: www.mcregg.com/ccc (http://www.mcregg.com/ccc). Would you mind checking out what I did and letting me know if there's a better (more standards) way of doing this.

05-04-2010, 06:17 AM
You need to have a look at the effect in different browsers. At least Chrome and Firefox are displaying half of each film at the same time.