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

RE: [svg-developers] Re: Dynamically create a link in SVG

Expand Messages
  • Doug Schepers
    Hi, Cameron- ... I do the same thing, but I think this is actually a kluge to compensate for a poor serializer that is not namespace-aware. Hopefully, the next
    Message 1 of 5 , Jun 26, 2006
    • 0 Attachment
      Hi, Cameron-

      Cameron McCormack wrote:
      |
      | Erik Dahlström:
      | > Why would you need the xlink-prefix in this case? I would
      | > suggest this instead:
      | >
      | a_elem.setAttributeNS("http://www.w3.org/1999/xlink","href","h
      | ttp://www.kevlindev.com");
      | >
      | > You already say (with the first parameter) that the namespace
      | > is XLink, so there is no need to prefix the attribute with "xlink:".
      |
      | There’s no need for the the prefix in the nodeName for the 'a' element
      | to work, but it’s better to include it in case the element is
      | serialised later on. (At least, that’s what I tell myself at
      | night. :) (And of course that assumes that there is an appropriate
      | namespace declaration attribute in the document, too.))

      I do the same thing, but I think this is actually a kluge to compensate for
      a poor serializer that is not namespace-aware. Hopefully, the next
      generation of serializers will take the namespace into account and include
      prefixes automagically.

      Regards-
      Doug

      doug.schepers@...
      www.vectoreal.com ...for scalable solutions.
    Your message has been successfully submitted and would be delivered to recipients shortly.