Good morning:
I have several problems with CSS transition command in a button. I am trying to do a background color change with a transition effect, and surprisely it only works in Internet Explorer, and it doesn't work in Firefox, Chrome or Opera, I don't know why.
My code:
#button_example{
background: -webkit-linear-gradient(#0CA5E2, #FFFFFF); /* For Safari 5.1 to 6.0 - Chrome, Safari, Android, iOs*/
background: -o-linear-gradient(#0CA5E2, #FFFFFF); /* For Opera 11.1 to 12.0 */
background: -moz-linear-gradient(#0CA5E2, #FFFFFF); /* For Firefox 3.6 to 15 */
background: linear-gradient(#0CA5E2, #FFFFFF); /* Standard syntax */
background: -ms-linear-gradient(top, #0CA5E2 0%, #FFFFFF 100%); /* IE10+ */
border-radius: 5px;
-webkit-box-shadow:0px 1px 1px #DEDEDE;
-moz-box-shadow:0px 1px 1px #DEDEDE;
box-shadow:0px 1px 1px #DEDEDE;
/* margin-left: 5px; */
margin-top: 10px;
width: 280px;
height: 40px;
font-size: 1.5em;
-webkit-transition: all 0.5s ease-out;
-moz-transition: all 0.5s ease-out;
-o-transition: all 0.5s ease-out;
-ms-transition: all 0.5s ease-out;
transition: all 0.5s ease-out;
}
#button_example:hover {
background: -webkit-linear-gradient(#FFFFFF, #0CA5E2); /* For Safari 5.1 to 6.0 - Chrome, Safari, Android, iOs*/
background: -o-linear-gradient(#FFFFFF, #0CA5E2); /* For Opera 11.1 to 12.0 */
background: -moz-linear-gradient(#FFFFFF, #0CA5E2); /* For Firefox 3.6 to 15 */
background: linear-gradient(#FFFFFF, #0CA5E2); /* Standard syntax */
background: -ms-linear-gradient(top, #FFFFFF 0%, #0CA5E2 100%); /* IE10+ */
border-radius: 5px;
-webkit-box-shadow:0px 1px 1px #DEDEDE;
-moz-box-shadow:0px 1px 1px #DEDEDE;
box-shadow:0px 1px 1px #DEDEDE;
/* margin-left: 5px; */
margin-top: 10px;
width: 280px;
height: 40px;
font-size: 1.5em;
}
<button id="button_example" type="button" onclick="window.location.href='www.google.es'">Google</button>
I don't know how to do, I have view all tutorials, but none of them fix my problem. Any solution please?
Thanks.