Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Chrome CSS Gradient Rendering Issue

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #39096

    I used a CSS button generator to create the following code:

    .blueGradient{
    background-color: #0137a3 !important;
    background: #0137a3 !important; /* Old browsers */
    background: -moz-linear-gradient(top, #ff7f04 0%, #003399 100%) !important; /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,#ff7f04), color-stop(100%,#003399)); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top, #ff7f04 0%,#003399 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top, #86aeff 0%,#3b7cff 0%,#003399 80%,#0137a3 100%); /* Opera 11.10+ */
    background: -ms-linear-gradient(top, #ff7f04 0%,#003399 100%); /* IE10+ */
    background: linear-gradient(top, #ff7f04 0%,#003399 100%); /* W3C */
    filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ff7f04', endColorstr='#0137a3',GradientType=0 ); /* IE6-9 */
    }

    The styling works perfectly for Firefox but does not work for Chrome or IE :S
    Any obvious errors in what I have done? I am currently using Chrome version 20 and am hoping to get the code to work for IE 8 and 9 and currently it doesn’t work for either version.

    You can see what I am talking about on the test page I created here: http://www.bluelinkerp.com/test.asp
    (gradient should be orange and blue, which is displayed in Firefox but not in the other browsers)

    P.s. I used extreme colours for illustrative purposes.

    #106870
    Paulie_D
    Moderator

    On looking at the CSS for the link you probably need to remove

    background: #0137A3 !important;

    If I turn it off the gradient renders in Chrome.

    #107062

    Thanks Paulie! That was the problem!

Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘CSS’ is closed to new topics and replies.