Dynamic Youtube Video With jQuery & jSON -


Then a Jason object has returned to me and I want to draw a thumbnail from the object, add click event, click once Based on the Json object, SWF Player creates a difficult time. Basically the thumbnail of the SDF is "binding". Therefore, when you click on this thumbnail, you create this SWF.

Here are JSFDials to drag the thumbnails. I'm not sure I'm saying this right. Not sure the click event should be in the loop to set up.

Any help would be greatly appreciated.

It should be in the loop not , because you use the Live method ( correctly ). <

It should be $ ('.logoon'). ('Click', {swf: $ swf} live, function (e) {

Now you can call it e.data.swf

with the way to ignore the last live click handlers ( if your code goes more than once ), then

  $ ('. Thumbnail'). (') .live (' click ', {swf: $ swf}, function (e) {  

I Also, to add an identifier on each thumbnail, your code has changed so that you can easily arrange them with the array of video Map.

The code can be retrieved by videoid when you click on the method with element as $ (this) .data ('videoid') >

On the demo

Comments