-
display image from hyperlink
I'm trying to achieve this menu list affect in the following link: http://www.karascupcakes.com/cupcakes.html
on frame 1 of my movie, i have a movie clip named imgholder.
I have a text box that accepts html. I'm loading an external text file into the box. In the text file is a <ul> list of items.
What I want to do is hover over the link, then display a specific image to load into the MovieClip.
Does anyone know what i can do to achieve this affect?
-
What you are asking for is not that easy.
You can use link events inside a dynamic textfield. That way a link event is dispatched when you click the link but it doesn't work for hovering.
What might work is using getCharIndexAtPoint(x, y) with the mouse coordinates to get the index of the character below the mouse pointer, use getTextFormat(beginIndex, endIndex) with that index value to get the text format of that character and use the url property of that text format to detect what the link is. When you have the link, you can use it to load the image.
-
KoolMoves Moderator
Why a dynamic textfield? First thought I had was a table component, a table of buttons built dynamically.
Then it occurred to me that perhaps a static build is all that is required.
Taly, make your "buttons" with the text and a over image like the little triangle for each item, then create a listener event for each that displays whatever you want.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|