Output format chnages

Rethought approach to specifying xml/json format output flag. Now
requires Accept: header to specify output format. Default format used
when not explictitly specified.
version updated
Tweaked format chnages & moded doco