How to create a museum website with WordPress?

In this post I am going to tell you how I build a museum (photographic archive) Website with WordPress.

First of all, in a clean WordPress Installation I installed the following plugins:

The photographic archive has its internal archive in FileMaker files. They have a File Maker file per collection. File Maker files can be exported as XML.

XML files has the next structure:

    <?xml version="1.0" encoding="UTF-8" ?>
    <FMPXMLRESULT xmlns="http://www.filemaker.com/fmpxmlresult">
        <ERRORCODE>0</ERRORCODE>
        <PRODUCT BUILD="01-25-2011" NAME="FileMaker" VERSION="ProAdvanced 11.0v3"/>
        <DATABASE DATEFORMAT="D/m/yyyy" LAYOUT="" NAME="FICHERO TIMOTEO.fp7" RECORDS="151" TIMEFORMAT="k:mm:ss "/>
        <METADATA>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Clasificación1" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Clasificación2" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Color" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Descriptores" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Estado" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Fecha" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Fondo" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Formato" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Información complementaria" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Nota a la fecha" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Nota al autor" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Registro1" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Soporte" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Tipo" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Título" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="TRA" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Tratamiento" TYPE="TEXT"/>
        </METADATA>
        <RESULTSET FOUND="151">
    <ROW MODID="38" RECORDID="1">
        <COL><DATA>Guadalajara </DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>B/N</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>bueno</DATA></COL>
        <COL><DATA>20-01-1949</DATA></COL>
        <COL><DATA>FONDO TIMOTEO</DATA></COL>
        <COL><DATA>17.X 11</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>TIM-0001</DATA></COL>
        <COL><DATA>PAPEL</DATA></COL>
        <COL><DATA>POSITIVO </DATA></COL>
        <COL><DATA>Cumplidoras del Servicio Social en clase de corte y confección</DATA></COL>
        <COL><DATA></DATA></COL>
    <COL><DATA></DATA></COL>
   </ROW>
    <ROW MODID="31" RECORDID="2">
        <COL><DATA>Guadalajara </DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>B/N</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>bueno</DATA></COL>
        <COL><DATA>09-01-1948</DATA></COL>
    <COL><DATA>FONDO TIMOTEO</DATA></COL>
        <COL><DATA>17.X 11</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>TIM-0002</DATA></COL>
        <COL><DATA>PAPEL</DATA></COL>
        <COL><DATA>POSITIVO </DATA></COL>
        <COL><DATA>Exposición de canastillas confeccionadas por la SECCIÓN FEMENINA</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
    </ROW>
    <ROW MODID="37" RECORDID="3">
            <COL><DATA>Guadalajara </DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>B/N</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>bueno</DATA></COL>
        <COL><DATA>13-10-1948</DATA></COL>
        <COL><DATA>FONDO TIMOTEO</DATA></COL>
        <COL><DATA>17.X 11</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>TIM-0003</DATA></COL>
        <COL><DATA>PAPEL</DATA></COL>
        <COL><DATA>POSITIVO </DATA></COL>
        <COL><DATA>Clase de organización de S.F. explicada por la directora local a las F.A. que han pasado a la S.F.    </DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
    </ROW>
    <ROW MODID="35" RECORDID="4">
            <COL><DATA>Guadalajara </DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>B/N</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>bueno</DATA></COL>
        <COL><DATA>17-05-1953</DATA></COL>
        <COL><DATA>FONDO TIMOTEO</DATA></COL>
        <COL><DATA>17.X 11</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>TIM-0004</DATA></COL>
        <COL><DATA>PAPEL</DATA></COL>
        <COL><DATA>POSITIVO </DATA></COL>
        <COL><DATA>Campeonato provincial de balonvolea</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
    </ROW>
    <ROW MODID="35" RECORDID="5">
            <COL><DATA>Guadalajara </DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>B/N</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>bueno</DATA></COL>
        <COL><DATA>09-08-1948</DATA></COL>
        <COL><DATA>FONDO TIMOTEO</DATA></COL>
        <COL><DATA>17.X 11</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
         <COL><DATA></DATA></COL>
        <COL><DATA>TIM-0005</DATA></COL>
        <COL><DATA>PAPEL</DATA></COL>
        <COL><DATA>POSITIVO </DATA></COL>
        <COL><DATA>Exposición de labores realizadas por las flechas en el taller de formación </DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
    </ROW>
    <ROW MODID="34" RECORDID="6">
            <COL><DATA>Guadalajara </DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>B/N</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>bueno</DATA></COL>
        <COL><DATA>04-02-1949</DATA></COL>
        <COL><DATA>FONDO TIMOTEO</DATA></COL>
        <COL><DATA>17.X 11</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>TIM-0006</DATA></COL>
        <COL><DATA>PAPEL</DATA></COL>
        <COL><DATA>POSITIVO </DATA></COL>
        <COL><DATA>Clase de cultura general dada por la regidora de las juventudes a las flechas</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
    </ROW>
    <ROW MODID="34" RECORDID="7">
            <COL><DATA>Guadalajara </DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>B/N</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>bueno</DATA></COL>
        <COL><DATA>18-07-1953</DATA></COL>
        <COL><DATA>FONDO TIMOTEO</DATA></COL>
        <COL><DATA>17.X 11</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA>TIM-0007</DATA></COL>
        <COL><DATA>PAPEL</DATA></COL>
        <COL><DATA>POSITIVO </DATA></COL>
        <COL><DATA>3º campeonato provincial de gimnasia</DATA></COL>
        <COL><DATA></DATA></COL>
        <COL><DATA></DATA></COL>
    </ROW>
    ...
    ..
    .
    </RESULTSET></FMPXMLRESULT>

