Benni: Problem SVG nach Hochladen

Hallo, ich habe ein Problem zu SVG. Nach dem Hochladen einer SVG-Datei ist diese nicht mehr funktionsfähig. Der Befehl "xlink" wird nicht akzeptiert. Hier mal der Quelltext:

<?xml version="1.0" encoding="ISO-8859-1" standalone="no" ?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd"> <svg width="512" height="384" xmlns="http://www.w3.org/2000/svg">
<image x="0" y="0" width="512px" height="384px" xlink:href="bes0.jpg" />
<a xlink:href="a1.svg"> <polygon fill="#DBAA66" stroke="#80883" opacity="0" points="78 236, 65 258, 79 253, 107 329, 134 309, 89 250, 109 249"><animate attributeName="opacity" begin="mouseover" dur="100ms" from="0" to="1" fill="freeze" /><animate attributeName="opacity" begin="mouseout" dur="100ms" from="1" to="0" fill="freeze" /></polygon></a>
<a xlink:href="a49.svg"> <polygon fill="#DCF5GG" stroke="#33DC58" opacity="0" points="423 201, 397 218, 419 212, 290 310, 446 317, 426 212, 441 216"><animate attributeName="opacity" begin="mouseover" dur="100ms" from="0" to="1" fill="freeze" /><animate attributeName="opacity" begin="mouseout" dur="100ms" from="1" to="0" fill="freeze" /></polygon></a></svg>

Im Offline-Modus funktioniert alles einwandfrei. Was mache ich falsch?
Gruß Benni
.

  1. Hallo,

    Hallo, ich habe ein Problem zu SVG. Nach dem Hochladen einer SVG-Datei ist diese nicht mehr funktionsfähig. Der Befehl "xlink" wird nicht akzeptiert. Hier mal der Quelltext:

    »»...

    <svg width="512" height="384" xmlns="http://www.w3.org/2000/svg">

    Fuege hier den XLink-Namespace hinzu:

    <svg width="512" height="384" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">

    MfG, Thomas

    1. Hallo Thomas, erst mal vielen Dank für deine Hilfe. Habe die Datei jetzt neu hochgeladen. Die Fehleranzeige ist verschwunden, allerdings zeigt das Fenster jetzt folgenden Text an (sieht sehr nach xml aus):

      <?xml version="1.0" encoding="ISO-8859-1" standalone="no" ?>
        <!DOCTYPE svg (View Source for full doctype...)>

      • <svg width="512" height="384" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" preserveAspectRatio="xMidYMid meet" zoomAndPan="magnify" version="1.0" contentScriptType="text/ecmascript" contentStyleType="text/css">
          <image x="0" y="0" width="512px" height="384px" xlink:href="bes (0).jpg" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad" preserveAspectRatio="xMidYMid meet" />
      • <a xlink:href="a1.svg" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="replace" xlink:actuate="onRequest">
      • <polygon fill="#DBAA66" stroke="#80883" opacity="0" points="78 236, 65 258, 79 253, 107 329, 134 309, 89 250, 109 249">
          <animate attributeName="opacity" begin="mouseover" dur="100ms" from="0" to="1" fill="freeze" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="other" xlink:actuate="onLoad" restart="always" calcMode="linear" additive="replace" accumulate="none" />
          <animate attributeName="opacity" begin="mouseout" dur="100ms" from="1" to="0" fill="freeze" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="other" xlink:actuate="onLoad" restart="always" calcMode="linear" additive="replace" accumulate="none" />
          </polygon>
          </a>
      • <a xlink:href="a49.svg" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="replace" xlink:actuate="onRequest">
      • <polygon fill="#DCF5GG" stroke="#33DC58" opacity="0" points="423 201, 397 218, 419 212, 290 310, 446 317, 426 212, 441 216">
          <animate attributeName="opacity" begin="mouseover" dur="100ms" from="0" to="1" fill="freeze" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="other" xlink:actuate="onLoad" restart="always" calcMode="linear" additive="replace" accumulate="none" />
          <animate attributeName="opacity" begin="mouseout" dur="100ms" from="1" to="0" fill="freeze" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="other" xlink:actuate="onLoad" restart="always" calcMode="linear" additive="replace" accumulate="none" />
          </polygon>
          </a>
          </svg>

      Vielleicht hast du ja noch eine Idee, was nicht stimmen könnte.

      Die Addresse der Datei lautet übrigens
      http://www.grundschule-leutenberg.de./andere/Rundgangstart/a0.svg

      Würde mich sehr freuen, wenn du mir noch mal behilflich sein könntest.

      Viele Grüße Benni

      1. Hallo,

        Vielleicht hast du ja noch eine Idee, was nicht stimmen könnte.

        Die Addresse der Datei lautet übrigens
        http://www.grundschule-leutenberg.de./andere/Rundgangstart/a0.svg

        Würde mich sehr freuen, wenn du mir noch mal behilflich sein könntest.

        Der Server liefert die SVG-Datei mit "Content-Type: text/plain" aus. Du muss dich an den Serveradmin wenden, dass er die Mime-Type für die SVG-Dateien in eurem Apache richtig angeben möge.

        Grüße
        Thomas

        1. Vielen Dank, werde morgen mein Glück bei meinem Anbieter versuchen.

          Grüße Benni

          1. Hallo,

            Vielen Dank, werde morgen mein Glück bei meinem Anbieter versuchen.

            Alternativ eine .htaccess mit diesem Inhalt anlegen bzw. ergaenzen:

            AddType image/svg+xml svg
            AddType image/svg+xml svgz

            MfG, Thomas