I have the following code in my html page. The icon exists and the path to the image is valid. Every browser seem to display this correctly except IE8 which only shows a rey box. Does anyone know a way around that?
<script type="text/javascript" charset="utf-8">
var sDate = new Date(1323637200000);
$(function() {
$( "#datepicker" ).datepicker({
minDate: -151,
maxDate: "-1D",
dateFormat: "dd-mm-yy",
defaultDate: sDate,
firstDay: 6,
showOn: "button",
buttonImage: "/public/images/ico-calendar.gif",
buttonImageOnly: false,
onSelect: function(mydate) {
window.location.href="/reports/"+mydate;
}
});
});
</script>
<input type="hidden" id="datepicker" />
After a lot of fiddling I discovered that resetting the maximum width on the icon image allowed the icon to appear correctly. That sounds like a quirk with IE 8.
change the html to
Fiddle here. I have not given a valid image path. You need to check it on your dev system.