fixing a load of redirection issues and adding placeholders to the xml