Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>「:-moz-placeholder」测试 by 一丝</title>
</head>
<body>
  <p>从 Firefox 19 开始将不再支持一个冒号的「:-moz-placeholder」伪元素,改成标准的两个冒号的「::-moz-placeholder」。今后若要兼容,开发者需要在CSS中同时书写两个伪元素。</p>
  <p><a href="https://bugzilla.mozilla.org/show_bug.cgi?id=737786" target="_blank">Bug</a> <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/::-moz-placeholder" target="_blank">文档</a></p>
  <input type="text" placeholder="Firefox 19+ 显示红色,之前版本显示绿色">
  <textarea name="" id="" cols="30" rows="5" placeholder="Firefox 19+ 显示红色,之前版本显示绿色"></textarea>
  
  
  <p>图片对比:</p>
  <img src="http://ww1.sinaimg.cn/mw1024/c1608aa0gw1e6r40io8mmj20hr08qwfg.jpg" alt="Firefox 18图片对比">
</body>
</html>
 
input{
  width: 300px;
  height: 30px;
  line-height: 30px;
  font-size: 14px;
  margin: 0;
  padding: 0 10px;
  display: block;
}
/* Firefox 19+ */
input::-moz-placeholder,
textarea::-moz-placeholder{
      color: red;
      opacity: 1;
}
input:focus::-moz-placeholder,
textarea:focus::-moz-placeholder{
      color: blue;
}
/* Firefox 19- */
input:-moz-placeholder,
textarea:-moz-placeholder{
      color: green; 
}
input:focus:-moz-placeholder,
textarea:focus:-moz-placeholder{
      color: yellow;
}
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
yisipro
0viewers