GeoNames Home | Postal Codes | Download / Webservice | About 

GeoNames Forum
  [Search] Search   [Recent Topics] Recent Topics   [Groups] Back to home page 
[Register] Register / 
[Login] Login 
Messages posted by: Anonymous  XML
Profile for Anonymous -> Messages posted by Anonymous [359] Go to Page: Previous  1, 2, 3 ... 15 , 16, 17, 18 Next 
Author Message
I've downloaded the geonames database (allCountries.zip), and I've noticed that you use 'UK' as the country code for United Kingdom (cities like London have this country code). On the other hand, according to this (official?) list, the ISO country code for UK is 'GB'

http://www.iso.org/iso/en/prods-services/iso3166ma/02iso-3166-code-lists/list-en1.html

Is this an error in the Geonames database or there is another explanation?

Thank you very much for the service (I am working on a site where I plan to use Geonames).

Cheers,

xavi
Thanks marc...
That's realy fantastic....it will help me lot...thanks again....
Hi,

The Reverse Geocoding Webservice findNearbyPlaceName only returns Name,GeonameId,Lat,Lng and CountyCode.

Is there any way to get more detail information of the geoname?

Or is there any other service which can provide Detail data from GeonameId?

Thanks and Regards
Sameer
hi all,

be aware that in the xml country data set http://ws.geonames.org/countryInfo? the western and eastern longitude of bBox are interchanged.
e.g. Germany:
<bBoxWest>15.038887</bBoxWest>
<bBoxNorth>55.056664</bBoxNorth>
<bBoxEast>5.864166</bBoxEast>
<bBoxSouth>47.274719</bBoxSouth>

it should be a quick fix.

best regards,
Dirk
Hi, I'm french and I'm trying to use your database but I've found some problems in the 'admin1 code' column. Some of the cities doesn't have an 'admin1 code' whereas they have one in the NGA database ('Grenoble' for example) and I really need them. Is it normal? How can I get the lacking codes?

(Sorry for my english)
Hi Marc,

It's working now. Thanks a lot!

Now, is there any way to change the name of an adm1?
In the gns database they have "Castilla-La Manacha" instead of "Castilla la Mancha" (extra hyphen and extra "a").

Is there any way to report such errors to your database?
This works like a charm, though I realized how sily I am
Thank you very much, Marc and Geonames!

marc wrote:

You have to add a parameter callback=getGeo to tell our werbservice the name of the function where you are processing the result.
http://ws.geonames.org/findNearbyPostalCodesJSON?lat=45&lng=-123&callback=getGeo 
Hi,

I'm miserably failing to understand how can I move a populated place.

