We'll create fresh WordPress site with Map Navigator installed. You have 20 minutes to test the plugin after that site we'll be deleted.
This plugin imports a Map Navigation file into your WordPress blog.
The Map Navigation file defines one or more Continents, Countries, Regions, States and Cities.
The plugin creates Posts that each contain a MapPress map or mashup that provide a linked
navigation of the geography using your organization’s name, image file and icon in the Post’s
Post, Excerpt and on the Map markers. The Map Navigation hierarchy can then be added to your
themes header or provided as a link so that your organization can locate its members Posts
or Pages by Geographical area. The plugin also provides an affiliate Register script that adds
an Affiliate to your Map Navigation hierarchy along with their link and image when they join
your organization. Any post can be added to the Map Navigation hierarchy using the Map Taxonomy
tags and a Custom field used by the MapPress plugin. Exisitng MapPress maps can be linked into
the Map Navigation Hierarchy from the MapNavigator Admin Tool Interface.
This plugin is built on top of the CSV Importer plugin so it contains all of the features of
CSV Importer with the additional customized features for MapPress Google maps navigation.
Click on the Map Navigator link on your WordPress admin page, choose the
Map Definition file you would like to import and click Import. You can
build your own Map Definition file using the example file “Test Map-Navigator-USA.csv” in the examples
directory
inside the plugin’s directory or you can download one for a small fee from:
http://mapclick.org
The Map Definition file is in CSV format that consists of rows and columns. Each row in
a CSV file represents a post; each column identifies a piece of information
that comprises a post. Each Post is assigned to a level in the Map Taxonomy which provides
the Map Navigational Hierarchy as follows:
Maps Taxonomy
* Continent
* Country
* Region (optional)
* State (optional)
* City
nav_post_title
– title of the post. The name should reflect the category of the taxonomy level. For instance : ‘United States Regions’
or ‘Mountain Region States’ or ‘California Map’
nav_post_post
– body of the post. This will hold the MapPress command to create a ‘mashup’ or to display a map in this post
nav_post_excerpt
– post excerpt. This will contain the title that will appear in the Map Marker. The word ‘mapClicks’
will be replaced with your organization’s name entered on the Map Navigator Tool dialog in WordPress.
nav_post_categories
– a comma separated list of category names or ids. This will be the level associated with this post;
for instance : Maps > Continent > Country > Region
nav_post_tags
– a comma separated list of tags. Tags are used in the nav_post_post column to specify the mashup posts that will be included in the
mashup post. See the Examples directory for a sample file. Pay close attention to the tags defined in this column and the references
in the nav_post_post column.
nav_post_date
– about any English textual description of a date and time.
For example, now
, 11/16/2009 0:00
, 1999-12-31 23:55:00
, +1 week
,
next Thursday, last year
are all valid descriptions. For technical
details, consult PHP’s strtotime()
function documentation.
nav_ctax_maps – See the Examples directory for a sample file (Test Map-Navigator-USA.csv).
This column is used to specify the Post’s taxonomy tags and thus what the post will appear as in the ‘Maps’ taxonomy
(Continent, Country, Region, State or City)
‘map_address’ – holds the address of the MapPress map marker. This must be defined as a Custom field and specified in the
MapPress setup as the field used to create maps automatically from when a post is updated.
Any column that doesn’t start with nav_
is considered to be a custom field
name. The data in that column will be imported as the custom field’s value.
nav_post_title
, nav_post_post
or>
nav_post_author
– numeric user id or login name. If not specified ornav_post_slug
– post slug used in permalinks.nav_post_parent
– post parent id.Once custom taxonomies are set up in your theme’s functions.php file or
by using a 3rd party plugin, nav_ctax_(taxonomy name)
columns can be
used to assign imported data to the taxonomies.
Non-hierarchical taxonomies
The syntax for non-hierarchical taxonomies is straightforward and is essentially
the same as the nav_post_tags
syntax.
Hierarchical taxonomies
The syntax for hierarchical taxonomies is more complicated. Each hierarchical
taxonomy field is a tiny two-column CSV file, where the order of columns
matters. The first column contains the name of the parent term and the second
column contains the name of the child term. Top level terms have to be preceded
either by an empty string or a 0 (zero).
Sample examples/custom-taxonomies.csv
file included with the plugin
illustrates custom taxonomy support. To see how it works, make sure to set up
custom taxonomies from functions.inc.php
.
Make sure that the quotation marks used as text delimiters in nav_ctax_
columns are regular ASCII double quotes, not typographical quotes like “
(U+201C) and ” (U+201D).
An example file with comments is included in the examples
directory.
In short, comments can be imported along with posts by specifying columns
such as nav_comment_*_author
, nav_comment_*_content
etc, where * is
a comment ID number. This ID doesn’t go into WordPress. It is only there
to have the connection information in the CSV file.
This plugin is based upon [csv-importer][3] by Denis Kobozev (thanks !) .
This plugin uses [php-csv-parser][3] by Kazuyoshi Tlacaelel (thanks !).
Contributors:
* Israeli Rothman (Original Idea and Requirements Spec)