设置input样式代码:

input::-webkit-input-placeholder{ /*WebKit browsers*/

color: red;

}

input::-moz-input-placeholder{ /*Mozilla Firefox*/

color: red;

}

input::-ms-input-placeholder{ /*Internet Explorer*/

color: red;

}

设置input标签的placeholder的样式的更多相关文章

  1. 更改input标签的placeholder的样式

    主要是要区别不同浏览器的不同css类 在input框中有时想将输入的字和placeholder设为不同的颜色或其它效果,这时就可以用以下代码来对placeholder进行样式设置了. input::- ...

  2. [oldboy-django][2深入django]学生管理(Form)-- 编辑(设置input标签属性,设置input标签默认显示值,设置input的类型)

    1 django 后台实现设置input标签属性,设置input标签默认显示值,设置input输入框类型 # Form生成html标签 a. 通过Form生成Input输入框,Form标签,以及sub ...

  3. 设置input标签placeholder字体颜色

    有时会遇到这样的需求,输入框的默认提示文字与用户输入的文字不同. <input className="city" placeholder="城市"/> ...

  4. 关于input标签和placeholder在IE8,9下的兼容问题

    一. input常用在表单的输入,包括text,password,H5后又新增了许多type属性值,如url, email, member等等,考虑到非现代浏览器的兼容性问题,这些新的type常用在移 ...

  5. 设置Input标签Date默认值为当前时间

    需求:想设置Imput标签Date默认值为当前时间,通过JavaScript实现. <html> ...... <body> <input type="date ...

  6. 使用js设置input标签只读 readonly 属性

    先上代码: <html> <head> <title> test </title> <meta charset="utf-8" ...

  7. 改变input标签中placeholder显示的颜色

    ::-webkit-input-placeholder { /* WebKit browsers */ color: #A9A9A9; } :-moz-placeholder { /* Mozilla ...

  8. input框中修改placeholder的样式

    有时间input标签的placeholder属性会出现问题,下面是修改placeholder的样式demo input::-webkit-input-placeholder{ color:red; f ...

  9. 前端 html input标签 placeholder属性 标签上显示内容

    前端 html  input标签 的placeholder属性  标签上显示内容 <!DOCTYPE html> <html lang="en"> < ...

随机推荐

  1. hping安装过程

    转载: http://www.safecdn.cn/website-announcement/2018/12/hping-install/97.html ‎ Hping的主要功能有: 测试防火墙实用的 ...

  2. Hibernate架构

    参照: http://blog.csdn.net/lovesummerforever/article/details/19169779 http://www.w3cschool.cn/hibernat ...

  3. 登录之md5加密

    语句: password = hex_md5(password); 引入js文件: md5.js: /* * A JavaScript implementation of the RSA Data S ...

  4. leetcode991

    class Solution: def brokenCalc(self, X: 'int', Y: 'int') -> 'int': if X>=Y : return Y-X else: ...

  5. js检查字符串的包含关系

    首先想到的是str.contains(),用的时候发现报错了 正确的判断方法应该用:str.indexof(substring),不包含的话,返回-1.大小写敏感 var rsp = response ...

  6. WeakReference与SoftReference

    WeakReference与SoftReference都可以用来保存对象的实例引用,这两个类与垃圾回收有关. WeakReference是弱引用,其中保存的对象实例可以被GC回收掉.这个类通常用于在某 ...

  7. OS位数,基本概念,结合iOS

    CPU位数,一般指CPU支持的指令集位数,32位CPU对应32位的指令集,64位的CPU对应64位的指令集,不过为了向下兼容,64位CPU也支持32位的指令集. 操作系统位数,一般指操作系统对应的指令 ...

  8. 单件模式——Head First

    一.定义 单件模式(Singleton Pattern)确保一个类只有一个实例,并提供一个全局访问点. 二.适用性 1.当类只能有一个实例而且客户可以从一个众所周知的访问点访问它时. 2.当这个唯一实 ...

  9. Linux下查看与修改mtu值

    MTU:通信术语 最大传输单元(Maximum Transmission Unit)是指一种通信协议的某一层上面所能通过的最大数据包大小(以字节为单位). 我们在使用互联网时进行的各种网络操作,都是通 ...

  10. ref与out

    注意点: ref和out都是按地址传递,使用后都将改变原来参数的数值 方法定义和调用方法都必须显式使用 ref/out 关键字 ref: 作为ref参数传递的变量在方法调用中传递之前必须初始化 out ...