Hi Nick,

That did the trick, thanks, my bad for not reading the docs properly I suppose.

By the way I'd like to take you up on your offer of sharing the Freemap code, 
both to study how someone has made lots of interesting changes to Mapnik and 
because I'd like to do an overlay with the photographs in OpenLayers. If you 
have it somewhere for me to download, or could email it to this address, that 
would be great.

Kind regards,
Tom

-----Original Message-----
From: [EMAIL PROTECTED] on behalf of Nick Whitelegg
Sent: Sat 01/03/2008 18:27
To: [email protected]
Cc: [EMAIL PROTECTED]
Subject: Re: [Mapnik-users] Customising footway rule in osm.xml wrecks allthe 
ways
 

> Hello,
>
> I'm making a customised map based upon OpenStreetMap's toolchain and
> osm.xml. I want to, amongst other things, distinguish between official and
> desired footways. I've used the tag "status=desired" to denote the latter.
>
> When I change the footway rules to reflect this I get really odd results,
> look at the ways in this: http://www.treestation.org/problem.png
>
> This works fine:


Hello Tom,

Do you specify the 'status' column in the appropriate layer in the XML file?
e.g

<Layer name="roadstext" status="on" srs="+proj=merc +datum=WGS84 +k=1.0 +units
=m +over +no_defs">
     <StyleName>roads-text</StyleName>
     <Datasource>
      <Parameter name="type">postgis</Parameter>
      <Parameter name="host">/var/run/postgresql</Parameter>
      <Parameter name="port">5432</Parameter>
      <Parameter name="user">www-data</Parameter>
      <Parameter name="dbname">freemap</Parameter>
      <Parameter name="table">(select 
way,highway,landuse,"natural",man_made,waterway,tourism,amenity,place,name,*status*,char_length(name)
 
as length from planet_osm_lin
e where waterway IS NULL and leisure IS NULL and landuse IS NULL) as 
roads</Para
meter>
    </Datasource>
   </Layer>


Also, you will need to modify output-pgsql.c to include the 'status' tag in 
the postgis database, if you haven't done so already, e.g.:

static struct {
    const char *name;
    const char *type;
    const int polygon;
} exportTags[] = {
    {"aeroway",  "text", 1},
    {"amenity",  "text", 1},
    {"bicycle",  "text", 0},
    {"bridge",   "text", 0},
    {"boundary", "text", 1},
    {"status","text",0 },
    ... etc....

Nick

_______________________________________________
Mapnik-users mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/mapnik-users

_______________________________________________
Mapnik-users mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/mapnik-users

Reply via email to