added workaround to jquery not parsing invalid markup (which is used for fragments). first the template is parsed as xml, the fragments are found then the html is parsed. added loader.xmlToHtml.