I want to change color in data image svg, right now current color is blue, i want to change its color to this color code #266C5E, can anyone please help me how to do that ?
data:image/svg xml;charset=utf8,
CodePudding user response:
You have to URL encode # in your svg code. So replace blue with #266C5E instead of #266C5E(which # is # URL encoded).
Here's the replaced version:
data:image/svg xml;charset=utf8,
div {
width: 180px;
height: 180px;
background-image: url("data:image/svg xml;charset=utf8,");
}
<div></div>
