0

I'm trying to create a simple music site using the Grooveshark API and their flash widgets. What I would like to do is have an album cover image with a play button in the middle and when that play button is clicked I would like it to "click" a div that is placed ontop of the flash widget play button, which would theoretically start playing the song.

I know I can create DIVs ontop of the flash widget, but what I'm not sure of is if I can imitate a click on the widget. The flash widget can't be controlled by javascript or any hooks according to their API.

So can clicking a DIV ontop of a flash widget imitate an actual click on the flash?

Here's a link to their API: http://developers.grooveshark.com/tuts/widgets

Thomas Uhrig
  • 30,811
  • 12
  • 60
  • 80
Stephen Roda
  • 859
  • 6
  • 13
  • 20
  • I think this would only work if the flash widget was written with ExternalInterface api which allows calling certain functions from javascript and vice versa. And according to the answer on this ***[question](http://stackoverflow.com/questions/6823523/control-embedded-grooveshark-widgets-using-javascript)*** it does have callable functions, the question was posted back in 2011 so make sure to look through grooveshark's documentation to make sure they are still there. – Patrick Evans Jul 05 '14 at 08:00
  • Ok according to their [page](http://developers.grooveshark.com/docs/) the `flash widgets do not provide js access` so you may be out of luck for this. – Patrick Evans Jul 05 '14 at 08:04
  • Yeah there's no javascript functions available, that's why I was wondering if it's possible to control them with HTML. Thank you for your answer though. – Stephen Roda Jul 05 '14 at 08:37

1 Answers1

0

Take a look at this info.

http://manisheriar.com/blog/flash_objects_and_z_index

http://css-tricks.com/snippets/html/keep-flash-behind-other-elements/

http://rijamedia.com/blog/2011/02/simple-fix-html-content-over-flash-content-in-all-browsers/

I know the answer is in them links.

Blood_Wolf89
  • 45
  • 1
  • 6
  • The answer was sort-of in those links. I know I can layer DIVs ontop of the flash object, but what I was wondering was if I could simulate a click on the flash object. Regardless those links will be helpful, so thank you. – Stephen Roda Jul 05 '14 at 08:40
  • Is it going to be something dynamic? or is it going to be static? Why I am asking is, It might be easier to just do it in flash. – Blood_Wolf89 Jul 05 '14 at 19:09