Home  >  Article  >  Web Front-end  >  How to set placeholder through css

How to set placeholder through css

不言
不言Original
2018-06-12 14:55:145904browse

This article mainly introduces the method of setting placeholder through css. It has certain reference value. Now I share it with you. Friends in need can refer to it.

input::-webkit-input-placeholder {    
color:#fff;    
text-align: center;    
font-size: 0.46rem;
}
input:-moz-placeholder {    
color:#fff;  
text-align: center;    
font-size: 0.46rem;
}
input:-ms-placeholder {    
color:#fff;  
text-align: center;    
font-size: 0.46rem;
}
input:-o-placeholder {    
color:#fff;  
text-align: center;    
font-size: 0.46rem;
}
input:placeholder {    
color:#fff;  
text-align: center;    
font-size: 0.46rem;
}

The above is The entire content of this article is hoped to be helpful to everyone's study. For more related content, please pay attention to the PHP Chinese website!

Related recommendations:

About css control UL LI style analysis

Four states in the css style of a tag

The above is the detailed content of How to set placeholder through css. For more information, please follow other related articles on the PHP Chinese website!

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