set layout to false if json or xml type