I have remove some data from the previous example due to privacy reasons.

Import the images

Each XML ROW in the previous example represents an image in the photographic archive. The image file’s name partially matches the DATA content in one column. That it is to say, for the first ROW displayed in the previous example, the image file’s name is TIM-0001.jpg. The text string TIM-0001 appears in the XML as mentioned.

Names are unique collections and entries of the same collection.

Once you have a name policy which ensures uniqueness and that you will be able to reference the images based on the XML content upload every image to WordPress. In my case it was a set of 15000 images. Because of that a cup of coffee and a good internet connection are a must.

Setup custom post types

In order to store the photographic archive entries within WordPress we are going to create a custom post type called “foto” (photo in Spanish). With Custom Post Types plugin is pretty easy. Next I show you some screenshots about how to do it:

Custom Post Type

This will be the custom post type details after clicking edit:

Add_New_‹_Cefihgu_—_WordPress

Setup the taxonomies

The photographic archive contains several picture collections. Each collection with its FileMaker file and name. Some collections even have different fields. To accommodate several collections I created a taxonomy as shown below.

Dar de alta una taxonomía

Next I show the taxonomy detail after clicking the edit button. This taxonomy is associated to the custom post type “Fotos” which we created before.

Detalle Taxonomía

Setup Custom Fields.

The metadata part of the previous XML, which I post again below, describes the data structure  of the collection.

        <METADATA>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Clasificación1" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Clasificación2" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Color" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Descriptores" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Estado" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Fecha" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Fondo" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Formato" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Información complementaria" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Nota a la fecha" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Nota al autor" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Registro1" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Soporte" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Tipo" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Título" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="TRA" TYPE="TEXT"/>
            <FIELD EMPTYOK="YES" MAXREPEAT="1" NAME="Tratamiento" TYPE="TEXT"/>
        </METADATA>

With the previous XML fragment in mind and the help of Custom Fields Plugin I created a field group to store the information stored in FileMaker. I created some additional fields such a search field called “Campo Búsqueda” to ease the construction of a search engine as well as field called Picture file to store the image’s URL.

This is the group field which I created:

Grupo de campos personalizado WordPress

 

Import the XML file with WP All Import Plugin

Thanks to all the previous work, we are ready to import the File Maker files in WordPress. In order to do that we are going to use the WP All Import Plugin. We import the entries in XML to the custom post type we have just created.  When we start an import with WP All import the XML is previewed. We need to tell the plugin which XML Tag we need to import. In our case ROW.

In the plugin import template page, we select the unique column we previously used for the image name as the name of the custom post type entry’s title. WP All Import has nice drag a drop capabilities. That it is to say, just use the XML preview in the right side and drag the data to the field you choose in the left. The Import Template I used is shown next:

WP All Import Template

Next I show the import options I used. I have highlighted the options selected. If you look at the next screenshot you will see that I’ve used the custom post type “Fotografías”, the taxonomy “Colecciones” and the custom field group “Foto”. Moreover, you can see how the field image is built using the media URL structure of WordPress and the XML Field which contains partially the image file’s name.

ImportOptions

 

Once, we have everything in place, we just need to wait for WP All Impor to perform the import. At the end of the import, we will have a custom post type per XML ROW element.

Next I show you an example of a custom post type “Fotografías” entries:

ficha

I still have to write another post to explain how to use all this information in the visible part of WordPress.

Leave a Reply

Your email address will not be published. Required fields are marked *