The Gradiennt effect

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • gautamz07
    New Member
    • Sep 2013
    • 26

    The Gradiennt effect

    Code:
    background: #b3dced; /* Old browsers */
    background: -moz-linear-gradient(top,  #b3dced 0%, #29b8e5 50%, #bce0ee 100%); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#b3dced), color-stop(50%,#29b8e5), color-stop(100%,#bce0ee)); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top,  #b3dced 0%,#29b8e5 50%,#bce0ee 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top,  #b3dced 0%,#29b8e5 50%,#bce0ee 100%); /* Opera 11.10+ */
    background: -ms-linear-gradient(top,  #b3dced 0%,#29b8e5 50%,#bce0ee 100%); /* IE10+ */
    background: linear-gradient(to bottom,  #b3dced 0%,#29b8e5 50%,#bce0ee 100%); /* W3C */
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#b3dced', endColorstr='#bce0ee',GradientType=0 ); /* IE6-9 */
    background: #d2dc9d url(images/blackgoose.png) no-repeat center 100px fixed;
    When i take off the last line the gradient effect works , but the image is not shown in the background and when i add the last line the image shows up but the gradient effect does not work . Why is it ?

    by last line i mean : -

    Code:
    background: #d2dc9d url(images/blackgoose.png) no-repeat center 100px fixed;
    The code is auto generated using www.colorzilla.com/gradient-editor/ , if that helps .
    Last edited by gautamz07; Apr 28 '14, 08:02 AM. Reason: adding more info
  • Rabbit
    Recognized Expert MVP
    • Jan 2007
    • 12517

    #2
    You can only have one background per element. If you're trying to layer things, you will have to use a div element

    Comment

    Working...