Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

flash button query!

Status
Not open for further replies.

iLy54

Programmer
Sep 5, 2002
33
ZA
i hav a button created in flash. this is the code used to add the button to the page.

<EMBED SRC=&quot;flash.swf&quot; swLiveConnect=FALSE width=120 height=120 QUALITY=autohigh BGCOLOR=#000000 TYPE=&quot;application/x-shockwave-flash&quot;PLUGINSPAGE=&quot;shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash&quot;>


flash.swf is the name of the file used. it ofcos has to inserted using EMBED.
My problem is that i want to associate an onclick event that when its clicked on it opens another page.
im clueless with this one.
any help would be appreciated.
thanx
-Mon3y is the r00t of all evil and every man needs roots-
 
Try a <A HREF=&quot;...&quot;><EMBED ...></A> construction. Cheers,
Nico
 
nico,

i'v tryd that already. and it hasn't worked 4 me. thanx anyway. -Mon3y is the r00t of all evil and every man needs roots-
 
Have you also tried a <DIV>? Another possibility is to add a <DIV> with the same dimensions on top of the flash button, by specifying a higher z-index. And then trap the onClick of the <DIV>. Cheers,
Nico
 
thanx 4 the suggestion. just 1 problem though: i am a novice to js and wouldnt no how 2 go bout doin it. what would you suggest?
thanx again -Mon3y is the r00t of all evil and every man needs roots-
 
I've not used Flash, but I thought you can assign an onClick event to the item itself within Flash? Maybe the Flash forum (is there one?) could help with that.
 
helltell,

i'v tryd assigning the onclick event to the item itself. and that hasnt worked either.
im sure there mus be sumone out there that can giv me a solution.
thanx 2 every1 that have offered suggestions. -Mon3y is the r00t of all evil and every man needs roots-
 
Questions:

1. Do you have the source file for the flash movie (.fla)?

2. Can you post a link to the page with the flash movie in it?

If you can do either of these then I can help Regards
David Byng
spider.gif

davidbyng@hotmail.com
 
What code did you try assigning to the onclick event from within Flash itself? Maybe it was that at fault.
 
wel i tryd this:

<EMBED SRC=&quot;flash.swf&quot; swLiveConnect=FALSE width=120 height=120 QUALITY=autohigh BGCOLOR=#000000 TYPE=&quot;application/x-shockwave-flash&quot;PLUGINSPAGE=&quot;shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash&quot;
onclick=&quot;window.open('login.htm')&quot;>
and it didnt work.

-Mon3y is the r00t of all evil and every man needs roots-
 
What I meant on my first post, is that using Flash, the program itself, is it possible to assign an onClick event to it there?
 
Yes it is and that is what i have been trying to say:

1. Do you have the source file for the flash movie (.fla)?

2. Can you post a link to the page with the flash movie in it?


If you can do either of these then I can help Regards
David Byng
spider.gif

davidbyng@hotmail.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top