How to append two image tags in div tag using jQuery -


iam trying place 2 image tags different images/src values init, in end 2 image tags have been appended same src value instead of different. may know s wrong append:

$("<div/>", {   "id": 'card'+i,   "class": blockarr[k],   html: $("<img src='"+key+"'/><img src='_ls-global/layout-images/layout2.png'/>")  }).appendto("#gtable"); 

any ideas ?

thanks

you can supply plain html in case:

demo

$("<div/>", {   id: 'card'+i,   class: blockarr[k],   html: "<img src='"+key+"'/><img src='_ls-global/layout-images/layout2.png'/>" }).appendto("#gtable"); 

Comments

Popular posts from this blog

javascript - Count length of each class -

What design pattern is this code in Javascript? -

hadoop - Restrict secondarynamenode to be installed and run on any other node in the cluster -