Home  >  Article  >  Web Front-end  >  Encapsulates a JS class (clip) that automatically generates gradient words_javascript skills

Encapsulates a JS class (clip) that automatically generates gradient words_javascript skills

WBOY
WBOYOriginal
2016-05-16 18:59:001315browse

All you need to do is add the text that requires gradient color to an outer container (span tag or a tag can be used) in the HTML page, and then add the name attribute to this tag to mark the gradient element, and the rel attribute indicates the color of the gradient. , the format of the rel attribute is very important:

Copy code The code is as follows:

rel="# Hexadecimal Color-#Hex Color"

One less character or one more character will not work.
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn