Added option to return the tag list as JSON or comma-separated list -- last by default.