innerHTML non è una semplice proprietà, è un setter, il che vuol dire che quando tu gli assegni un valore il browser ci fa qualcosa (un po' come accade con document.cookie). In particolare, in questo caso il browser proverà a completare i tag che non si chiudono. Ecco perché non puoi assegnare un innerHTML a pezzi! Prova così, vedrai che funzionarà:

codice:
var tuaVariabile = "<TABLE width='360' style='height:380; background: url(sfondo_f.gif) no-repeat;'><TR><TD>";
tuaVariabile += "<DIV style='height: 25; width: 360; display: none; cursor: pointer;'></DIV>";
tuaVariabile += "<DIV id='15' style='display: inline;'><TABLE cellpadding='2' cellspacing='0'><TR><TD>[img]45.jpg[/img]</TD><TD>[img]44.jpg[/img]</TD></TR></TABLE></DIV>";
tuaVariabile += "<DIV id='14' style='display: inline;'><TABLE cellpadding='2' cellspacing='0'><TR><TD>[img]42.jpg[/img]</TD><TD>[img]41.jpg[/img]</TD></TD></TR></TABLE></DIV>";
tuaVariabile += "<DIV style='height: 25; width: 360; display: block; cursor: pointer;'></DIV>";
tuaVariabile += "</TD></TR></TABLE>";

document.getElementById("cart").innerHTML = tuaVariabile;