그래디언트 이미지를 확장하여 이전에 회색으로 표시하도록 제안 했으므로 (그레이는 음영이 아닌 원하는 음영이됩니다) 또는 -webkit-gradient
을 사용합니다 (일부 구형 브라우저는 지원하지 않을 수 있습니다. 그것은 ....)
예 :
background: url(http://i.imgur.com/ajzo0.jpg) rgb(145,127,103); /* Old browsers (in case they don't support webkit, use the original image. */
background: -moz-linear-gradient(top, rgba(145,127,103,1) 0%, rgba(236,235,233,1) 100%); /* FF3.6+ */
background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(145,127,103,1)), color-stop(100%,rgba(236,235,233,1))); /* Chrome,Safari4+ */
background: -webkit-linear-gradient(top, rgba(145,127,103,1) 0%,rgba(236,235,233,1) 100%); /* Chrome10+,Safari5.1+ */
background: -o-linear-gradient(top, rgba(145,127,103,1) 0%,rgba(236,235,233,1) 100%); /* Opera 11.10+ */
background: -ms-linear-gradient(top, rgba(145,127,103,1) 0%,rgba(236,235,233,1) 100%); /* IE10+ */
background: linear-gradient(to bottom, rgba(145,127,103,1) 0%,rgba(236,235,233,1) 100%); /* W3C */
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#917f67', endColorstr='#ecebe9',GradientType=0); /* IE6-9 */
네, 그것은 더 많은 코드이지만, 일을 끝내야한다.
참고 : 새 수업을 추가해야합니다 .... 참조 : http : //jsfiddle.net/JfyAR/ – nwong212