谁能告诉我如何在名为 siteContents2 的 javascript 变量中正确使用 myVariable 和 myVariable2?此时我的代码不显示图像缩略图及其名称。
var siteContents2=""
+"<li>"
+"<img src=""+myVariable2+"" width=\"180\" height=\"148\""
+"alt=\"'+myVariable+'\" class=\"png\">"
+"<a href=\"'+myVariable+'" class=\"corners\"> <\/a>"
+""
+" "
+" "
+" "
+"<div class=\"thumbnail_label\">mango<\/div>"
+" "
+" "
+" "
+""
+"<div class=\"details\">"
+"<div class=\"title\">"
+" <a href="
+" \"'+myVariable+'">"+myVariable+"<\/a>"
+" <span class=\"season\">2<\/span>"
+" <\/div>"
+" <ul class=\"subject\">"
+" <li>mango sesaon<\/li>"
+" <\/ul>"
+" <ul class=\"sub-info\">"
+" <li class=\"location\">us<\/li>"
+" <li class=\"price\">2 dollar<\/li>"
+" <\/ul>"
+" <\/div>"
+"<\/li>";
$('#myDiv').append(siteContents2)