Opened 8 years ago

Closed 7 years ago

#3520 closed defect (fixed)

postcode should be a string?

Reported by: booo Owned by: geocoding@…
Priority: major Milestone:
Component: nominatim Version:
Keywords: reverse geocoding, json Cc:


Request in question:

JSON does not support integers with leading zeros. I'm not sure how complex postcodes could be. Perhaps the best way to fix the problem is to return a string. This could be done in javascript_renderData by removing the if statement with is_int. If we would like to parse ints and floats we should check for is_int and return (int) $xVal or (float) $xVal I guess.

Thx for your help.

Change History (2)

comment:1 Changed 7 years ago by Tom Hughes

Owner: changed from openstreetmap@… to geocoding@…

comment:2 Changed 7 years ago by Sarah Hoffmann

Resolution: fixed
Status: newclosed

All elements of the json response are now returned as strings.

Note: See TracTickets for help on using tickets.