No, I don't have the script to generate the cute html... :)<br><br>By now, we will start with the capitals and some other important cities (30-35 cities), but your script will be necessary in the future, when we raise the number of the cities.<br>
<br>On Tue, Dec 1, 2009 at 1:03 PM, Ævar Arnfjörð Bjarmason <span dir="ltr"><<a href="mailto:avarab@gmail.com">avarab@gmail.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div><div></div><div class="h5">On Tue, Dec 1, 2009 at 17:06, Matt Amos <<a href="mailto:zerebubuth@gmail.com">zerebubuth@gmail.com</a>> wrote:<br>
> On Tue, Dec 1, 2009 at 4:04 PM, Vitor George <<a href="mailto:vitor.george@gmail.com">vitor.george@gmail.com</a>> wrote:<br>
>> I want to start a project in Brazil that is similar to the Tiger Fixup 250<br>
>> Cities [1], and I looking forward to build a script that generates a<br>
>> distance grid, like this:<br>
>><br>
>> <a href="http://matt.sandbox.cloudmade.com/usa-routes.html" target="_blank">http://matt.sandbox.cloudmade.com/usa-routes.html</a><br>
>><br>
>> I've tried to contact the authors via wiki, but I was unsuccessful, so I<br>
>> want to develop it by myself. I'm not a professional programmer, but I have<br>
>> some experience in java. Is the LibOSM the easiest way tool to implement it?<br>
><br>
> sorry you missed us on the wiki. i have to say, i don't really check<br>
> the discussion pages like a good wikian should :-(<br>
><br>
> the script is very simple, and uses cloudmade's ruby API [1] to get<br>
> the routes. you'll need to sign up for a cloudmade API key, if you<br>
> haven't already. the script i've attached will output CSV on stdout,<br>
> but i usually put them in a database for easy access.<br>
><br>
> run it like "ruby routes.rb <conf file>". i've attached an example<br>
> configuration file, which is just a yaml map of string to lat/lon<br>
> array.<br>
><br>
> i look forward to seeing brazil's 250 cities :-)<br>
<br>
</div></div>I made a hacky script to generate .yml from XAPI output (attached):<br>
<br>
wget '<a href="http://www.informationfreeway.org/api/0.6/node[place=city%7Ctown%7Cvillage%7Chamlet][bbox=-25.74085,62.84553,-12.41708,67.50085]" target="_blank">http://www.informationfreeway.org/api/0.6/node[place=city|town|village|hamlet][bbox=-25.74085,62.84553,-12.41708,67.50085]</a>'<br>

-O iceland-places.osm<br>
perl -CI <a href="http://place2yaml.pl" target="_blank">place2yaml.pl</a> < place.osm  > place.yml<br>
<br>
But I just get internal server errors from the CM API:<br>
<br>
$ ruby routes.rb place.yml<br>
[Tue Dec 01 18:59:57 +0000 2009] HTTP error: Couldn't read data. HTTP<br>
status: #<Net::HTTPInternalServerError:0xb769348c>, retrying...<br>
<br>
Anyway do you have a script to generate that cute HTML matrix? And how<br>
can I link to a route on CM's website. I have to supply lat/lon/zoom<br>
it seems and not just starting/ending lat/lon (at least the URLs I've<br>
seen are all like that).<br>
</blockquote></div><br>