I click on its marker, the info window shows up, I click on "Move", I close the info window (it's covering the right position), I click on the right position for that city, and then nothing.

On the left pane it says

move Cox
1. point mouse to new location
2. save new coordinates

How can I "save the new coordinates"?

Thank you for a great service!

Cheers,


Marc, would you like to try the following code and see what's wrong?
Put "http://ws.geonames.org/findNearbyPostalCodesJSON?lat=45&lng=-123" directly to a brower window, I can see an output like: {"postalCodes":[{"postalCode":"97303","lat":44.992731,"placeName":"Salem","countryCode":"US","lng":-123.01672},{"postalCode":"97313","lat":44.984941,"placeName":"Salem","countryCode":"US","lng":-122.998756}]}

However, with the call of bObj.addScriptTag(), I always saw the error message: Error: Expected ';' Code: 0

I'd really appreciate your comments!

<html>
<body>
<script type="text/javascript" src="jsr_class.js"> </script>
<script type="text/javascript">
// Define the callback function
function getGeo(jsonData) {
alert('...');
}
// The web service call
var req = 'http://ws.geonames.org/findNearbyPostalCodesJSON?lat=45&lng=-123';
// Create a new request object
bObj = new JSONscriptRequest(req);
// Build the dynamic script tag
bObj.buildScriptTag();
// Add the script tag to the page
bObj.addScriptTag();
</script>
</body>
</html>

marc wrote:
Who is 'they'? It is a company starting with 'Y'? If yes, I don't think 'they' offer reverse geocoding.
But this is no problem as you can use our service for this

Marc 
I know they offer JSON variant for geocoding, but it doesn't seem like they offer JSON for reverse geocoding.
Maybe I'm wrong?

Many thanks for your reply!


marc wrote:
The problem with your code lies in a browser security feature which makes it impossible to call an xml service from an other server then the one the page has been loaded from.

See this geonames faq entry for details :

http://forum.geonames.org/gforum/posts/list/11.page

Instead of calling the xml service :
http://ws.geonames.org/findNearbyPostalCodes?postalcode=6020&country=CH

you can call the JSON variant of the same service :
http://ws.geonames.org/findNearbyPostalCodesJSON?postalcode=6020&country=CH

For the JSON format there is no security restriction on the browser.

Marc 
I'm trying to use the reverse geocoding service here to get postal codes by lat/lng info in Javascript.
However, it never runs into the callback function because I always get the redyState as 1 (means retrieving) and I cannot get responseText. The URL I make works when I use it manually with a browser.
So what's wrong with the following code?
Your helps are highly appreciated!

var xmlhttp = null;
var RevGeocodingHtml = 'http://ws.geonames.org/findNearbyPostalCodes?lat='+lat+'&lng='+lng;
if (window.XMLHttpRequest) {
xmlhttp = new XMLHttpRequest();
if ( typeof xmlhttp.overrideMimeType != 'undefined') {
xmlhttp.overrideMimeType('text/xml');
}
} else if (window.ActiveXObject) {
xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
} else {
alert('Perhaps your browser does not support xmlhttprequests?');
}
xmlhttp.open('GET', RevGeocodingHtml, true);
alert(xmlhttp.readyState);
xmlhttp.onreadystatechange = function() {
if (xmlhttp.readyState == 4 && xmlhttp.status == 200) {
// do something with the results
var myObj = eval ( xmlhttp.responseText );
} else {
// wait for the call to complete
}
};
good work!


best regards from russia
hugo
I've been studying the samples, but I'm missing something. I copied the source code from the example page you cited and inserted my own API code. The result is at http://www.geoworld.org/mapsSearch.php

I presume I have to subscribe to some sort of GeoNames service before I can type in place names, but I haven't yet found instructions for subscribing. What do I do next?

Thanks.
I just subscribed to Google Maps. Below is my web page's source code:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<?php // Example page from Google...
// http://groups.google.com/group/Google-Maps-API/browse_thread/thread/f8ad7eabb1c7f360/ce6844d0883dae65#ce6844d0883dae65
?>
<head>
<script src="http://maps.google.com/maps?file=api&v=1&key=ABQIAAAAJVXjUUf9w3uK4JOTnUjtmhRflKT1ByLdAwE0qGKUfkqxDXuq4BSKI2ATTrGcUGJwR6LQ3Ut66tojRg" type="text/javascript"></script>
</head>
<body>
<div id="map" style="width: 500px; height: 400px"></div>
<script type="text/javascript">
//<![CDATA[

var map = new GMap(document.getElementById("map"));
map.addControl(new GSmallMapControl());
map.centerAndZoom(new GPoint(-122.1419, 37.4419), 15);

//]]>
</script>
</body>
</html>

* * * * *

I would like to add a feature that would allow visitors to navigate to a location by typing in coordinates or place names (cities, states, nations, mountains, etc.). Someone on Google's forum suggested I use JavaScript input boxes for geographic coordinates, but they suggested GeoNames for place names:

"As for placenames, personally I would recommend integrating with a
webservice like the 'Fulltext search' at http://www.geonames.org/export/ "

Can someone tell me how I would use GeoNames to add such a feature to my website? Can you point me to a tutorial or a working model? I work with PHP and MySQL on a Windows XP platform.

Thanks.
Hi,

Where do you get the feature data information from? For some points (I was looking points in the Seattle area / Space Needle etc) the lat/lng data is off by 1 or 2 blocks.

Do you plan to update the information?

Thanks,

Paul
I managed to save the same entry twice and when dleting it I'm getting this:

error while saving:
java.sql.SQLException: ERROR: duplicate key violates unique constraint "geoname_history_pkey"


these are the ones I created-.
http://www.geonames.org/maps/geonameId=6252056
http://www.geonames.org/maps/geonameId=6252057
I did not found a separate classification, but two close matches: "school" and "research institute". Should an university be classified as both or does some other classification exist?
Major cities might have well-known names in more than one language. In Finland, which is officially a bilingual country, city of Turku (Finnish) is also known as Åbo (Swedish).

I see that currently, the Swedish version is given as the authoritative name in Geonames. This seems a little strange to me - I would assume that it should be the language of the majority that is used in determining which name is used- at least in cases such as this when the minority is very small.

This can be a bit heated issue- perhaps it is best approached for example by asking which way contributes more to Geonames use/usage?

In this case, name "Turku" is of course better known in Finland and more used. In Scandinavia, I do not know, but I suspect "Åbo" might be better known. Internationally, who knows?
Above it says one can help correct the data by using the "edit" functions. I just registered and cannot see anything that would permit me to make corrections???
Hi could anybody help me with using geonames webservice in perl. im really new to this area and really could not find much help in implementing a client for REST on PERL. any help is appreciated.

Thanks in advance,
Hari
 
Profile for Anonymous -> Messages posted by Anonymous [359] Go to Page: Previous  1, 2, 3 ... 15 , 16, 17, 18 Next 
Go to:   
Powered by JForum 2.1.5 © JForum Team