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

Adding Context Menu to existing page

Expand Messages
  • Brian McCullough
    Folks, I have been working on something for quite a while and thought that I would ask if anybody has any suggestions that I could use. Part of my web
    Message 1 of 1 , Feb 2, 2009
    • 0 Attachment
      Folks,

      I have been working on something for quite a while and thought that I
      would ask if anybody has any suggestions that I could use.


      Part of my web application displays legacy web pages, adding a YUI
      Context Menu to that page before display. This is a plain page, no
      IFrames involved.

      I am adding "yui-skin-sam" to the <body> class as well as adding the
      required CSS and JS files to each of these pages to support the Context
      Menu operation. ( this happens on-the-fly as the page is being displayed
      )

      I have many of these pages displaying correctly, with the Context Menu
      looking right. All of the pages display a Context Menu of some sort.
      A few pages display a transparent Context Menu, which is less than
      ideal. However, I have run into one page that displays the Context Menu
      in a strange, horizontal instead of vertical configuration.

      This page appears to be ( possibly ) using a private copy of the YUI
      Library, which is corrupting my copy of the SAM Skin. ( or at least
      interfering with my access to the "real" copy )

      I could possibly create a custom answer to this problem, specifically
      for this page, but I don't know that I will never get this issue with
      another page.

      Replacing the legacy pages is not available as an option, all I can do
      is write my own code to alter these pages as they are being displayed on
      the browser.

      I have wondered about the "sandbox" example shown in the YUI Loader
      pages to change the "name" of the YUI Library, would this help? The
      context menu includes one or more items that emulate the "Copy" ( select
      and copy ) functionality from the browser's Edit menu. I found that I
      couldn't seem to use an iFrame to add my Context Menu, because it
      couldn't see the selected text. ( Possibly I was running into a
      cross-domain issue, I'm not sure, because I think everything is coming
      from the same domain origin. )


      Thanks for any suggestions,
      Brian
    Your message has been successfully submitted and would be delivered to recipients shortly.