I want to download the content from the following link to a file .
I tried using wget and curl commands , the file has downloaded data but is not in readable format or json string.
command I have used is :
wget -O ~/ks/json.txt "http://api.geonames.org/postalCodeLookupJSON?postalcode=6600&country=AT&username=demo"
I want the output file to contain data in json format itself as shown in the link.
EDIT
I used Vi editor to read the output , below is the sample i got as output :
^_<8b>^H^@^@^@^@^@^D^@Õ[^?wÚ8³þ*ºì<9e>¾d^Wÿ¶1Ð$û¦MÚdÛ$½MÚݾKO<8e>°^E(16kË¡´§÷³ß^YÉ^F^C&%ÙûÏÍÙ-F<9e>^Y<8d>¤<99>G3#ñÁ^E<9b>d<8d>Þ_ß^Z<82><8e>ð¡1¦a<92>L^[Æ<84>NS^Væ^A<83>ç9MãÆçV#<99>Å,mô¾5R6Í^E^U<<89>^[=Ûi5ò<8c>¥7<lô^\ÏqÝvÙ"æSÖè^Aõ<88>g<82><81>8<90>E<83><80>MÅMJ^E¼ò;Æ4M<86><b7|BGH=^Vb<9a>õ^Lc6<9b>é£<94>ÞSAS=H&<86>z4Âд¼6^[ºf7^XZagà<87>~×¶CÚa<8e>^[Ø<83>ß²^CËî<^K^OxÈbÁ<83>$~<96>^^¼{ýlx`A÷!Ϧ^Q<9d>ßÄt<82><9d>½&oR<9e><8d>cJ®èdJÅ^XH"^^ß^Uz<80>^Z<99> Á]rÏÒa<94>̤^^8´Ì(Fj<8c>´;%AË