8 Replies Latest reply on Jul 9, 2009 8:57 AM by Nick Belaevski

    a4j:mediaOutput

    Ioana Iacob Newbie

      Hello,

      I'm having problems with the media output. I tried the exmple from the live demo page, but it does not work for me.

      In my xhtml, I have

      <a4j:outputPanel id="flashPanelDynamic">
      
       <a4j:mediaOutput element="a" id="swfLink" style="display: none;" cacheable="false" session="true"
       createContent="#{Bean.paintFlash}" value="#{mediaData}" />
      
       <a4j:outputPanel layout="block" id="myFlashContent" style="width: 200px; height: 200px">
       <a href="http://www.adobe.com/go/getflashplayer">
       <img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" />
       </a>
       </a4j:outputPanel>
      
       <script type="text/javascript">
       var flashvars = {};
       var params = {};
       var attributes = {};
       swfobject.embedSWF(#{rich:element('swfLink')}.href, "#{rich:clientId('myFlashContent')}", "200", "200", "9.0.0", false, flashvars, params, attributes);
       </script>
      
       </a4j:outputPanel>
      



      In my bean I have the paintFlash and copy methods, and I added the MediaData bean.

      Ok, I must mention that the swf is in another war (I'm trying to integrate 2 projects), but this is not the problem. I've put a breakpoint inside the paintFlash method, but the method is not called.

      Plus how can I send flashvars?

      Thank you,
      Ioana.