【发布时间】:2020-05-12 23:07:45
【问题描述】:
我正在使用 wordpress,我正在尝试使用 CSS 更改输入占位符内容的内容。通过这样做,我能够在桌面版本中做到这一点。
.st-location-new:before {
content: 'Routes';
visibility:visible;
}
<label class="st-location-new">Where are you going</label>
在移动版本中,我无法通过应用相同的方法更改占位符文本,但没有任何成功。我能够更改字体的颜色和大小,但不能更改内容。
<input type="text" name="location_name" class="form-control" readonly="" placeholder="Where are you going?" id="dropdown-mobile-destination" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" value="">
【问题讨论】:
-
Chrome 不再支持它。您需要改用 HTML 或 JS。