adding xml or json conditionals