Arun
Arun

Reputation: 53

Create svg without using public Url

Hi i am using svg to draw lines but my problem is i am using public url's to draw line `var svgnode = document.createElementNS('http://www.w3.org/2000/svg', 'svg');

        svgnode.setAttributeNS(null, "style", "overflow:none");

        var defs = document.createElementNS('http://www.w3.org/2000/svg', "defs");
        var marker = document.createElementNS('http://www.w3.org/2000/svg', "marker");
        var path = document.createElementNS('http://www.w3.org/2000/svg', "path");`

how to achieve the same without using pubic urls

Upvotes: 0

Views: 510

Answers (1)

Robert Longson
Robert Longson

Reputation: 124229

That's not a URL, it just looks like one, it's actually a namespace. w3c chose namespaces to have the format of URLs but there's actually no connection between them otherwise.

Upvotes: 1

Related Questions