Add json output format

Need to specify filename with .json extension in config
Also change new output format variable to json. Default is php