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

Re: [ydn-javascript] Using YUI DOM to query for vendor specific styles

Expand Messages
  • Matt Sweeney
    Hi Ivo, This works when the properties are actually supported by the browser. For example, you can get -moz specific styles in Gecko browsers, and -webkit
    Message 1 of 2 , Sep 21, 2009
    • 0 Attachment
      Hi Ivo,

      This works when the properties are actually supported by the browser.

      For example, you can get "-moz" specific styles in Gecko browsers, and
      "-webkit" in webkit-based browsers, but you won't get anything returned
      for "-moz" prefixed style in webkit.

      -Matt

      ivo wrote:
      > Hello listers,
      >
      > Can the YUI DOM utility query for Vendor-specific CSS properties that are associated with an element? (http://www.w3.org/TR/CSS2/syndata.html#vendor-keywords)
      >
      > I have a stylesheet with vendor extensions and I need to check whether an elements has specific ones applied.
      >
      > .someClass {
      > -vendor-specific-css: value;
      > }
      >
      > ...
      >
      > <div id="myDiv" class="someClass"></div>
      >
      > ...
      >
      > var cssProp = YAHOO.util.Dom.getStyle('myDiv', '-vendor-specific-css');
      >
      >
      > Is it at all possible to get such CSS properties via JS?
      >
      > Thanks,
      >
      > - Ivo
      >
      >
      > ------------------------------------
      >
      > Yahoo! Groups Links
      >
      >
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.