like @lucidbrot comments in another answer "It's important to realize that the xmlns="..." is required even if it's not there in the inspect element page"
– NorfeldtJan 24 '20 at 21:52
3
I don't think this works if the SVG is styled by external CSS; it only works if the styling is contained within the SVG element.
– MerchakoDec 23 '21 at 17:38
The tool is amazing, but in case you are using Firefox where in the inspector there's not a "Copy Element" option, you can either use Copy > Inner HTML on the
– ManuAlvarado22Sep 07 '22 at 21:21
Unless I am misunderstanding you, this could be as easy as inspecting (F12) the icon on the page to reveal its .svg source file path, going to that path directly (Example), and then viewing the page source code with Control+u. Then just save that code.
To save the code, paste it into a text editor such as google docs. Then save the file as a .txt file. Change the end of that file's name from ".txt" to ".svg", and now you have your file as a .svg. This method does not involve getting any external extensions or downloading any programs, and it functions the same.
i have a strange feeling he wants to know how to download one then he will do the rest, i may be wrong :-)
– SyferMay 05 '17 at 11:54
2
For some reason it does not work the same as for png or jpeg images. I see blank screen when going to svg directly and if in console there are some errors.
– Vladyslav KMay 05 '17 at 11:55
1
@VladyslavKushney I think they are coloring the SVG with CSS that's why its showing as white.
– SyferMay 05 '17 at 11:57
This works fine! You just have to save svg code as `.txt` file and open it in any code editor like VS Code to rename its extension to `.svg`.
– akshay_sushirFeb 23 '22 at 05:05
This is the only method I could get working. Thanks. You should also be able to use inkscape as described here: https://en.wikipedia.org/wiki/Wikipedia:Graphics_Lab/Resources/PDF_conversion_to_SVG
– Robert LuggFeb 10 '19 at 21:31
Very helpful. I managed to save with firefox a graph originated and manipulated dynamically from d3.js. However, the edges interactions was missing in the pdf. Fortunately, it works in chrome when printing showing all nodes and their edges.
– daniel souzaFeb 28 '19 at 22:13
16
You can copy the HTML svg tag from the website, then paste the code on a new html file and rename the extension to svg. It worked for me. Hope it helps you.
This is the best answer, imho. You don't need any 3rd-party apps to convert, just simply rename the file from .html to .svg and your computer will treat it as an image file.
– x.g.Feb 25 '20 at 00:31
Any suggestions for how to incorporate CSS that is found outside the `` tag?
– mlibbyJun 23 '21 at 13:43
6
They are all logged under Elements in google chromes developer tools.
It's important to realize that the `xmlns="..."` is required even if it's not there in the inspect element page
– lucidbrotOct 18 '18 at 16:36
3
@mayersdesign solution is fine But for me it's not working. You just have to save svg code as a .txt file and open it in any code editor like VS Code / Atom to rename its extension to .svg. Try to open svg in any browser, if it does not work then just add xmlns in svg start tag <svg xmlns="http://www.w3.org/2000/svg" > like this and you have your svg ready.
You can download individual ones from their site like @mayerdesign has stated or you can click on the download link on the left and you can download the whole pack.
Once you're on a web page, click the extension's icon next to the URL bar and a new tab will open showing you all the SVG files it found on the page. You can copy an SVG file to your clipboard, download only the few you need, or click the 'Download all SVGs' button to add them all to a zipped file and download them.
When you're on a page that doesn't let you reach the SVG via its own URL (e.g. an inline SVG), you can print the page and select PDF as the target output. Once the PDF has been saved, you can open it in an image editor that supports vector (e.g. Adobe Illustrator), select only the vector art you want, and cut and paste it into a new file in the image editor.
I had to get my hands on a svg that was included super weird. Couldn't find the source anywhere. All tips and most tools failed to extract the picture. Finally I found a tool that did the job: https://github.com/rossmoody/svg-gobbler
There is a Chrome and Firefox extension. I used the Chrome extension.
I don't know if this already been answered correctly or not. Well. Downloading the file from the source is not the resolution. How to grab *.svg from URL.
I installed 'svg-grabber' add-on to Google Chrome. That only partially resolve my problem, as Google Chrome does not have the shortcut to 'Back' one page.
I was trying to download the files from URL, but I kept getting an error, that there are no svg files on this page when I can see 40 of them. You can click on them, so they will open, but you cannot save it.
The folder within WordPress: .../static/img/icons/
I added 'Go Back With Backspace' add-on to Chrome, as I had to click on each file separately, as if they are white icons (that I am currently looking for), you will not see them. You have to click on the file. Then back. It was taking too long. Now is fine. There is a soft to download specific folder, but I do not want to download half of the internet, to just have get a white .
When you click on a white icon, a new tab opens, but it is all white. Then you click on svg-grabber icon in Chrome and it will open it in a new window on a black background with a button download all svg.
I just tried it on another website, in firefox. After trying to save the webpage, it gave me a save-file-as dropdown menu with an option called webpage, svg only.
-1
CTRL+P hit print command
in destination chose Save As PDF you are done