Es gibt SVG-Grafiken, die auf Webseiten „verschwinden“, obwohl sie als Datei im Browser angezeigt werden können. Das weiß ich, weil ich eine SVG-Grafik, die im Browser angezeigt wurde, in eine Webseite einbinden wollte…
In solchen Fällen die SVG-Grafik mit Photoline laden und sofort wieder speichern. Fertig.
Darauf kommen hat etwas länger gedauert.
Was da passiert, habe ich bei BUOA! etwas ausführlicher beschrieben.
Wenn SVG-Grafiken in Webseiten „unsichtbar“ sind
-
- Betatester
- Posts: 1046
- Joined: Mon 07 Jan 2008 19:52
- Location: Birkenwerder / Berlin
Wenn SVG-Grafiken in Webseiten „unsichtbar“ sind
Screencasts zu Photoline: http://www.buoa.de • Win 10x64 / PL64, immer die aktuellste Beta-Version.
-
- Mitglied
- Posts: 254
- Joined: Sat 26 Jul 2014 10:13
- Location: California
Re: Wenn SVG-Grafiken in Webseiten „unsichtbar“ sind
A few points:
The namespace xmlns="http://www.w3.org/2000/svg" is required for external svg files, optional for inline code.
Namespace prefixes (xmlns:xlink="http://www.w3.org/1999/xlink") are not needed if they are not used in the code; for example, xlink:href is deprecated in favor of just href.
No browser makes use of the version specification so there is no need to include it.
SVG width and height attributes can be non-integers (unlike regular html elements). The real number will be used if scaling is applied.
The recommended minimum inline requirements:
<svg
width="126" height="95" OR style="width: 126px; height: 95px"
viewBox="0 0 126 95">
An external svg file should begin with:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<svg xmlns="http://www.w3.org/2000/svg"
width="126" height="95" OR style="width: 126px; height: 95px"
viewBox="0 0 126 95">
The namespace xmlns="http://www.w3.org/2000/svg" is required for external svg files, optional for inline code.
Namespace prefixes (xmlns:xlink="http://www.w3.org/1999/xlink") are not needed if they are not used in the code; for example, xlink:href is deprecated in favor of just href.
No browser makes use of the version specification so there is no need to include it.
SVG width and height attributes can be non-integers (unlike regular html elements). The real number will be used if scaling is applied.
The recommended minimum inline requirements:
<svg
width="126" height="95" OR style="width: 126px; height: 95px"
viewBox="0 0 126 95">
An external svg file should begin with:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<svg xmlns="http://www.w3.org/2000/svg"
width="126" height="95" OR style="width: 126px; height: 95px"
viewBox="0 0 126 95">