did not like the order of params for the function Cr.appendChildElement, use Cr.insertNode instead