Forum Moderators: phranque

Message Too Old, No Replies

How do we do this?

Something I have seen on another website.

         

adamnichols45

2:00 pm on Feb 18, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



At the moment on the .co.uk version of yahoo on the right hand side they have an advert which plays and then once it has finished all the links below more up.

How can that be achieved? Im thinking javascript and dhtml

regards

httpwebwitch

3:41 pm on Feb 18, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Very fancy.

Yahoo has some messy code in there. Probably deliberate, to keep people like us from figuring out how to mimic them. ha!

The ad is Flash, which means it can trigger javascript events on the page with FSCommands. So when the movie reaches Frame X, the movie tells the page to start that DHTML routine that changes the (CSS) height of the element it's in.

The column below the ad just rides along as the height changes. I don't think it's positioned up or down.

If you want to mimic this, then you can experiment with the getUrl Flash command:

getUrl("javascript:startAnim()");
// where startAnim() is a function in your javascript

adamnichols45

7:12 pm on Feb 18, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Thanks mate - yeah I was quite impressed when I see that. I dont really use flash but I might have ago at something like that :)

tbear

10:25 am on Feb 19, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Sounds like a bit of a pain, if you are about to click on a link and it suddenly jumps away.

Not what I would call visitor friendly (bit like the tabs used by hotmail which jump sideways as the page loads).