Skip to content

Configuration File Specification

John Deck edited this page May 23, 2016 · 11 revisions

Introduction

This file is specified in the calling URL by setting configfile=. You may put this file on any URL. Please validate your XML before putting a configfile into place and testing it. If you have any questions you may contact the administrator for assistance.

A Note on Special Characters

Since data is passed using XML documents, embedded in databases, and sometimes coming from text documents, care should be taken in using special characters. It is reccomended to use the named entity references (see, for example http://home.earthlink.net/~bobbau/platforms/specialchars/). In addition, any & symbol should be entered as a named reference, even when used in identify named references.

Opening Tag

<berkeleymapper>

Metadata Section

<metadata>
Element: legendText
Attributes:
Repeatable: No
Example: Point locations are randomized within 5kilometers
Description: Display some custom header text above the legend.

Element: abstract
Attributes: None
Repeatable: No
Example: <abstract>GIS configuration file for MVZ query interface<br>Unknown end tag for </abstract>
Description: A more in-depth description of what the purpose of this application does for the group.

Element: disclaimer
Attributes:
Repeatable: No
Example: <disclaimer><![CDATA[Data records provided by ORNIS may be used by individual researchers or research groups, but they may not be repackaged, resold, or redistributed in any form without the express written consent of the original institution where those records are held.<p>Citations: ....(etc)]]><br>Unknown end tag for </disclaimer>
Description: This is a user-supplied disclaimer to display when users are downloading data. Make sure you use the CDATA syntax if you include HTML tags here.

Element: logo
Attributes: img,url
Repeatable: Yes
Example: <logo img="http://moorea.berkeley.edu/sites/default/files/u4/gumpzen2_logo.gif" url="http://moorea.berkeley.edu/"/>
Description: These tags will display logos and a link in the legend.

</metadata>

Record LinkBack

There are two methods for record linkbacks in BerkeleyMapper 2.0.

1. Fully formatted from the calling application with the link placed in the tab delimited text as its own field (or part of another field, such as):

<a href="someurl">12345</a>

2. Specified in the linkback URL syntax with:

method: how to linkback
linkurl: url to use
text: text to display inside href tag
fieldname: name of field
key1: Concept Alias
value1: Concept Name
<recordlinkback>
<linkback method="root" linkurl="http://biocode.berkeley.edu/cgi/biocode_query?one=T" text="View Details" fieldname="Link Back" key1="bnhm_id" value1="char120_5"/>
</recordlinkback>

Matching tab-delimited fields to Map schema

<concepts xmlns:darwin="http://digir.net/schema/conceptual/darwin/2003/1.0">

Element:
Attributes: viewlist: 0 means do not show this field in query results. 1 means to show it.
colorlist: 0 means do not add this as an option under 'Color By'. 1 means add this as an option to 'Color By', so the user can display unique colors for each unique value in this field.
datatype: name of concept in mapfile schema or specification of new datatype.
alias: Your name for this field which will also appear on column headings of query results.
order: any number to designate what order this should be displayed in results table.
Repeatable: No
Example: See following file:
Description: This section defines names of server-side-fields, aliases, and whether we want to view it. If there are concepts outside the map schema, then they go into sequentially numbered, typed fields (char120:1-8,char255:1-8,longtext:1-4,int:1-4,float:1-4). The order of the fields MUST match the order of the fields in the tab delimited file being passed to this application.

<concepts>
<concept viewlist="1" colorlist="0" datatype="darwin:catalognumbertext" alias="CatalogNumber" order="1" />
<concept viewlist="1" colorlist="1" datatype="darwin:scientificname" alias="ScientificName" order="2" />
<concept viewlist="0" colorlist="1" datatype="darwin:country" alias="Country" order="9" />
<concept viewlist="0" colorlist="0" datatype="darwin:stateprovince" alias="StateProvince" order="3" />
<concept viewlist="1" colorlist="1" datatype="darwin:county" alias="County" order="4" />
<concept viewlist="0" colorlist="0" datatype="char120:1" alias="id_modifier" order="11" />
<concept viewlist="0" colorlist="0" datatype="char120:2" alias="Coll_Object_id" order="12" />
<concept viewlist="0" colorlist="0" datatype="char120:3" alias="type_status" order="5" />
<concept viewlist="0" colorlist="1" datatype="char120:4" alias="class" order="5" />
<concept viewlist="0" colorlist="1" datatype="char120:5" alias="order" order="50" />
<concept viewlist="0" colorlist="1" datatype="char120:6" alias="family" order="10" />
<concept viewlist="0" colorlist="0" datatype="char120:7" alias="tissues" order="19" />
<concept viewlist="0" colorlist="0" datatype="char120:8" alias="sex_cde" order="20" />
<concept viewlist="1" colorlist="0" datatype="darwin:collectioncode" alias="CollectionCode" order="1" />
<concept viewlist="0" colorlist="0" datatype="darwin:decimallatitude" alias="DecimalLatitude" order="20" />
<concept viewlist="0" colorlist="0" datatype="darwin:decimallongitude" alias="DecimalLongitude" order="21" />
<concept viewlist="0" colorlist="0" datatype="darwin:coordinateuncertaintyinmeters" alias="CoordinateUncertaintyInMeters" order="22" />
<concept viewlist="1" colorlist="0" datatype="darwin:horizontaldatum" alias="HorizontalDatum" order="23" />
</concepts>

GIS Data Section (KML)

The following is an example of structuring references to KML layers that you wish to be included as background layers:
<gisdata>
<layer title="IUCN Bufo bufo Distribution" legend="1" active="1" url="http://www.iucnredlist.org/apps/redlist/details/54596/0"><![CDATA[http://amphibiaweb.org/cgi/amphib_ws_shapefile?genus=Bufo&species=canorus]]></layer>
<layer title="NE Status" legend="1" active="1" url="http://detailsaboutthisresource.com/"><![CDATA[http://kml-samples.googlecode.com/svn/trunk/kml/misc/thematic1/states.kml]]></layer>
</gisdata>

Closing Tag

</berkeleymapper>