views:

48

answers:

0

I have this code:

$('<img>').attr('src',pages[i]['src']).appendTo('#cache');

which should create an <img> element from an array entry and append it to the element with an ID of cache.

However, IE reports the error:

'attr(...)' is null or not an object

FF, Chrome and Safari have no issues.

Thanks.