0

I have seen these questions dotted around the web with little response.

I add some CSS in jQuery like:

$('#object').css('background-image', 'url(../../Content/Images/green-tick.png');

It works in all browsers expect from Safari.

Anyone know as of why? Most answers I have seen to this question say to actually use

'background-image'

(This answers or 'guides' are mostly not on stackoverflow)

I cant debug the browser as I am only testing this with an iPad.

Thanks for your help.

user3428422
  • 4,300
  • 12
  • 55
  • 119

1 Answers1

0

Check the height that you have allocated.
I had a scenario with height: 100%. That didn't work in Safari. It wanted the height applied in pixels else the height got set to 0 and hence the image appeared not to be shown (although it was there. It just had a height of zero)