XML working now (still little performace bugs)