M
M
Mikhail Lebedev2022-01-10 14:52:43
SVG
Mikhail Lebedev, 2022-01-10 14:52:43

Embedded .svg image not showing on website?

there is a .svg file, it has a graphic + a .png picture
, you need to display this on the main screen of the site, BUT the embedded .png does not want to be displayed ...
If you just open this svg in the browser using the link - everything is ok (displayed as needed)
example below - should be 2 squares red(png) and blue(svg)

Answer the question

In order to leave comments, you need to log in

2 answer(s)
I
Ivan Bogachev, 2022-01-10
@zaza41rus

On MDN they say that this is a security issue (there is only about Gecko, but we can assume that this is the case everywhere). If SVG is used as an image, then it is no longer possible to load other external resources in it. Alternatively, you can use the embed tag instead of img, and everything will work without such restrictions.

S
Sergey Smagin, 2022-01-10
@gitosik

with linking the cant is possible.
61dc221012c4e051475143.png

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question