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: geotree  XML
Profile for geotree -> Messages posted by geotree [138] Go to Page: Previous  1, 2, 3, 4, 5, 6, 7
Author Message
Just add a missing ; to the first line.
Use lat= and long= parameters
Code:
 $url = "http://ws.geonames.org/findNearbyPlaceNameJSON?lat=47.3&lng=9"
 $json = file_get_contents($url);
 $data = json_decode($json, true);
 foreach ($data["geonames"] as $key => $val) {
 	echo $val["name"]." ".$val["countryName"]." ".$val["countryCode"]."<br />";
 }
Example using PHP 5
Code:
 $url  = "http://ws.geonames.org/hierarchyJSON?geonameId=6447142";
 $json = file_get_contents($url);
 $data = json_decode($json, true);
 var_dump($data);


Note : json_decode() does not exist using PHP4

PhpGedView module calls geoNames searchJSON webservice
with fclass=P (white pins) or fclass=A (red pins) depending on place hierarchy level.
(see : modules/googlemap/places_edit.php in your PhpGedView installation)

http://ws.geonames.org/searchJSON?name=Dzierzoniow&fclass=A&style=FULL&formatted=true
returns an empty array

http://ws.geonames.org/searchJSON?name=Dzierzoniow&fclass=P&style=FULL&formatted=true
returns a city from Poland

This is *not* a GeoNames problem.
Please ask PhpGedView module developper.
Sounds like a PhpGedView bug or misconfiguration.

Please ask for help on PhpGedView forum :
http://sourceforge.net/forum/forum.php?forum_id=185166

or post a bug report :
http://sourceforge.net/tracker/?group_id=55456&atid=477079
"book with laterooms" link is always in english.
http://www.laterooms.com/en/...

As Laterooms.com site works in en/de/fr/it/sp,
I suggest to use browser's default lang when possible :
http://www.laterooms.com/de/...
http://www.laterooms.com/fr/...
http://www.laterooms.com/it/...
http://www.laterooms.com/sp/...

Christophe
Zoom needs to be fixed also for :
> largest cities
> highest mountains
> capitals

on homepage :
http://www.geonames.org/

Christophe
Same for French overseas territories :
as they have a country code, I think they should be stored as A.PCLIX (section of independent political entity) and linked to appropriate continent :

Guadeloupe (GP) and Martinique (MQ) to North America

Guyane (GF) to South America

Réunion (RE) and Mayotte (YT) to Africa

Saint-Pierre et Miquelon (PM)
Wallis et Futuna (WF)
Polynésie Francaise (PF)
Nouvelle Calédonie (NC) to Oceania
To add Alsatian (Alsacien, Elsaessisch) alternate names to french departements 67 & 68, I have used 'gsw' lang code.

http://www.geonames.org/3034720/departement-du-bas-rhin.html
http://www.geonames.org/3013663/departement-du-haut-rhin.html

Not sure this is the good one, but found nothing better...

Christophe




Ideas :

What about inserting "siblings" to the top of the list ?
Would this decrease performance ?

You may also check only current class in the left frame
(today all boxes have default status : checked)

Christophe
Marc,

hierarchy returns long names :
http://ws.geonames.org/hierarchy?lang=fr&geonameId=6444096
[Republic of France]

children returns short names :
http://ws.geonames.org/children?lang=fr&geonameId=6255148
[France]

What is the rule ?

And hierarchy does not show upper level 'Earth'.
May you add it ?

Thanks

Christophe
Marc,
may you also change default zoom for CONT :
http://www.geonames.org/6255148/europe.html

Thanks

Christophe
children webservice is great :
http://www.geonames.org/export/place-hierarchy.html#children

More similar webservices would be useful :


1/ siblings :
siblings(node) = children(parent(node)) - node;


2/ neighbours :
all nodes from same level with a common border

For France country, this would return :
Spain, Andorra, Monaco, Italy, Switzerland, Germany, Luxembourg, Belgium.
(Should also work for ADM1/2/3/4)


Christophe
Let's open an ADM1 perma link :
http://www.geonames.org/3027257/
then click on 'refresh' link to display all features in area.

The first 50 objects listed are 50 PPL from Germany

What I suggest to be more user-friendly :
when there is more than 50 objects, to show in this order :
1/ objects from same code (here ADM1)
2/ objects from same class (here A)
3/ others

Christophe


Thanks Marc for this great addition.

Parameter zoom does not work any more. Is it normal ?
http://www.geonames.org/6455179/index.html?zoom=18

And what about adding a kind of polygon feature similar to this :
http://www.mapygon.com/france/

Christophe
Today, all perma links have same default googlemap zoom (=14).

Not very intuitive for a country :
http://www.geonames.org/3017382/
or ADM1 :
http://www.geonames.org/3030293/

User can already add a zoom parameter :
http://www.geonames.org/3030293/index.html?zoom=6

However, it would be nice to have a default zoom depending on place level. Let's say :

default zoom=4 (Country)
http://www.geonames.org/3017382/index.html?zoom=4

default zoom=6 (ADM1)
http://www.geonames.org/3030293/index.html?zoom=6

default zoom=8 (ADM2)
http://www.geonames.org/2991879/index.html?zoom=8

default zoom=10 (ADM3)
http://www.geonames.org/2997576/index.html?zoom=10

default zoom=12 (ADM4)
http://www.geonames.org/6455179/index.html?zoom=12

Thanks

Christophe
I have started french translation :

Bundesland => Etat
Regierungsbezirk => District
Landkreis => Arrondissement
Stadtkreis => Ville-arrondissement
Gemeinde => Municipalité

Any comments ?
During French Revolution, years 1793-1794, some french city names were changed (and most of them restored a few months later !).

ex: "St Gildas de Rhuys" was called "Abélard"

Read more : http://www.cyberindre.org/jahia/webdav/site/cyberindre/shared/images/archives/NOMS_REVOLUTIONNAIRES_w_800.jpg

Many genealogists would appreciate this addition to geonames.

I suggest to create a new alternate name code "fr-revol" or "fr-1793" for "French Revolution" (similar to "post" for postcode)

After that, I will try to collect most of those names to create a batch.

Thanks

Christophe
 
Profile for geotree -> Messages posted by geotree [138] Go to Page: Previous  1, 2, 3, 4, 5, 6, 7
Go to:   
Powered by JForum 2.1.5 © JForum Team