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

tag not rendered, error message

Expand Messages
  • jfkransen
    Hello, I have an SVG like this:
    Message 1 of 1 , Nov 22, 2011
    • 0 Attachment
      Hello, I have an SVG like this:

      <svg:svg version="1.1" width="175" height="175">
      <svg:g transform="scale(0.3)">
      <svg:g transform="translate(-20,-20)">
      <svg:image x="0" y="0" width="256" height="256" xlink:href="https://somewhere.nl/C00000302.png" />

      When I open it in the browser, it looks fine.
      When I link to it from an HTML page in the browser, it does not show the underlying .png image.
      When I rasterize it server-side to PNG, using Batik, it gives this error:

      org.apache.batik.bridge.BridgeException: null:0
      The URI "http://somewhere.nl/C00000302.png"
      on element <image> can't be opened because:
      The URI can't be opened:
      Server returned HTTP response code: 406 for URL: https://somewhere.nl/C00000302.png
      at org.apache.batik.bridge.UserAgentAdapter.getBrokenLinkDocument(UserAgentAdapter.java:449)
      at org.apache.batik.bridge.SVGImageElementBridge.createBrokenImageNode(SVGImageElementBridge.java:993)

      406 would mean "not acceptable", so I guess a mismatch in the accept headers. If this is the case, I would like to know how to tell Batik to also accept "image/png". But I would be surprised if it does not accept it by default.

      I am very grateful for your responses.

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