Loading ...
Sorry, an error occurred while loading the content.

Align Panels and OverlayManager

Expand Messages
  • RedLeffer
    Hi, I have a loop, which produces 5 panels. I would like to add a OverlayManager, but it doesn´t work... Can somebody give me an example how i can align
    Message 1 of 1 , Jul 9, 2007
    • 0 Attachment
      Hi,

      I have a loop, which produces 5 panels.
      I would like to add a OverlayManager, but it doesn´t work...

      Can somebody give me an example how i can align panels with context
      (ar) ?


      Here my past code:

      for (...) {

      <script>
      YAHOO.namespace("example.container");

      function init(c) {

      YAHOO.example.container.panel = new
      YAHOO.widget.Panel("panel"+c, { xy:[150,100],


      width:"300px",


      visible:false,


      constraintoviewport:true } );
      YAHOO.example.container.panel.setHeader("<div
      class='tl'></div><span>$item.getText()</span><div class='tr'></div>");
      YAHOO.example.container.panel.setBody("This is a
      dynamically generated Panel.");
      YAHOO.example.container.panel.setFooter("<span>End of
      Panel $item.getText()</span>");
      YAHOO.example.container.panel.render(document.body);

      YAHOO.example.container.manager = new
      YAHOO.widget.OverlayManager();

      YAHOO.example.container.manager.register([YAHOO.example.container.panel]);

      YAHOO.example.container.panel.show();


      }

      YAHOO.util.Event.addListener(window, "load", init(countPanel));


      </script>

      }
    Your message has been successfully submitted and would be delivered to recipients shortly.