[Javascript] Embed flash object help

suresh kumar asureshkumar_1983 at yahoo.co.in
Sun Feb 11 04:20:45 CST 2007


Hi,
     I am facing one problem in embed flash object.i am displaying the flash (.swf file) using embed tag<embed> in IE.i want to display the alert box when user click  the mouse over the flash .i am able to display the alert box  when user double click the flash .but i want alert box need to display when single mouse click over flash.
   
  my code:
   
  <script>
  function kiosk(){    // fn will be called when user click mouse
   
             alert(" i received the mouse click");
  }
  //-------------- creating the embed flash object
   
  var picObj1 = document.createElement('EMBED');                
picObj1.setAttribute('id',"aShow"); // Give id to it
picObj1.setAttribute('TYPE' , 'application/x-mplayer2');
picObj1.setAttribute('PLUGINSPAGE','http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,7,1112');
 picObj1.setAttribute('play','true');
 picObj1.setAttribute('wmode','opaque');
  picObj1.setAttribute('width','100%');
 picObj1.setAttribute('height','100%');
 picObj1.setAttribute('src','02.swf');

  //--------end 
   
  aShow.attachEvent("onmousedown",kiosk); // i am attaching "onmousedown" event

document.getElementById('iedisplayarea').appendChild(picObj1);
  
</script>
  <div id="displayarea"></div>
   
   
  i am very happy if there is any technically help from you
                                                                        A.suresh
   

 				
---------------------------------
 Here’s a new way to find what you're looking for - Yahoo! Answers 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.evolt.org/pipermail/javascript/attachments/20070211/4985d23f/attachment.htm>


More information about the Javascript mailing list