N
N
Nikita Nafranets2016-02-16 02:20:28
HTML
Nikita Nafranets, 2016-02-16 02:20:28

How to put mask on svg text?

There is a word "TEXT". There is a Svg file with a gradient. How can I attach this svg file to the word text?
Here is the svg code and I keep it in text-gradient.svg file

<svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" >
<defs> 
<linearGradient id="lgrad" x1="50%" y1="0%" x2="50%" y2="100%" > 
<stop offset="0%" style="stop-color:rgb(46,73,152);stop-opacity:1" />
<stop offset="100%" style="stop-color:rgb(1,142,210);stop-opacity:1" />
</linearGradient> 
</defs>
<rect x="0" y="0" width="100%" height="100%" fill="url(#lgrad)"/>
</svg>

css.yoksel.ru/css-and-svg-masks found such an article, but I can't master it. It is for advanced people who know what svg is. I don't understand at all. Help me please. Thanks in advance.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Anna_BS, 2016-02-16
@Dimensi

Here is the text with your gradient

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question