<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://ark.lparchaeology.com/wiki/index.php?feed=atom&amp;namespace=0&amp;title=Special%3ANewPages</id>
		<title>ARK - New pages [en]</title>
		<link rel="self" type="application/atom+xml" href="https://ark.lparchaeology.com/wiki/index.php?feed=atom&amp;namespace=0&amp;title=Special%3ANewPages"/>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/Special:NewPages"/>
		<updated>2026-06-09T12:53:05Z</updated>
		<subtitle>From ARK</subtitle>
		<generator>MediaWiki 1.27.1</generator>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/Brother_A3</id>
		<title>Brother A3</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/Brother_A3"/>
				<updated>2018-08-22T14:34:26Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Scanning Permatrace */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Brother A3 Printer / Scanner =&lt;br /&gt;
&lt;br /&gt;
LP owns a number of Brother A3 Printer / Scanners, primarily for scanning Permatrace, but also for printing large A3 plans and drawings, or colour documents where an office does not have a colour laser printer.&lt;br /&gt;
&lt;br /&gt;
NOTE: These printers are Ink Jet printers, which means the inks are not archivally stable and so cannot be used for printing Recording Sheets and any other documents to be deposited as part of the site archive. You must use a laser printer for these purposes.&lt;br /&gt;
&lt;br /&gt;
== Setup ==&lt;br /&gt;
&lt;br /&gt;
The printers should be setup to connect via the office network, although sometimes they may be directly connected via USB to a machine. If you need any assistance with this please contact the Sysadmins.&lt;br /&gt;
&lt;br /&gt;
Apple macOS will automatically detect the printer and scanner once they are connected to the network and they can be immediately used from the macOS print dialog or Image Capture app (under the Shared section, click on more to display). They will usually be listed with a model number like &amp;#039;&amp;#039;Brother MFC J6930DW&amp;#039;&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
If you need to use some advanced features, or do large volumes of Permatrace scanning, then you will need to install the official Brother drivers and app. The drivers can be found in the Library/Software/Printer Scanner Drivers/Brother A3/ folder, or downloaded from http://support.brother.com/g/b/countrytop.aspx?c=gb&amp;amp;lang=en. If you need Admin rights to install the drivers, please talk to your managing partner or the Sysadmins.&lt;br /&gt;
&lt;br /&gt;
== Scanning Permatrace ==&lt;br /&gt;
&lt;br /&gt;
You can use the standard Apple Image Capture app to scan permatrace using the Automatic Document Feeder (ADF), but this app will only allow you to do so at A3 paper size. While the image resolution will be correct you will have to manually crop the image to permatrace size afterwards.&lt;br /&gt;
&lt;br /&gt;
The Brother Control Centre app enables you to scan custom page sizes using the ADF. You can find the app in the Finder under Applications / Brother / Control Centre. If it is not installed, see the Setup section for installation instructions.&lt;br /&gt;
&lt;br /&gt;
Run the Control Centre, choose the printer &amp;#039;&amp;#039;Model&amp;#039;&amp;#039; you want to use, and click on the &amp;#039;&amp;#039;Custom Scan&amp;#039;&amp;#039; tab to see if the &amp;#039;&amp;#039;Permatrace&amp;#039;&amp;#039; option has already been added:&lt;br /&gt;
&lt;br /&gt;
[[File:Brother_scan_custom.png]]&lt;br /&gt;
&lt;br /&gt;
Load the scanner ADF with up to 30 sheets of permatrace. Click on the &amp;#039;&amp;#039;Permatrace&amp;#039;&amp;#039; button to get the &amp;#039;&amp;#039;Save to File&amp;#039;&amp;#039; dialog:&lt;br /&gt;
&lt;br /&gt;
[[File:Brother_scan_file.png]]&lt;br /&gt;
&lt;br /&gt;
Change the file name prefix to the LP standard format for the site and drawing type you are scanning. This will usually be something like cxt_STE18_ for context drawings for site STE18 (see the LP Data Standards for further guidance). &lt;br /&gt;
&lt;br /&gt;
Use the &amp;#039;&amp;#039;Browse&amp;#039;&amp;#039; button to select the folder to save the scans to. We recommend saving to a local folder and not the server as it will be faster and easier to manage the files afterwards.&lt;br /&gt;
&lt;br /&gt;
Ensure all other settings are as displayed above.&lt;br /&gt;
&lt;br /&gt;
Click &amp;#039;&amp;#039;Start Scanning&amp;#039;&amp;#039; button which will show the &amp;#039;&amp;#039;Brother TWAIN&amp;#039;&amp;#039; dialog to set the image scan details. This will default to the last used values, you should not change these once set the first time:&lt;br /&gt;
&lt;br /&gt;
[[File:Brother_scan_settings.png]]&lt;br /&gt;
&lt;br /&gt;
Once you click start the permatrace will start feeding through the ADF and saving to your local folder. You need to watch the ADF carefully as dirty permatrace misfeeds easily. If it does misfeed you have to unload all the permatrace, close the scan dialog, reload the permatrace, and start the scan again. If the ADF clicks on a misfeed you have enough time &lt;br /&gt;
&lt;br /&gt;
To create the Permatrace option  click on the Configuration button and choose the Custom1 option to edit:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This will show a Config dialog which needs to be set up as follows:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Click OK to save and you&amp;#039;ll have the Permatrace option. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You&amp;#039;ll only need to fill these in the first time, afterwards it will remember them once you click Start.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/View</id>
		<title>ARK2/View</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/View"/>
				<updated>2018-03-19T15:47:58Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Tables */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= View =&lt;br /&gt;
&lt;br /&gt;
ARK2 provides a table driven configuration of Views on Data Schemas and Items, such as Pages, Forms and Tables. View Elements can be nested to build up complex layouts.&lt;br /&gt;
&lt;br /&gt;
== View Elements ==&lt;br /&gt;
&lt;br /&gt;
View elements are either Basic Elements, or Compound Elements made up of other Basic and/or Compound Elements.&lt;br /&gt;
&lt;br /&gt;
Basic Elements&lt;br /&gt;
* Widget - An object embedded in a page, e.g. a form element, text element, button, etc&lt;br /&gt;
* Field - A widget that is linked to a specific Attribute in a Schema and inherits its behaviour from that Attribute, e.g. an Actor&amp;#039;s name is a text form field with defined size constraints&lt;br /&gt;
* Nav - A widget that is used for site navigation, e.g. a clickable link with or without an icon&lt;br /&gt;
&lt;br /&gt;
Compound Elements&lt;br /&gt;
* Page -  A layout of other elements in a page, with standard elements such as header, sidebar, footer, and content&lt;br /&gt;
* Grid - A layout of other elements in rows and columns, both basic and compound&lt;br /&gt;
* Form - An HTML5 Form&lt;br /&gt;
* Table - An HTML5 Table&lt;br /&gt;
* Tree - Currently not implemented, a layout of other elements in a hierarchical tree, e.g. a navigation menu&lt;br /&gt;
&lt;br /&gt;
== View Tables / Classes ==&lt;br /&gt;
&lt;br /&gt;
 ark_view_cell - ARK\View\Cell&lt;br /&gt;
 ark_view_element - ARK\View\Element&lt;br /&gt;
 ark_view_field - ARK\View\Field&lt;br /&gt;
 ark_view_form - ARK\View\Form&lt;br /&gt;
 ark_view_group - ARK\View\Grid&lt;br /&gt;
 ark_view_nav - ARK\View\Nav&lt;br /&gt;
 ark_view_page - ARK\View\Page&lt;br /&gt;
 ark_view_table - ARK\View\Table&lt;br /&gt;
 ark_view_tree - ARK\View\Tree&lt;br /&gt;
 ark_view_type - ARK\View\Type&lt;br /&gt;
 ark_view_widget - ARK\View\Widget&lt;br /&gt;
&lt;br /&gt;
== Tables ==&lt;br /&gt;
&lt;br /&gt;
Tables are a Compound Element defined by the ARK\View\Table class, and can only embed ARK\View\Field or ARK\View\Widget Basic Elements. They cannot embed other Compound Elements. When a Table embeds Field Elements, then all Fields must belong to a single Schema, i.e. a Table embeds a Schema, with each row embedding an Item that is an instance of that Schema.&lt;br /&gt;
&lt;br /&gt;
The Table Element is defined in the ark_view_table table, which is mapped by Doctrine to the ARK\View\Table class. The definition seeks to abstract the HTML5 Table definition and the currently chosen JavaScript Table widget in a generic way to avoid implementation specifics. The Twig or JavaScript frontends are expected to translate this generic definition into the specific implementation being used.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
|+ Table Definition&lt;br /&gt;
&lt;br /&gt;
! Database Field&lt;br /&gt;
! Class Method&lt;br /&gt;
! Datatype&lt;br /&gt;
! Description&lt;br /&gt;
&lt;br /&gt;
|-&lt;br /&gt;
| element&lt;br /&gt;
| id()&lt;br /&gt;
| string&lt;br /&gt;
| The unique ID of the Table element&lt;br /&gt;
|-&lt;br /&gt;
| name&lt;br /&gt;
| name()&lt;br /&gt;
| string&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
|&lt;br /&gt;
| type()&lt;br /&gt;
| ARK\View\Type&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
| mode&lt;br /&gt;
| mode()&lt;br /&gt;
| boolean&lt;br /&gt;
|&lt;br /&gt;
|-&lt;br /&gt;
| caption&lt;br /&gt;
| showCaption()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether to show the HTML5 table caption element&lt;br /&gt;
|-&lt;br /&gt;
| header&lt;br /&gt;
| showHeader()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether to show the HTML5 table header element&lt;br /&gt;
|-&lt;br /&gt;
| footer&lt;br /&gt;
| showFooter()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether to show the HTML5 table footer element&lt;br /&gt;
|-&lt;br /&gt;
| sortable&lt;br /&gt;
| isSortable()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether the table rows can be sorted&lt;br /&gt;
|-&lt;br /&gt;
| searchable&lt;br /&gt;
| isSearchable()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether the table data is searchable&lt;br /&gt;
|-&lt;br /&gt;
| list&lt;br /&gt;
| enableListView()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether the table list view is enabled&lt;br /&gt;
|-&lt;br /&gt;
| detail&lt;br /&gt;
| enableDetailView()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether the table detail view is enabled&lt;br /&gt;
|-&lt;br /&gt;
| expand&lt;br /&gt;
| enableExpandListView()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether the table expand view is enabled (only if list and detail views are enabled)&lt;br /&gt;
|-&lt;br /&gt;
| card&lt;br /&gt;
| enableCardView()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether the table card view is enabled&lt;br /&gt;
|-&lt;br /&gt;
| thumb&lt;br /&gt;
| enableThumbnailView()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether the table thumbnail view is enabled&lt;br /&gt;
|-&lt;br /&gt;
| view&lt;br /&gt;
| defaultView()&lt;br /&gt;
| string&lt;br /&gt;
| Which table view is the default view, choice of list, card, or thumb&lt;br /&gt;
|-&lt;br /&gt;
| image&lt;br /&gt;
| image()&lt;br /&gt;
| string&lt;br /&gt;
| The data field to use for images, i.e. thumbnails&lt;br /&gt;
|-&lt;br /&gt;
| export&lt;br /&gt;
| canExportData()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether the table data can be exported&lt;br /&gt;
|-&lt;br /&gt;
| columns&lt;br /&gt;
| canChooseColumns()&lt;br /&gt;
| boolean&lt;br /&gt;
| Whether the table columns displayed can be selected&lt;br /&gt;
|-&lt;br /&gt;
| pagination&lt;br /&gt;
| pagination(), pageSize()&lt;br /&gt;
| boolean, integer&lt;br /&gt;
| The number of rows per page, defaults to 10&lt;br /&gt;
|-&lt;br /&gt;
| selection&lt;br /&gt;
| selection()&lt;br /&gt;
| string&lt;br /&gt;
| Whether data rows can be selected&lt;br /&gt;
|-&lt;br /&gt;
| keyword&lt;br /&gt;
| keyword()&lt;br /&gt;
| string, ARK\Translation\Keyword&lt;br /&gt;
| The translation keyword used for the table&lt;br /&gt;
|-&lt;br /&gt;
| classes&lt;br /&gt;
| classes()&lt;br /&gt;
| string&lt;br /&gt;
| Any extra CSS classes to add to the table&lt;br /&gt;
|-&lt;br /&gt;
| template&lt;br /&gt;
| template()&lt;br /&gt;
| string&lt;br /&gt;
| The TWIG template to use instead of the default table template&lt;br /&gt;
|-&lt;br /&gt;
| url&lt;br /&gt;
| dataUrl()&lt;br /&gt;
| string&lt;br /&gt;
| The server-side pagination URL&lt;br /&gt;
|-&lt;br /&gt;
&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARKmatrix</id>
		<title>ARKmatrix</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARKmatrix"/>
				<updated>2018-03-17T14:40:37Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Harris Matrix Software */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Harris Matrix Software =&lt;br /&gt;
&lt;br /&gt;
This page summarises L - P : Archaeology&amp;#039;s ongoing work on Harris Matrix software.&lt;br /&gt;
&lt;br /&gt;
* Our ARK Matrix software: https://gitlab.com/arklab/ArkMatrix&lt;br /&gt;
* Our survey of the State of the Art in 2015: http://archaeologic.al/wiki/Harris_Matrix&lt;br /&gt;
* The Matrix Reloaded - CAA UK 2016 presentation by John Layt of L - P : Archaeology https://www.youtube.com/watch?v=geLD7Fo6crU&lt;br /&gt;
&lt;br /&gt;
== ARK Matrix Software ==&lt;br /&gt;
&lt;br /&gt;
High-level sketch of docs - a Work-in-Progress!&lt;br /&gt;
&lt;br /&gt;
=== Strat Units ===&lt;br /&gt;
&lt;br /&gt;
Unit Attributes&lt;br /&gt;
* Site Code&lt;br /&gt;
* Unit ID&lt;br /&gt;
* Label&lt;br /&gt;
* Class [Context, Subgroup, Group, Landuse]&lt;br /&gt;
* Type [Deposit, Fill, Cut, Masonry, Skeleton, Timber]&lt;br /&gt;
* Status [Allocated, Assigned, Void]&lt;br /&gt;
* Aggregate Unit&lt;br /&gt;
* Phase&lt;br /&gt;
* Period&lt;br /&gt;
&lt;br /&gt;
=== Strat Relations ===&lt;br /&gt;
&lt;br /&gt;
* Above / Below (directed graph)&lt;br /&gt;
* Same-As (undirected graph)&lt;br /&gt;
* Contemporary With (undirected graph) [REMOVE?]&lt;br /&gt;
&lt;br /&gt;
=== Rules / Heuristics ===&lt;br /&gt;
&lt;br /&gt;
Any Relations:&lt;br /&gt;
* Cannot be between same Unit&lt;br /&gt;
* Both Units must be same Class&lt;br /&gt;
&lt;br /&gt;
Above/Below Relations:&lt;br /&gt;
* Adding relation should not create cycles (no intersection between successors and predecessors)&lt;br /&gt;
&lt;br /&gt;
Same-As Relations:&lt;br /&gt;
* Both Units must be Context class&lt;br /&gt;
* Adding relation should not create cycles (no intersection between successors and predecessors)&lt;br /&gt;
* Both Units must have the same Aggregate Unit if set&lt;br /&gt;
* Both Units must have the same Period / Phase if set&lt;br /&gt;
&lt;br /&gt;
=== Processing ===&lt;br /&gt;
&lt;br /&gt;
Load&lt;br /&gt;
&lt;br /&gt;
Validate&lt;br /&gt;
* Validate Units&lt;br /&gt;
* Validate Above/Below relations&lt;br /&gt;
* Validate Same-as Units&lt;br /&gt;
&lt;br /&gt;
Resolve&lt;br /&gt;
* For each Same-As relationship add all Above/Below relations to each Unit&lt;br /&gt;
&lt;br /&gt;
Validate&lt;br /&gt;
&lt;br /&gt;
Reduce&lt;br /&gt;
* Remove all redundant Above/Below relations (transitive reduction)&lt;br /&gt;
&lt;br /&gt;
Aggregate&lt;br /&gt;
* Validate all Context Units have an Aggregate Unit&lt;br /&gt;
* For each Context Above/Below relation where the Aggregate Unit is different between the Above and Below Units, add an Above/Below relation between the Aggregate Units to the Subgroup matrix&lt;br /&gt;
* Reduce the Subgroup matrix&lt;br /&gt;
* Validate all Subgroup Units have an Aggregate Unit&lt;br /&gt;
* For each Subgroup Above/Below relation where the Aggregate Unit is different between the Above and Below Units, add an Above/Below relation between the Aggregate Units to the Group matrix&lt;br /&gt;
* Reduce the Group matrix&lt;br /&gt;
&lt;br /&gt;
== Development Plans ==&lt;br /&gt;
&lt;br /&gt;
* https://github.com/anvaka/graph-drawing-libraries&lt;br /&gt;
* https://github.com/ArsMasiuk/qvge&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/The_ARK_Way</id>
		<title>ARK2/The ARK Way</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/The_ARK_Way"/>
				<updated>2017-12-16T12:25:03Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Inspiration */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
== Inspiration ==&lt;br /&gt;
&lt;br /&gt;
The architecture, design and implementation of ARK2 was deeply inspired by [http://www.phptherightway.com/ PHP The Right Way], a manifesto for developing modern PHP web applications. Following in that spirit, this page sets out how ARK2 implements the recommendations of [http://www.phptherightway.com/ PHP The Right Way], as well as [https://symfony.com/doc/current/best_practices/index.html Symfony Best Practices], and leavened with our own decades of development experience outside the web world.&lt;br /&gt;
&lt;br /&gt;
This page will broadly follow the organisation of PHP The Right Way, addressing each recommendation in turn&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Maps</id>
		<title>ARK2/Maps</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Maps"/>
				<updated>2017-11-30T12:10:44Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Configuration */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Maps =&lt;br /&gt;
&lt;br /&gt;
ARK2 supports the display of maps and mapping layers using OpenLayers4. Maps and layers can be dynamically defined in the config database and then linked to a defined page view. Much of the config closely reflects the [http://openlayers.org/en/latest/apidoc/ OpenLayers4 API] as this is the map library used by the ARK2 frontend.&lt;br /&gt;
&lt;br /&gt;
== Configuration ==&lt;br /&gt;
&lt;br /&gt;
The following database tables can be configured to define an OL4 map.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Define available [http://openlayers.org/en/latest/apidoc/ol.source.html OL4 Sources] in ark_map_source.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;margin: 0; border: 1px solid grey; text-align:left&amp;quot; cellpadding=&amp;quot;4&amp;quot; cellspacing=&amp;quot;2&amp;quot;&lt;br /&gt;
! colspan=&amp;quot;6&amp;quot; | ark_map_source&lt;br /&gt;
|-&lt;br /&gt;
! Field || Type || Size || Required || Description || Example&lt;br /&gt;
|-&lt;br /&gt;
| source  || varchar  || 30 || PK  || The key for the source || bing&lt;br /&gt;
|-&lt;br /&gt;
| type  || varchar  ||  30  || Y || The type of the source (raster, vector) || raster&lt;br /&gt;
|-&lt;br /&gt;
| subtype  || varchar  ||  30  || Y || The subtype of the source (image, tile, vector) || tile&lt;br /&gt;
|-&lt;br /&gt;
| format  || varchar  ||  30  || Y || The format of the source (wms, gml, etc) || bing&lt;br /&gt;
|-&lt;br /&gt;
| view_class  || varchar  ||  100  || Y || The [http://openlayers.org/en/latest/apidoc/ol.source.html OL4 Class] of the source || BingMaps&lt;br /&gt;
|-&lt;br /&gt;
| keyword  || varchar  ||  100  || Y || The ARK translation keyword || map.source.bing&lt;br /&gt;
|-&lt;br /&gt;
| ticket  || varchar  ||  100  || N || The API auth ticket for the source ||&lt;br /&gt;
|-&lt;br /&gt;
| ticket_expiry  || datetime  ||  || N || The expiry date for the API auth ticket ||&lt;br /&gt;
|-&lt;br /&gt;
| options  || varchar  ||  4000  ||  N || The OL4 Options to pass to the Source class in JSON format ||&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Define available [http://openlayers.org/en/latest/apidoc/ol.layer.html OL4 Layers] for each Source in ark_map_layer.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;margin: 0; border: 1px solid grey; text-align:left&amp;quot; cellpadding=&amp;quot;4&amp;quot; cellspacing=&amp;quot;2&amp;quot;&lt;br /&gt;
! colspan=&amp;quot;6&amp;quot; | ark_map_layer&lt;br /&gt;
|-&lt;br /&gt;
! Field || Type || Size || Required || Description || Example&lt;br /&gt;
|-&lt;br /&gt;
| source  || varchar  ||  30  || PK || The source key from ark_map_source || bing&lt;br /&gt;
|-&lt;br /&gt;
| layer  || varchar  ||  30  || PK || The layer key || aerial&lt;br /&gt;
|-&lt;br /&gt;
| source_name  || varchar  ||  50  || Y || The key of the layer as defined by the source provider || Aerial&lt;br /&gt;
|-&lt;br /&gt;
| keyword  || varchar  ||  100  || Y || The ARK translation keyword || map.layer.bing.aerial&lt;br /&gt;
|-&lt;br /&gt;
| url  || varchar  ||  2000  ||  N || The url of the layer ||&lt;br /&gt;
|-&lt;br /&gt;
| options  || varchar  ||  4000  ||  N || The OL4 Options to pass to the Layer class in JSON format ||&lt;br /&gt;
|-&lt;br /&gt;
| parameters  || varchar  ||  4000  ||  N || The layer parameters to pass to the source provider ||&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Define available [http://openlayers.org/en/latest/apidoc/ol.Map.html OL4 Map] views in ark_map.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;margin: 0; border: 1px solid grey; text-align:left&amp;quot; cellpadding=&amp;quot;4&amp;quot; cellspacing=&amp;quot;2&amp;quot;&lt;br /&gt;
! colspan=&amp;quot;6&amp;quot; | ark_map_source&lt;br /&gt;
|-&lt;br /&gt;
! Field || Type || Size || Required || Description || Example&lt;br /&gt;
|-&lt;br /&gt;
| map  || varchar  || 30 || PK  || The key for the map || ark_map_main&lt;br /&gt;
|-&lt;br /&gt;
| draggable  || boolean  ||  || Y || If the map view is draggable ||&lt;br /&gt;
|-&lt;br /&gt;
| clickable  || boolean  ||  || Y || If the map view is clickable ||&lt;br /&gt;
|-&lt;br /&gt;
| zoomable  || boolean  ||  || Y || If the map view is zoomable ||&lt;br /&gt;
|-&lt;br /&gt;
| zoom  || integer  ||  || Y || The default zoom level || 7&lt;br /&gt;
|-&lt;br /&gt;
| min_zoom  || integer  ||  || N || The minimum zoom level || 6&lt;br /&gt;
|-&lt;br /&gt;
| max_zoom  || integer  ||  || N || The maximum zoom level || 16&lt;br /&gt;
|-&lt;br /&gt;
| srid  || integer  ||  || N || The SRID of the map projection || 4512&lt;br /&gt;
|-&lt;br /&gt;
| center  || varchar  ||  50  || Y || The default center point of the map view in WKT format || POINT (1155972 7580813)&lt;br /&gt;
|-&lt;br /&gt;
| extent  || varchar  ||  100  || N || The maximum extent of the map view in WKT format || MULTIPOINT (831000 7230000, 1750000 7950000)&lt;br /&gt;
|-&lt;br /&gt;
| keyword  || varchar  ||  100  || N || The ARK translation keyword || ark.map.main&lt;br /&gt;
|-&lt;br /&gt;
| options  || varchar  ||  4000  ||  N || The OL4 Options to pass to the Map class in JSON format ||&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Define the Source Layers displayed in a Map View in the ark_map_legend table.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; style=&amp;quot;margin: 0; border: 1px solid grey; text-align:left&amp;quot; cellpadding=&amp;quot;4&amp;quot; cellspacing=&amp;quot;2&amp;quot;&lt;br /&gt;
! colspan=&amp;quot;6&amp;quot; | ark_map_layer&lt;br /&gt;
|-&lt;br /&gt;
! Field || Type || Size || Required || Description || Example&lt;br /&gt;
|-&lt;br /&gt;
| map  || varchar  || 30 || PK  || The map key from ark_map || ark_map_main&lt;br /&gt;
|-&lt;br /&gt;
| source  || varchar  ||  30  || PK || The source key from ark_map_layer || bing&lt;br /&gt;
|-&lt;br /&gt;
| layer  || varchar  ||  30  || PK || The layer key from ark_map_layer || aerial&lt;br /&gt;
|-&lt;br /&gt;
| seq  || integer  ||  || Y || The sequence of the layer in the legend || 1&lt;br /&gt;
|-&lt;br /&gt;
| is_default  || boolean  ||  || Y || If the view layer is the default ||&lt;br /&gt;
|-&lt;br /&gt;
| visible  || boolean  ||  || Y || If the view layer is visible by default ||&lt;br /&gt;
|-&lt;br /&gt;
| enabled  || boolean  ||  || Y || If the view layer is enabled ||&lt;br /&gt;
|-&lt;br /&gt;
| keyword  || varchar  ||  100  || Y || The ARK translation keyword || map.layer.bing.aerial&lt;br /&gt;
|-&lt;br /&gt;
| options  || varchar  ||  4000  ||  N || The OL4 Options to pass to the Layer class in JSON format ||&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/Available_config</id>
		<title>Available config</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/Available_config"/>
				<updated>2017-11-27T16:10:16Z</updated>
		
		<summary type="html">&lt;p&gt;Mike: /* ARK Empty */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
With the ARK1.2 release there are several available default setups or &amp;quot;configs&amp;quot; for ARK. When installing ARK you must choose the right one for your project.&lt;br /&gt;
&lt;br /&gt;
===Single Context===&lt;br /&gt;
This is L - P : Archaeology&amp;#039;s favourite config, it is a full implementation of the MoL recording system including modules for Contexts, Sections, Plans, Registered Finds, Samples, Site Photographs, Timber, &amp;#039;Trenches, Areas, Etc&amp;#039; (TAE), Subgroups, Groups and Landuses.&lt;br /&gt;
&lt;br /&gt;
===Basic Context===&lt;br /&gt;
This is a simple version of the single context recording system which has modules for Contexts, Plans, Sections, Registered Finds and Site Photos.&lt;br /&gt;
&lt;br /&gt;
===ARK Landscape===&lt;br /&gt;
This config is good for landscape studies it has modules for Locations, Excavations, Finds, Catalogued Finds, Illustrations and Photos.&lt;br /&gt;
&lt;br /&gt;
===ARK Stratigraphic Unit===&lt;br /&gt;
This config is used by some mediterranean projects, it has modules for Contexts, Site Photos,  Plans, Geophotos, Architectural Elements, Special Finds and Coins&lt;br /&gt;
&lt;br /&gt;
===ARK Empty===&lt;br /&gt;
ARK is endlessly customisable, the empty config has only the required addressbook module, allowing you to create your own config with modules from the other configs, or by creating them yourself. check out the [http://ark.lparchaeology.com/wiki/index.php/Mod_settings.php Mod Settings] page to see how.&lt;/div&gt;</summary>
		<author><name>Mike</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Community</id>
		<title>ARK2/Community</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Community"/>
				<updated>2017-05-27T11:46:10Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;A development and support community will be required for both the Project and the Service.&lt;br /&gt;
&lt;br /&gt;
* User support&lt;br /&gt;
* Sysadmins support&lt;br /&gt;
* Developers support&lt;br /&gt;
&lt;br /&gt;
An online chat service that integrates with an issue tracker, project manager, wiki, and code repository will be needed for developers. A chat, wiki, and forum will be needed for user support. It makes sense to use a single solution for both, either under a single brand or separate brands. The Service will need to be able to keep some Projects, Clients, and Tasks private, with the rest remaining open.&lt;br /&gt;
&lt;br /&gt;
Needed Features:&lt;br /&gt;
* Guest or OAuth &lt;br /&gt;
* Chat: web and app&lt;br /&gt;
* Wiki&lt;br /&gt;
* GitHub integration&lt;br /&gt;
* CI system&lt;br /&gt;
* Bots&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Chat options:&lt;br /&gt;
* Basecamp / Campfire - More customer oriented than coder oriented, costs $1000 p/a&lt;br /&gt;
* Gitter - Integrated with GitHub and common developer services, free but not open, dodgy security, login only via GitHub or Twitter account&lt;br /&gt;
* Atlassian / HipChat - Lots of integration, free hosted/paid, not open&lt;br /&gt;
* RocketChat - Free and Open, self-serve, host very expensive, fewer integrations, but screenshare and videochat are free.&lt;br /&gt;
* Slack&lt;br /&gt;
* Flock https://flock.com/uk/pricing/&lt;br /&gt;
* Mattermost https://about.mattermost.com/features/&lt;br /&gt;
* Matrix / Riot https://matrix.org/ / https://about.riot.im/need-help/&lt;br /&gt;
* Discourse https://www.discourse.org/features&lt;br /&gt;
* https://www.getopensocial.com/&lt;br /&gt;
* https://www.oxwall.com/&lt;br /&gt;
* https://www.humhub.org/en&lt;br /&gt;
&lt;br /&gt;
Project Management Options:&lt;br /&gt;
* https://huboard.com/pricing&lt;br /&gt;
* https://waffle.io/pricing/&lt;br /&gt;
* https://www.zenhub.com/pricing&lt;br /&gt;
* https://overv.io/&lt;br /&gt;
&lt;br /&gt;
Help Ticket:&lt;br /&gt;
* https://github.com/ladybirdweb/faveo-helpdesk&lt;br /&gt;
&lt;br /&gt;
Other:&lt;br /&gt;
* https://secure.phabricator.com/applications/&lt;br /&gt;
* https://www.gitbook.com/pricing&lt;br /&gt;
* https://zapier.com/&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Install</id>
		<title>ARK2/Install</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Install"/>
				<updated>2017-01-09T18:08:35Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Debian Stable (Stretch) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Install =&lt;br /&gt;
&lt;br /&gt;
== Git / Github ==&lt;br /&gt;
&lt;br /&gt;
Development is hosted on [https://gitlab.com/arklab GitLab], so you will need a free GitLab account to contribute code.&lt;br /&gt;
&lt;br /&gt;
If you are new to Git, you may find a desktop application easier to use such as [https://www.sourcetreeapp.com/ SourceTree] and [https://www.gitkraken.com/ GitKraken], or the support built-in to your IDE like Atom.&lt;br /&gt;
&lt;br /&gt;
== Environment ==&lt;br /&gt;
&lt;br /&gt;
To develop ARK requires the following tools to be installed:&lt;br /&gt;
* [https://git-scm.com/ Git]&lt;br /&gt;
* [https://getcomposer.org/ Composer]&lt;br /&gt;
* [https://nodejs.org/en/ Node.js] (for frontend/theme development only)&lt;br /&gt;
&lt;br /&gt;
You will also require PHP, a web server (Apache/PHP), a database server (MySQL/PostreSQL/SQLite), a web browser (Chrome/Firefox), and a an API client (Postman).&lt;br /&gt;
&lt;br /&gt;
The following tools are recommend to adhere to ARK code quality standards:&lt;br /&gt;
* php-cs-fixer&lt;br /&gt;
* PHP CodeSniffer&lt;br /&gt;
&lt;br /&gt;
=== macOS ===&lt;br /&gt;
&lt;br /&gt;
On macOS, while you can install the requirements via standalone packages such as [https://www.mamp.info/en/ MAMP], we recommend using HomeBrew as it makes installing and updating all the tools used easier. Using macOS is only recommended for local hosting or development purposes only, internet-connected production sites should be run on a properly supported server installation, such as Debian Stretch.&lt;br /&gt;
&lt;br /&gt;
* Install XCode from the App Store and run it to accept the license, or from the command line: &amp;lt;pre&amp;gt;sudo xcodebuild -license accept&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Check you have the Command Line Tools (including Git) installed and enabled: &amp;lt;pre&amp;gt;sudo xcode-select --install&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Download and install [http://brew.sh/ HomeBrew]: &amp;lt;pre&amp;gt;/usr/bin/ruby -e &amp;quot;$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)&amp;quot;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Modify your ~/.profile file to add brew packages to your $PATH and to enable Git completion&lt;br /&gt;
&amp;lt;pre&amp;gt; export PATH=/usr/local/bin:/usr/local/sbin:$PATH&lt;br /&gt;
 source /Library/Developer/CommandLineTools/usr/share/git-core/git-completion.bash&lt;br /&gt;
 source /Library/Developer/CommandLineTools/usr/share/git-core/git-prompt.sh&lt;br /&gt;
 GIT_PS1_SHOWDIRTYSTATE=true&lt;br /&gt;
 PS1=&amp;#039;\u@\h \W$(__git_ps1 &amp;quot; (%s)&amp;quot;) \$ &amp;#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Source your modified ~/.profile file to start using it: &amp;lt;pre&amp;gt;source ~/.profile&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Install the required packages from Brew: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
 brew install httpd mariadb imagemagick icu4c&lt;br /&gt;
 brew install php@7.4&lt;br /&gt;
 pecl install apcu imagick xdebug&lt;br /&gt;
 brew install composer php-code-sniffer php-cs-fixer@2 phpdocumentor phplint phpmyadmin&lt;br /&gt;
 brew install node@14&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Modify /usr/local/etc/httpd/httpd.conf to enable PHP-FPM, aliases, vhosts and rewrite by uncommenting the following lines:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
 LoadModule proxy_module lib/httpd/modules/mod_proxy.so&lt;br /&gt;
 LoadModule proxy_fcgi_module lib/httpd/modules/mod_proxy_fcgi.so&lt;br /&gt;
 LoadModule vhost_alias_module lib/httpd/modules/mod_vhost_alias.so&lt;br /&gt;
 LoadModule alias_module lib/httpd/modules/mod_alias.so&lt;br /&gt;
 LoadModule rewrite_module lib/httpd/modules/mod_rewrite.so&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Add the following after the DocumentRoot section to enable PhpMyAdmin:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Alias /phpmyadmin /usr/local/share/phpmyadmin&lt;br /&gt;
&amp;lt;Directory /usr/local/share/phpmyadmin/&amp;gt;&lt;br /&gt;
    Options Indexes FollowSymLinks MultiViews&lt;br /&gt;
    AllowOverride All&lt;br /&gt;
    Require all granted&lt;br /&gt;
&amp;lt;/Directory&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Modify the DirectoryIndex section to appear as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#&lt;br /&gt;
# DirectoryIndex: sets the file that Apache will serve if a directory&lt;br /&gt;
# is requested.&lt;br /&gt;
#&lt;br /&gt;
&amp;lt;IfModule dir_module&amp;gt;&lt;br /&gt;
    DirectoryIndex index.html index.php&lt;br /&gt;
&amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;IfModule proxy_fcgi_module&amp;gt;&lt;br /&gt;
    &amp;lt;FilesMatch &amp;quot;.+\.ph(ar|p|tml)$&amp;quot;&amp;gt;&lt;br /&gt;
        SetHandler &amp;quot;proxy:fcgi://127.0.0.1:9000&amp;quot;&lt;br /&gt;
    &amp;lt;/FilesMatch&amp;gt;&lt;br /&gt;
&amp;lt;/IfModule&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Start the required services:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
 brew services start mariadb&lt;br /&gt;
 brew services start php@7.4&lt;br /&gt;
 brew services start httpd&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Point your browser to localhost and you should see the default Apache page&lt;br /&gt;
* Point your browser to localhost/phpmyadmin and sign in to confirm that PHP and MariaDB are running correctly&lt;br /&gt;
&lt;br /&gt;
=== Debian ===&lt;br /&gt;
&lt;br /&gt;
Since Debian Stretch, Debian has enabled the parallel install of multiple PHP versions using PHP-FM. However each release of Debian ships with a different default version and only that version is officially supported in that release. In order to install other versions such as PHP 5.6 and 7.4 you need to use the packages made available by the Debian Maintainer in his personal development repo. Check your version of Debian to determine what you need. LP Archaeology use this solution for our servers and we strongly recommend you use this method for both simplicity and reliability.&lt;br /&gt;
&lt;br /&gt;
Instructions for NodeJS: https://nodejs.org/en/download/package-manager/#debian-and-ubuntu-based-linux-distributions&lt;br /&gt;
&lt;br /&gt;
Instructions for adding PHP repo: https://packages.sury.org/php/README.txt.  See also https://github.com/oerdnj/deb.sury.org/wiki/Managing-Multiple-Versions&lt;br /&gt;
&lt;br /&gt;
Summary of install commands for PHP 7.4 current requirement:&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install build-essential git apache2 mariadb-client mariadb-server&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install php7.4 php7.4-apcu php7.4-apcu-bc php7.4-bcmath php7.4-bz2 php7.4-cli php7.4-common php7.4-fpm php7.4-gd \&lt;br /&gt;
   php7.4-geoip php7.4-imagick php7.4-intl php7.4-json php7.4-mbstring php7.4-mysql php7.4-opcache php7.1-readline php7.4-sqlite3 \&lt;br /&gt;
   php7.4-tidy php7.4-uuid php7.4-yaml php7.4-xml php7.4-zip phpmyadmin php-pear&lt;br /&gt;
&lt;br /&gt;
 curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -&lt;br /&gt;
 sudo apt-get install -y nodejs&lt;br /&gt;
&lt;br /&gt;
 curl -sS https://getcomposer.org/installer -o composer-setup.php&lt;br /&gt;
 php composer-setup.php --install-dir=/usr/local/bin --filename=composer&lt;br /&gt;
&lt;br /&gt;
Enabled FPM&lt;br /&gt;
&lt;br /&gt;
 sudo service php7.4-fpm start&lt;br /&gt;
 sudo systemctl enable  php7.4-fpm&lt;br /&gt;
 sudo a2enconf php7.4-fpm&lt;br /&gt;
 sudo a2enmod proxy_fcgi rewrite&lt;br /&gt;
&lt;br /&gt;
Once ARK is installed (see below), configure Apache to serve the site, using either alias or symlink.&lt;br /&gt;
&lt;br /&gt;
sudo vim /etc/apache2/sites-available/mysite.conf&lt;br /&gt;
&lt;br /&gt;
Using a simple alias on a subdirectory:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;VirtualHost *:80&amp;gt;&lt;br /&gt;
      ServerName localhost&lt;br /&gt;
      ServerAdmin sysadmin@localhost&lt;br /&gt;
      DirectoryIndex index.html index.php&lt;br /&gt;
      LogLevel debug&lt;br /&gt;
      Alias &amp;quot;/mysite&amp;quot;&lt;br /&gt;
      &amp;lt;Directory &amp;quot;/srv/www/lib/ark2/sites/mysite/web&amp;quot;&amp;gt;&lt;br /&gt;
          Options FollowSymLinks&lt;br /&gt;
          Require all granted&lt;br /&gt;
          AllowOverride None&lt;br /&gt;
          AcceptPathInfo On&lt;br /&gt;
          RewriteEngine On&lt;br /&gt;
          RewriteCond %{REQUEST_FILENAME} !-f&lt;br /&gt;
          RewriteRule ^(.*)$ /index.php [QSA,L]&lt;br /&gt;
     &amp;lt;/Directory&amp;gt;&lt;br /&gt;
  &amp;lt;/VirtualHost&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Using a vhost on a subdomain &lt;br /&gt;
&lt;br /&gt;
  &amp;lt;VirtualHost *:80&amp;gt;&lt;br /&gt;
      ServerName mysite.example.com&lt;br /&gt;
      ServerAdmin admin@example.com&lt;br /&gt;
      DocumentRoot /srv/www/lib/ark2/sites/mysite/web&lt;br /&gt;
      DirectoryIndex index.html index.php&lt;br /&gt;
      LogLevel warn&lt;br /&gt;
      ErrorLog /path/to/logs/&amp;lt;site&amp;gt;/error.log&lt;br /&gt;
      CustomLog /path/to/logs/&amp;lt;site&amp;gt;/access.log combined&lt;br /&gt;
      &amp;lt;Directory &amp;quot;/srv/www/lib/ark2/sites/mysite/web&amp;quot;&amp;gt;&lt;br /&gt;
          Options FollowSymLinks&lt;br /&gt;
          Require all granted&lt;br /&gt;
          AllowOverride None&lt;br /&gt;
          AcceptPathInfo On&lt;br /&gt;
          RewriteEngine On&lt;br /&gt;
          RewriteCond %{REQUEST_FILENAME} !-f&lt;br /&gt;
          RewriteRule ^(.*)$ /index.php [QSA,L]&lt;br /&gt;
     &amp;lt;/Directory&amp;gt;&lt;br /&gt;
  &amp;lt;/VirtualHost&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 sudo a2ensite mysite&lt;br /&gt;
&lt;br /&gt;
 sudo apache2ctl -t&lt;br /&gt;
&lt;br /&gt;
 sudo systemctl reload apache2&lt;br /&gt;
&lt;br /&gt;
 sudo apache2ctl -S&lt;br /&gt;
&lt;br /&gt;
== Install ==&lt;br /&gt;
&lt;br /&gt;
To install using git, create the folder where the library code will be located, then clone the ARK2 repository.&lt;br /&gt;
&lt;br /&gt;
For example, for Debian stretch:&lt;br /&gt;
&lt;br /&gt;
 mkdir -p /srv/www/lib&lt;br /&gt;
 cd /srv/www/lib&lt;br /&gt;
 git clone https://gitlab.com/arklab/arkserver.git&lt;br /&gt;
&lt;br /&gt;
Alternatively download and unzip the file from https://gitlab.com/arklab/arkserver&lt;br /&gt;
&lt;br /&gt;
Then run composer to install the required PHP libraries:&lt;br /&gt;
&lt;br /&gt;
 cd arkserver/&lt;br /&gt;
 composer install&lt;br /&gt;
 &amp;lt;may need github token...&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Run the Sysadmin console to check your install:&lt;br /&gt;
&lt;br /&gt;
 ./bin/sysadmin&lt;br /&gt;
 ./bin/sysadmin system:about&lt;br /&gt;
&lt;br /&gt;
Check the database server config file is correct for your install:&lt;br /&gt;
&lt;br /&gt;
 less sites/servers.json&lt;br /&gt;
&lt;br /&gt;
If you need to add different server details:&lt;br /&gt;
&lt;br /&gt;
 ./bin/sysadmin database:server:add&lt;br /&gt;
&lt;br /&gt;
To create a new site:&lt;br /&gt;
&lt;br /&gt;
 ./bin/sysadmin site:create &amp;lt;site&amp;gt;&lt;br /&gt;
 ./sites/&amp;lt;site&amp;gt;/bin/console&lt;br /&gt;
&lt;br /&gt;
Now edit the site config files to reflect your site settings. Most settings will have the correct default, but some may need tweaking:&lt;br /&gt;
&lt;br /&gt;
 vim sites/&amp;lt;site&amp;gt;/config/site.json&lt;br /&gt;
&lt;br /&gt;
If using vhosts, see above for instructions.&lt;br /&gt;
&lt;br /&gt;
If not using vhosts, for local development, edit your Apache config to alias the site folder:&lt;br /&gt;
&lt;br /&gt;
 Alias /&amp;lt;site&amp;gt; /path/to/ark2/sites/&amp;lt;site&amp;gt;/web&lt;br /&gt;
 &amp;lt;Directory /path/to/ark2/sites/&amp;lt;mysite&amp;gt;/web&amp;gt;&lt;br /&gt;
     Options Indexes FollowSymLinks MultiViews&lt;br /&gt;
     AllowOverride All&lt;br /&gt;
     Require all granted&lt;br /&gt;
 &amp;lt;/Directory&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 http://localhost/&amp;lt;site&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To rebuild the frontend&lt;br /&gt;
 cd build&lt;br /&gt;
 npm install&lt;br /&gt;
 ./build frontend:all &amp;lt;frontend&amp;gt;&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Console</id>
		<title>ARK2/Console</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Console"/>
				<updated>2017-01-04T10:07:50Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Console */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Console =&lt;br /&gt;
&lt;br /&gt;
ARK2 uses the [https://symfony.com/doc/current/components/console.html Symfony Console] to provide three custom command-line consoles for maintaining ARK:&lt;br /&gt;
&lt;br /&gt;
* The System Console - A console to assist in managing an ARK system install (./bin/sysadmin)&lt;br /&gt;
* The Site Console - A console to assist in managing an ARK site in a system install (./sites/&amp;lt;site&amp;gt;/bin/console)&lt;br /&gt;
* The Build Console - A console to assist in developing ARK and ARK front-ends (./build/build)&lt;br /&gt;
&lt;br /&gt;
The key difference between the System and Site consoles is the System console does not load a specific site configuration when it runs. This allows it to perform maintenance on the whole system or on an individual site even when an individual site configuration is unable to be loaded. The Site Console needs to load a valid site configuration to allow it to perform more advanced site-specific maintenance.&lt;br /&gt;
&lt;br /&gt;
The Build Console is for developer use only and is documented under the Frontend Build documentation.&lt;br /&gt;
&lt;br /&gt;
== System Console ==&lt;br /&gt;
&lt;br /&gt;
The System Console can be run from the command line from the root install folder:&lt;br /&gt;
&lt;br /&gt;
 ./bin/sysadmin&lt;br /&gt;
&lt;br /&gt;
Running the console without and parameters displays a help message and the list of available commands:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ARK System Admin Console 1.9.80&lt;br /&gt;
&lt;br /&gt;
Usage:&lt;br /&gt;
  command [options] [arguments]&lt;br /&gt;
&lt;br /&gt;
Options:&lt;br /&gt;
  -h, --help            Display this help message&lt;br /&gt;
  -q, --quiet           Do not output any message&lt;br /&gt;
  -V, --version         Display this application version&lt;br /&gt;
      --ansi            Force ANSI output&lt;br /&gt;
      --no-ansi         Disable ANSI output&lt;br /&gt;
  -n, --no-interaction  Do not ask any interactive question&lt;br /&gt;
  -v|vv|vvv, --verbose  Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug&lt;br /&gt;
&lt;br /&gt;
Available commands:&lt;br /&gt;
  help                  Displays help for a command&lt;br /&gt;
  list                  Lists commands&lt;br /&gt;
 cache&lt;br /&gt;
  cache:clear           Clear the system cache&lt;br /&gt;
 database&lt;br /&gt;
  database:clone        Clone an existing database&lt;br /&gt;
  database:drop:tables  Drop all tables in a database&lt;br /&gt;
  database:import       Import an SQL file into a database&lt;br /&gt;
  database:server:add   Add a new database server&lt;br /&gt;
  database:truncate     Truncate all tables in a database&lt;br /&gt;
 security&lt;br /&gt;
  security:check        Checks security issues in your project dependencies&lt;br /&gt;
 site&lt;br /&gt;
  site:create           Create a new site&lt;br /&gt;
  site:frontend         Install or replace a frontend. WARNING: Will delete the old frontend!&lt;br /&gt;
  site:migrate:info     Analyse the migration mapping for an ARK 1 site&lt;br /&gt;
  site:migrate:load     Migrate an ARK 1.2 site&lt;br /&gt;
  site:migrate:map      Create the migration mapping for an ARK 1 site&lt;br /&gt;
 system&lt;br /&gt;
  system:about          Display information about the system&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Site Console ==&lt;br /&gt;
&lt;br /&gt;
The System Console can be run from the command line from the root install folder:&lt;br /&gt;
&lt;br /&gt;
 ./bin/sysadmin&lt;br /&gt;
&lt;br /&gt;
Running the console without and parameters displays a help message and the list of available commands:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ARK Site Admin Console 1.9.80&lt;br /&gt;
&lt;br /&gt;
Usage:&lt;br /&gt;
  command [options] [arguments]&lt;br /&gt;
&lt;br /&gt;
Options:&lt;br /&gt;
  -h, --help            Display this help message&lt;br /&gt;
  -q, --quiet           Do not output any message&lt;br /&gt;
  -V, --version         Display this application version&lt;br /&gt;
      --ansi            Force ANSI output&lt;br /&gt;
      --no-ansi         Disable ANSI output&lt;br /&gt;
  -n, --no-interaction  Do not ask any interactive question&lt;br /&gt;
  -v|vv|vvv, --verbose  Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug&lt;br /&gt;
&lt;br /&gt;
Available commands:&lt;br /&gt;
  help                  Displays help for a command&lt;br /&gt;
  list                  Lists commands&lt;br /&gt;
 cache&lt;br /&gt;
  cache:clear           Clear the system cache&lt;br /&gt;
 database&lt;br /&gt;
  database:drop:tables  Drop all tables in a database&lt;br /&gt;
  database:import       Import an SQL file into a database&lt;br /&gt;
  database:truncate     Truncate all tables in a database&lt;br /&gt;
 orm&lt;br /&gt;
  orm:entity:generate   Generate ORM Entities for Custom ARK Modules&lt;br /&gt;
 route&lt;br /&gt;
  route:dump            Dump configured route(s)&lt;br /&gt;
 site&lt;br /&gt;
  site:about            Display information about the site&lt;br /&gt;
 spatial&lt;br /&gt;
  spatial:rebuild       Rebuild the Spatial Index&lt;br /&gt;
 translation&lt;br /&gt;
  translation:add       Add or Set a translation.&lt;br /&gt;
 user&lt;br /&gt;
  user:create           Create a new user&lt;br /&gt;
  user:delete           Delete a user&lt;br /&gt;
  user:disable          Disable a user&lt;br /&gt;
  user:enable           Enable a user&lt;br /&gt;
  user:list             List all users.&lt;br /&gt;
  user:password:reset   Send user a password reset email&lt;br /&gt;
  user:password:set     Set the password for a user&lt;br /&gt;
  user:role:add         Add a user role&lt;br /&gt;
  user:role:delete      Delete a user role&lt;br /&gt;
  user:verify           Verify a user&amp;#039;s email&lt;br /&gt;
 view&lt;br /&gt;
  view:page:dump        Dump a View Page&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Templates</id>
		<title>ARK2/Templates</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Templates"/>
				<updated>2017-01-02T13:37:15Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Extensions */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Templates =&lt;br /&gt;
&lt;br /&gt;
ARK2 uses the TWIG templating engine to define the Front-end web views.&lt;br /&gt;
&lt;br /&gt;
See the [http://twig.sensiolabs.org/documentation Twig documentation] on general use of Twig.&lt;br /&gt;
&lt;br /&gt;
See the [http://silex.sensiolabs.org/doc/providers/twig.html Silex documentation] for using TWIG with the Silex Framework.&lt;br /&gt;
&lt;br /&gt;
See the [http://symfony.com/doc/current/templating.html Symfony documentation] for using TWIG with the Symfony Components&lt;br /&gt;
&lt;br /&gt;
== Extensions ==&lt;br /&gt;
&lt;br /&gt;
TWIG can easily be extended with custom extensions to the template language. ARK2 ships with a number of common extensions, as well as some ARK-specific extensions.&lt;br /&gt;
&lt;br /&gt;
* ARK:&lt;br /&gt;
** service: A global variable to access the ARK Service object.&lt;br /&gt;
** translate: An extension to the standard Symfony trans option to add support for ARK Translation Roles, see [[ARK2/Localization#Translation|Translation]].&lt;br /&gt;
** translatechoice: An extension to the standard Symfony transchoice option to add support for ARK Translation Roles, see [[ARK2/Localization#Translation|Translation]].&lt;br /&gt;
&lt;br /&gt;
* [http://silex.sensiolabs.org/doc/providers/twig.html Silex/Symfony Extensions] , in particular:&lt;br /&gt;
** [http://symfony.com/doc/current/book/translation.html#twig-templates Translation]&lt;br /&gt;
** [http://symfony.com/doc/current/reference/forms/twig_reference.html Forms]&lt;br /&gt;
** [http://symfony.com/doc/current/book/security.html#access-control-in-templates Security]&lt;br /&gt;
** Asset&lt;br /&gt;
** Global variables for: app, request, session, user, debug&lt;br /&gt;
&lt;br /&gt;
* [http://twig.sensiolabs.org/doc/extensions/index.html Official Twig Extensions], in particular:&lt;br /&gt;
** Text: Provides useful filters for text manipulation;&lt;br /&gt;
** Intl: Adds a filter for localization of DateTime objects, numbers and currency;&lt;br /&gt;
** Array: Provides useful filters for array manipulation;&lt;br /&gt;
** Date: Adds a filter for rendering the difference between dates.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Workflow</id>
		<title>ARK2/Workflow</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Workflow"/>
				<updated>2016-12-30T11:19:04Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: Created page with &amp;quot;= Workflow =   * https://github.com/Sylius/SyliusFlowBundle * https://www.w3.org/TR/activitystreams-core/&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Workflow =&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* https://github.com/Sylius/SyliusFlowBundle&lt;br /&gt;
* https://www.w3.org/TR/activitystreams-core/&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Cache</id>
		<title>ARK2/Cache</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Cache"/>
				<updated>2016-12-27T15:27:11Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Implementation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Cache =&lt;br /&gt;
&lt;br /&gt;
Caching can greatly improve performance of ARK, especially for configuration and metadata, but also the data and database access. ARK provides a flexible caching system based on Doctrine Cache, Symphony Cache, and the PSR-6 Caching standard, and supporting filesystem, APCu, or Redis caches (others are possible but not officially supported).&lt;br /&gt;
&lt;br /&gt;
By default, ARK will use APCu for caching if your server has APCu installed, otherwise a filesystem cache will be used. For high-volume sites and APIs, Redis is recommended using either Predis or PHPRedis. Redis can also be used as a Spatial cache to speed up spatial searches.&lt;br /&gt;
&lt;br /&gt;
== Configuration ==&lt;br /&gt;
&lt;br /&gt;
If caching is not explicitly configured in the site.json file, then ARK will check if APCu is available, and if not will fall back to the filesystem. To fractionally improve performance, you can use site.json to explicitly set &amp;#039;apc&amp;#039; or &amp;#039;file&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
If using Redis you need to explicitly set site.json to use &amp;#039;redis&amp;#039; and the url of the Redis instance.&lt;br /&gt;
&lt;br /&gt;
If Debug mode is enabled, then the cache is disabled.&lt;br /&gt;
&lt;br /&gt;
== Implementation ==&lt;br /&gt;
&lt;br /&gt;
ARK uses the Symfony Cache component for a PSR-6 compliant implementation. This also provides a bridge for the Doctrine ORM to use for caching.&lt;br /&gt;
&lt;br /&gt;
Two caches are provided, the System and Application caches:&lt;br /&gt;
* System: An APCu cache primarily for PHP compilable items or smaller static items such as config and metadata.&lt;br /&gt;
* App: A cache for application data.&lt;br /&gt;
&lt;br /&gt;
These caches are accessed via the container:&lt;br /&gt;
* $app[&amp;#039;cache.app&amp;#039;] or $app[&amp;#039;cache&amp;#039;]&lt;br /&gt;
* $app[&amp;#039;cache.system&amp;#039;]&lt;br /&gt;
* $app[&amp;#039;cache.orm.app&amp;#039;]&lt;br /&gt;
* $app[&amp;#039;cache.orm.system&amp;#039;]&lt;br /&gt;
&lt;br /&gt;
The global Service object also provides access to the cache.&lt;br /&gt;
&lt;br /&gt;
== Commands ==&lt;br /&gt;
&lt;br /&gt;
* cache::warmup - Warms-up the System cache&lt;br /&gt;
* cache::clear - Clears the System cache&lt;br /&gt;
* cache::refresh - Clears and warms-up the System cache&lt;br /&gt;
* doctrine cache commands?&lt;br /&gt;
&lt;br /&gt;
Any cachable component should provide HTTP Kernel CacheWarmer and CacheClearer implementations and register these with the cache provider.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Vocabulary</id>
		<title>ARK2/Vocabulary</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Vocabulary"/>
				<updated>2016-12-19T14:13:30Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Classes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Vocabulary =&lt;br /&gt;
&lt;br /&gt;
ARK1 supported Controlled Lists of Attributes. In ARK2 we support other types of Controlled Vocabularies including Taxonomies and Thesauri, in compliance with ANSI/NISO standard [http://www.niso.org/publications/ansiniso-z3919-2005-r2010-guidelines-construction-format-and-management-monolingual Z39.19-2005 &amp;#039;Guidelines for the Construction, Format, and Management of Monolingual Controlled Vocabularies&amp;#039;].&lt;br /&gt;
&lt;br /&gt;
== Definitions ==&lt;br /&gt;
&lt;br /&gt;
* Concept - What the Vocabulary is about, such as Country, Period, Material, etc&lt;br /&gt;
* Term - A valid value within the Vocabulary, such as Denmark, Viking, Gold, etc&lt;br /&gt;
* Type - The Type of Controlled Vocabulary which controls what relationships the Vocabulary has between Terms (Equivalence, Hierarchy, Association)&lt;br /&gt;
* Equivalence - Where two Terms are considered the same&lt;br /&gt;
* Hierarchy - Where two Terms have a parent/child relationship, usually called broader/narrower&lt;br /&gt;
* Association - Where two Terms have a relationship that is not Equivalence nor Hierarchy, i.e. related terms, order, etc&lt;br /&gt;
* List - A simple list of valid terms with no relationships&lt;br /&gt;
* Ring - A list of valid Terms that are all Equivalent&lt;br /&gt;
* Taxonomy - A list of valid Terms that are arranged in a Hierarchy&lt;br /&gt;
* Thesaurus - A list of valid Terms that arranged in a Hierarchy with optional Equivalence and/or Association between some Terms, usually ordered&lt;br /&gt;
* Metadata - Information related to a Term, for example a Period will have a Start Year and End Year&lt;br /&gt;
&lt;br /&gt;
== Translations ==&lt;br /&gt;
&lt;br /&gt;
Translations will be denoted as being in the &amp;#039;Vocabulary&amp;#039; Domain. The Translations admin will not include these translations, these will be managed in the Vocabulary admin instead.&lt;br /&gt;
&lt;br /&gt;
== Resources ==&lt;br /&gt;
&lt;br /&gt;
* http://www.getty.edu/research/publications/electronic_publications/intro_controlled_vocab/&lt;br /&gt;
* https://www.controlledvocabulary.com/&lt;br /&gt;
&lt;br /&gt;
== Database == &lt;br /&gt;
&lt;br /&gt;
The following tables hold the data for individual vocabularies:&lt;br /&gt;
* ark_vocabulary - Key table for vocabulary concepts&lt;br /&gt;
* ark_vocabulary_term - Table for terms in a vocabulary&lt;br /&gt;
* ark_vocabulary_parameter - Table for optional parameters applying to a term&lt;br /&gt;
* ark_vocabulary_related - Table for optional relationships betweens terms if a vocabulary or taxonomy&lt;br /&gt;
&lt;br /&gt;
The following reference tables are unlikely to require editing:&lt;br /&gt;
* ark_vocabulary_relation - Reference table for term relation types, i.e.broader/narrower&lt;br /&gt;
* ark_vocabulary_type - Reference table for vocabulary types, i.e. list, taxonomy, etc&lt;br /&gt;
&lt;br /&gt;
== Classes ==&lt;br /&gt;
&lt;br /&gt;
*ARK/Vocabulary/Vocabulary - Utility class for static access methods&lt;br /&gt;
&lt;br /&gt;
*ARK/Vocabulary/Concept - Abstract base class for Vocabulary Concept, stored in ark_vocabulary&lt;br /&gt;
**ARK/Vocabulary/TermList - Subclass of Vocabulary for list type vocabularies&lt;br /&gt;
**ARK/Vocabulary/Ring - Subclass of Vocabulary for ring type vocabularies&lt;br /&gt;
**ARK/Vocabulary/Taxonomy - Subclass of Vocabulary for taxonomy type vocabularies&lt;br /&gt;
**ARK/Vocabulary/Thesaurus - Subclass of Vocabulary for thesaurus type vocabularies&lt;br /&gt;
&lt;br /&gt;
*ARK/Vocabulary/Term&lt;br /&gt;
*ARK/Vocabulary/Parameter&lt;br /&gt;
*ARK/Vocabulary/Related&lt;br /&gt;
&lt;br /&gt;
*ARK/Vocabulary/Type&lt;br /&gt;
*ARK/Vocabulary/Relation&lt;br /&gt;
&lt;br /&gt;
== Classes ==&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Avalon2</id>
		<title>ARK2/Avalon2</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Avalon2"/>
				<updated>2016-12-15T21:09:38Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Avalon 2 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Avalon 2 =&lt;br /&gt;
&lt;br /&gt;
Avalon is the project management ARK for LP Archaeology. Avalon triggers the creation of a job folder on the local server, which is then synced to the other servers. If a GIS is required, then standard shapefiles are created in the job folder, and all the GIS data is stored in the job folder. Any Project that also requires a site recording ARK then sets that up separately.&lt;br /&gt;
&lt;br /&gt;
A number of issues exist here:&lt;br /&gt;
* File syncing is slow, resource intensive, and error prone&lt;br /&gt;
* GIS data is heavily duplicated, wasting space&lt;br /&gt;
* GIS data is fractured, i.e. finding what data we already have requires manual searching of folders, and may lead to the purchase of duplicate data&lt;br /&gt;
* GIS Figures are still too complex to produce and could be automated more.&lt;br /&gt;
* Use of ARK for data recording is time-consuming to set up so often not done for small jobs.&lt;br /&gt;
* Many jobs are deemed too small to bother entering the data in ARK, this makes querying our data corpus or automating many report writing functions impossible&lt;br /&gt;
* Versioning files, submitting them for review, and checking they have been is a manual process and open to abuse&lt;br /&gt;
&lt;br /&gt;
ARK 2 provides several new features that can alleviate this:&lt;br /&gt;
* File management and file versioning support&lt;br /&gt;
* Workflow management&lt;br /&gt;
* Easy automated creation of new ARK instances&lt;br /&gt;
* Multiple sites and schemas in a single ARK install&lt;br /&gt;
* Support for running on PostgreSQL, and consequently support for PostGIS&lt;br /&gt;
&lt;br /&gt;
The proposal for Avalon 2 is as follows:&lt;br /&gt;
* A single ARK install running both Avalon and all site ARKs, either as a single instance or two instances sharing a single user database.&lt;br /&gt;
* The database will run on PostgreSQL, providing both the Avalon/ARK data server and a PostGIS database in a single install.&lt;br /&gt;
* The GIS database will manage as many shared vector and raster resources as possible, as well as the GIS for each Project.&lt;br /&gt;
* On creation of a new Project, the PM can choose to create a GIS and an ARK, or trigger this at any time later.&lt;br /&gt;
* All the ARK site data will be stored in a single instance using multiple standard company data schemas, both standardising recording methods and enabling search across all projects.&lt;br /&gt;
* A connection to Harvest will be created using their API, allowing for combined reporting, and automated creation of projects and allocation of staff.&lt;br /&gt;
* Later Avalon could seek to replicate the required features of Harvest itself.&lt;br /&gt;
&lt;br /&gt;
* Integrated Wiki to replace Mediawiki&lt;br /&gt;
&lt;br /&gt;
* https://github.com/charlesroper/OSGB_Grids&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/UX</id>
		<title>ARK2/UX</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/UX"/>
				<updated>2016-12-12T09:43:24Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Map View */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= UX =&lt;br /&gt;
&lt;br /&gt;
ARK, the Archaeological Recording Kit, is a web application for recording, analysing, and publishing archaeology data. ARK provides a very flexible platform akin to a CMS to allow different clients to configure their website to meet their data recording needs. This flexibility applies to the UX as well as the data schema.&lt;br /&gt;
&lt;br /&gt;
ARK 1 is largely custom code that is showing its age and hard to customise. ARK 2 is a ground-up rewrite to bring ARK into line with modern web technology including a REST API, while also making it easier to configure and maintain. ARK 2 will also enable ARK to be offered as a hosted service.&lt;br /&gt;
&lt;br /&gt;
While clients will be able to build custom web or app interfaces using whatever technology they prefer, most will choose to use and possibly adapt the default Bootstrap/Twig web interface which needs to be both feature-complete and flexible, albeit at the cost of some efficiency. They are also likely to use variations on the standard &amp;#039;Site Recording&amp;#039; data schema with &amp;#039;Sites&amp;#039; or &amp;#039;Projects&amp;#039; at the top level, as will the hosted ARK-as-a-service, so the default UX should be weighted towards that scenario.&lt;br /&gt;
&lt;br /&gt;
Note that &amp;#039;Site&amp;#039; is a term often used in archaeology to define a geographic area of interest or excavation, to avoid confusion we will try refer to &amp;#039;An ARK Website&amp;#039; and &amp;#039;An Archaeological Site&amp;#039; wherever possible.&lt;br /&gt;
&lt;br /&gt;
== Data Schema ==&lt;br /&gt;
&lt;br /&gt;
The ARK data schema is configurable using the concept of Modules. A Module can be thought of as an Object in the Object-Oriented model, a Resource in the REST model, or a table in the Relational model. A Module has a set of data properties and relationships to other Modules. An instance of a Module is known as an Item. The schema is completely configurable by the website admin, but a number of pre-defined configurations for industry-standard recording schemas are available to use.&lt;br /&gt;
&lt;br /&gt;
=== Field Recording ===&lt;br /&gt;
&lt;br /&gt;
The primary use for ARK is recording archaeological data in the field, analysing the data in the office, and publishing the data online. It reflects the paper-based field recording systems originally used in Archaeology, being based around Registers and Forms, and is designed to replace part or all of a paper-based system. Field staff are often freelance or on short-term contracts, so the UX needs to be familiar enough for them to adapt to quickly. The UX needs to balance the familiarity of the users with the paper-based systems with the improved workflows that can come from an online system. The UX should also be adaptable to other field data recording scenarios both in archaeology, and also other potential uses such as conservation.&lt;br /&gt;
&lt;br /&gt;
[[File:ExampleRegisterSmall.png]]&lt;br /&gt;
[[File:ExampleSheetSmall.png]]&lt;br /&gt;
&lt;br /&gt;
The main recording system used is called Single Context Recording in which various objects and concepts found on an archaeological site are recorded.&lt;br /&gt;
&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Context_(archaeology) Context] - A basic unit of archaeological recording, such as a layer of soil or a wall.&lt;br /&gt;
* Photo - A photo that can be linked to the objects seen in the Photo, such as Context, Timber, Find, etc.&lt;br /&gt;
* Plan - A drawn plan of an object, usually a Context or Find, which can be linked to those objects.&lt;br /&gt;
* Section - A drawn cross-section of contexts&lt;br /&gt;
* Sample - Part of a Context saved for later scientific analysis in the laboratory.&lt;br /&gt;
* Find - A human made object that is found in a Context, like a pot or a coin.&lt;br /&gt;
* Timber - A piece of timber used in a building or other man-made structure.&lt;br /&gt;
* Subgroup - A collection of Contexts that make up a minor feature or object.&lt;br /&gt;
* Group - A collection of Subgroups that make up a major feature or object.&lt;br /&gt;
&lt;br /&gt;
This could be drawn as:&lt;br /&gt;
&lt;br /&gt;
[[File:MinoriesSchema.png]]&lt;br /&gt;
&lt;br /&gt;
Other archaeological objects can also be added to the model as required.&lt;br /&gt;
&lt;br /&gt;
As staff in the field excavate a site, they initially Register the basic details of contexts and objects using phones or tablets, and can then add more details as required. An alternative use model is to record on paper and later copy into the ARK. Staff in the office then process that data, such as putting the Contexts into Subgroups and Groups, before publishing the results. The results are mostly used internally for writing formal reports, but may also attract wider professional or public interest.&lt;br /&gt;
&lt;br /&gt;
== User Profiles ==&lt;br /&gt;
&lt;br /&gt;
* Anonymous - A member of the general public interested in browsing information about the archaeological site. Primary requirement is rich detail with easy navigation.&lt;br /&gt;
* Field Operative - A member of staff recording and editing data in the field. Primary requirement is speed and simplicity of data entry in challenging conditions (protective gloves, rain, mud, etc), often only using a mobile phone.&lt;br /&gt;
* Field Supervisor - A member of staff supervising other field staff with supervisor-level site functions. Primary requirement is quickly and easily reviewing and editing data.&lt;br /&gt;
* Office Operative - A member of staff in the office processing data. Primary requirement is full-featured but efficient data entry and editing, but also search and navigation.&lt;br /&gt;
* Office Supervisor - A member of staff in the office doing higher level data analysis. Primary requirement is powerful search and navigation functions.&lt;br /&gt;
* Website Admin - An administrator of the ARK website. Primary requirement is basic admin functions, mainly user admin and vocabularies, but sometimes also schema.&lt;br /&gt;
* System Admin - An administrator of the ARK install (Different from Site Admin on multi-site/multi-tenant installs). God.&lt;br /&gt;
&lt;br /&gt;
== Configurable Views ==&lt;br /&gt;
&lt;br /&gt;
Just as the data schema is completely configurable by a website admin, so too are the views of that data. ARK combines a layout grid with content blocks known as Subforms. Each Subform usually contains a layout of data fields from the schema, but can also contain other elements. Subforms are usually used to group fields that are related, or require similar functionality. Different page views of the same Item can be laid out for different purposes, for example the Field Operatives data entry view may differ from the Office Supervisors data analysis view. Where this differs from standard CRUD forms is in the code functionality that can be embedded in a Subform. A different View of an Item can also offer significantly different functionality for that Item.&lt;br /&gt;
&lt;br /&gt;
Item Collection views, such as Table, List, Thumbnail, etc, can also be configured. In ARK 1 the two main variants are currently Register and Search, but ARK 2 will also define a standard List view.&lt;br /&gt;
&lt;br /&gt;
The core UX requirement is to define the relationship and navigation between these core generic pages, rather than the physical layout of the Item fields and Subforms. The current model is not integrated or consistent and leads to considerable confusion for users.&lt;br /&gt;
&lt;br /&gt;
== Generic Pages ==&lt;br /&gt;
&lt;br /&gt;
=== Website Home ===&lt;br /&gt;
&lt;br /&gt;
Landing page for a Website. If private ARK then usually login page. If public ARK then usually some project brochure-ware and links to browse site if anonymous access enabled.&lt;br /&gt;
&lt;br /&gt;
=== User Home ===&lt;br /&gt;
&lt;br /&gt;
Landing page for user after logging in, usually some kind of dashboard, but may be User Profile page.&lt;br /&gt;
&lt;br /&gt;
=== Collection View ===&lt;br /&gt;
&lt;br /&gt;
* List Items by Module&lt;br /&gt;
* View modes: Text, Table, Thumbnails&lt;br /&gt;
* Filter Items by properties in view&lt;br /&gt;
* Select properties to view&lt;br /&gt;
* Paging&lt;br /&gt;
* Export&lt;br /&gt;
* Integrate Advanced Search? (see below)&lt;br /&gt;
&lt;br /&gt;
=== Item View / Edit ===&lt;br /&gt;
&lt;br /&gt;
* View item details&lt;br /&gt;
* Edit Item details&lt;br /&gt;
* Subforms (think Drupal Blocks)&lt;br /&gt;
* Item navigation&lt;br /&gt;
&lt;br /&gt;
=== Map View ===&lt;br /&gt;
&lt;br /&gt;
Spatial data and GIS is core to archaeology, but often in a way that has more in common with CAD than most websites. While some simpler forms of data are recorded, such as find spots or site addresses, most spatial data is a detailed and precise plan of all the contexts in a site drawn to 25mm accuracy. This data needs to be displayed in a way that can help with data analysis, such as how different objects relate to each other, as well as be attractive to a wider public.&lt;br /&gt;
&lt;br /&gt;
OpenLayers is used to display spatial data, both embedded as a subform in an Item View, or on a separate page showing a Collection of Items. Spatial search and interactive editing are also required, but full-blown spatial analysis is done in a proper GIS package that can make calls to the ARK api to obtain the data.&lt;br /&gt;
&lt;br /&gt;
=== Advanced Search ===&lt;br /&gt;
&lt;br /&gt;
Version of Collection View with more advanced search tools, possibly same page with mode switch or hidden panel?&lt;br /&gt;
&lt;br /&gt;
* Cross-module search&lt;br /&gt;
* Set based queries&lt;br /&gt;
* By Module / Type&lt;br /&gt;
* By Property&lt;br /&gt;
* By Actor / Action / Event&lt;br /&gt;
* By Period&lt;br /&gt;
* By Spatial&lt;br /&gt;
* Free Text&lt;br /&gt;
* Save Search Definition&lt;br /&gt;
* Choose from saved Search definitions&lt;br /&gt;
&lt;br /&gt;
== Site Recording Pages ==&lt;br /&gt;
&lt;br /&gt;
=== Register View ===&lt;br /&gt;
&lt;br /&gt;
Short-form add new Item. List view shows most recently registered Items to reflect the traditional paper register.&lt;br /&gt;
&lt;br /&gt;
=== Site/Project Dashboard ===&lt;br /&gt;
&lt;br /&gt;
Dashboard for a Site/Project&lt;br /&gt;
&lt;br /&gt;
== User Security ==&lt;br /&gt;
&lt;br /&gt;
ARK2 will provide a very flexible User Security system using an RBAC model. Website admins will have a choice of registration and authentication options and the UX/UI should adapt to these as configured. Login should work as either a page or a pop-up.&lt;br /&gt;
&lt;br /&gt;
* Register (by self or admin)&lt;br /&gt;
* Login&lt;br /&gt;
* Optional Captcha&lt;br /&gt;
* Optional OAuth2 (Facebook, Google, etc)&lt;br /&gt;
* Request password reset&lt;br /&gt;
* Profile&lt;br /&gt;
** Personal details&lt;br /&gt;
** Contact details&lt;br /&gt;
** Security details&lt;br /&gt;
&lt;br /&gt;
== Admin Screens ==&lt;br /&gt;
&lt;br /&gt;
See [[ARK2/Admin|Admin Screens]]. UX required is primarily layout and flow, plus User Admin, Translation and Vocabulary pages.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Admin</id>
		<title>ARK2/Admin</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Admin"/>
				<updated>2016-12-07T10:45:47Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Translation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Admin =&lt;br /&gt;
&lt;br /&gt;
ARK2 offers a stand-alone Admin web interface, allowing an API-only back-end to be configured and maintained. When running the full ARK2 Web frontend, the Admin interface is accessible to admin-level users, but does not &amp;#039;leak&amp;#039; into the standard user interface. It will probably be an option on the User dropdown menu, or directly at example.com/admin.&lt;br /&gt;
&lt;br /&gt;
Because ARK2 supports multi-tenant/multi-site modes, the Admin interface has two broad divisions between Website Admin and System Admin, i.e. managing an ARK instance and managing the ARK install. How the UX of multi-site / multi-tenant will work is still to be figured out.&lt;br /&gt;
&lt;br /&gt;
The Admin interface should reflect the theme of the main website (colours, fonts, etc), but not otherwise change in layout or function so admin is a consistent experience across sites and installs. Many of the pages will be standard CRUD list views for which we will need a master template, but some pages will benefit from custom UX.&lt;br /&gt;
&lt;br /&gt;
[https://startbootstrap.com/template-overviews/sb-admin-2/ SBAdmin] and [https://almsaeedstudio.com/ AdminLTE] were early options assessed. The Drupal Admin panel is another example.&lt;br /&gt;
&lt;br /&gt;
== Profiles ==&lt;br /&gt;
&lt;br /&gt;
The options available in the admin frontend will vary depending on the admin level of the user.&lt;br /&gt;
&lt;br /&gt;
* Hosted Website Admin - Basic website details, add users, but not able to change schema, roles, etc.&lt;br /&gt;
* Website Admin - Full website admin for a single website, including schema&lt;br /&gt;
* Multisite Admin - Full website admin for multiple websites?&lt;br /&gt;
* System Admin - Installation admin&lt;br /&gt;
&lt;br /&gt;
== Menu ==&lt;br /&gt;
&lt;br /&gt;
Rough menu or grouping structure, not all features required in 2.0.&lt;br /&gt;
&lt;br /&gt;
 Admin&lt;br /&gt;
 - Website&lt;br /&gt;
 - Content&lt;br /&gt;
 - Structure&lt;br /&gt;
 - Security&lt;br /&gt;
 - System&lt;br /&gt;
&lt;br /&gt;
Initial view should be some kind of dashboard summary view of the install, alternatively the Website initial page.&lt;br /&gt;
&lt;br /&gt;
== Website ==&lt;br /&gt;
&lt;br /&gt;
Administration of an ARK Website (Instance? Project?).&lt;br /&gt;
&lt;br /&gt;
 - Website&lt;br /&gt;
 -- Details&lt;br /&gt;
 -- Theme&lt;br /&gt;
 -- Region&lt;br /&gt;
 -- Alerts&lt;br /&gt;
&lt;br /&gt;
Initial view should be some kind of dashboard summary view of the websites managed by the user with ability to switch websites, alternatively the Website Details.&lt;br /&gt;
&lt;br /&gt;
=== Details ===&lt;br /&gt;
&lt;br /&gt;
General website details:&lt;br /&gt;
&lt;br /&gt;
* Name&lt;br /&gt;
* Short description&lt;br /&gt;
* Logo&lt;br /&gt;
* Favicon&lt;br /&gt;
* Contact Name / Email&lt;br /&gt;
* Copyright&lt;br /&gt;
* Content license: CC, etc&lt;br /&gt;
&lt;br /&gt;
=== Theme ===&lt;br /&gt;
&lt;br /&gt;
Web frontend details:&lt;br /&gt;
&lt;br /&gt;
* Frontend (API, Admin, Flat, Web) [Not available for Hosted ARK Admin]&lt;br /&gt;
* Skin (Colour, etc)&lt;br /&gt;
&lt;br /&gt;
=== Region ===&lt;br /&gt;
&lt;br /&gt;
Regional and language settings:&lt;br /&gt;
&lt;br /&gt;
* Locale&lt;br /&gt;
* Time Zone&lt;br /&gt;
* Multilingual site&lt;br /&gt;
* Default language&lt;br /&gt;
* Supported Languages&lt;br /&gt;
&lt;br /&gt;
=== Alerts ===&lt;br /&gt;
&lt;br /&gt;
Alerts or Flashes are notifications displayed to users, i.e. [http://getbootstrap.com/components/#alerts Bootstrap Alerts]. Site or System Admins can schedule alerts to be show at a system, site, role, or user level, and configure them to be dismissible and/or persistent. The Admin frontend will provide a page to administer these Alerts. The Alerts Admin will appear at both Site and System levels with the appropriate options.&lt;br /&gt;
&lt;br /&gt;
== Content Admin ==&lt;br /&gt;
&lt;br /&gt;
 - Content&lt;br /&gt;
 -- Static Page&lt;br /&gt;
 -- File&lt;br /&gt;
 -- Image&lt;br /&gt;
 -- Translation&lt;br /&gt;
 -- Import&lt;br /&gt;
 -- Upload&lt;br /&gt;
&lt;br /&gt;
=== Static Page ===&lt;br /&gt;
&lt;br /&gt;
Static Page administration. Ability to add or edit a static html page at a given URL.&lt;br /&gt;
&lt;br /&gt;
=== File ===&lt;br /&gt;
&lt;br /&gt;
File options and file management. Allowed types, sizes, etc. Flysystem config. Basic CRUD list with admin options. Bulk upload option?&lt;br /&gt;
&lt;br /&gt;
=== Image ===&lt;br /&gt;
&lt;br /&gt;
Image options management (files themselves included in File tab). Toolkit options, thumbnail profiles, regenerate thumbnails, etc.&lt;br /&gt;
&lt;br /&gt;
=== Translation ===&lt;br /&gt;
&lt;br /&gt;
ARK2 uses [http://symfony.com/doc/current/translation.html Symfony Translation] for translating both markup and content into multiple languages, including data values such as taxonomy terms. A Site Admin needs to be able to add and maintain translations directly. Advanced features are not required, as specialised websites will be used to maintain the core translation files. A sortable/filterable list view of translation keys and their translations into the site&amp;#039;s supported languages is required. Useful features would including listing keywords that are missing translations for a given language, export al translations to XLIFF file, etc.&lt;br /&gt;
&lt;br /&gt;
A translation has the following fields:&lt;br /&gt;
* Domain - Message group, e.g. Users, Admin, Errors, etc&lt;br /&gt;
* Keyword - The translation key&lt;br /&gt;
* Role - The translation role, e.g. Default, Title, Description, Opposite, etc&lt;br /&gt;
* Language&lt;br /&gt;
* Text - The translation&lt;br /&gt;
* Notes - Notes to help the translator, will default to original English translation if not otherwise set&lt;br /&gt;
&lt;br /&gt;
Note that a Keyword can have multiple Roles in the table, for example keyword &amp;#039;field.location&amp;#039; will have Roles for &amp;#039;default&amp;#039; (the translation to use for any Role not set),  &amp;#039;title&amp;#039; (the Title to show for a field, in title case), &amp;#039;description&amp;#039; ( a short description of the field that can be shown in a help mouseover).&lt;br /&gt;
&lt;br /&gt;
Some possible examples:&lt;br /&gt;
* https://github.com/lexik/LexikTranslationBundle&lt;br /&gt;
* https://github.com/instaclick/TranslationEditorBundle&lt;br /&gt;
* https://www.transifex.com/&lt;br /&gt;
* https://demo.weblate.org/&lt;br /&gt;
&lt;br /&gt;
=== Import ===&lt;br /&gt;
&lt;br /&gt;
Bulk data import functions.&lt;br /&gt;
&lt;br /&gt;
=== Upload ===&lt;br /&gt;
&lt;br /&gt;
Bulk file upload function, or in File section?&lt;br /&gt;
&lt;br /&gt;
== Structure ==&lt;br /&gt;
&lt;br /&gt;
Section to manage the data structures available, i.e. Modules, Schemas, Fields, etc.&lt;br /&gt;
&lt;br /&gt;
Most pages to be developed for v2.1, but Vocabulary may be required for 2.0.&lt;br /&gt;
&lt;br /&gt;
 - Structure&lt;br /&gt;
 -- Vocabulary&lt;br /&gt;
 -- Format&lt;br /&gt;
 -- Schema&lt;br /&gt;
 -- Workflow&lt;br /&gt;
 -- View&lt;br /&gt;
&lt;br /&gt;
=== Vocabulary ===&lt;br /&gt;
&lt;br /&gt;
Page to manage controlled vocabularies (List, Ring, Taxonomy, Thesaurus), including translations (i.e current Aliases). See the [[ARK2/Vocabulary|Vocabulary]] page for more details.&lt;br /&gt;
&lt;br /&gt;
=== Format ===&lt;br /&gt;
&lt;br /&gt;
Page to manage data field formats.&lt;br /&gt;
&lt;br /&gt;
=== Schema ===&lt;br /&gt;
&lt;br /&gt;
Page to manage Module Data Schemas.&lt;br /&gt;
&lt;br /&gt;
=== Workflow ===&lt;br /&gt;
&lt;br /&gt;
Page to manage Workflows.&lt;br /&gt;
&lt;br /&gt;
=== View ===&lt;br /&gt;
&lt;br /&gt;
Page to manage Module View Layouts.&lt;br /&gt;
&lt;br /&gt;
== Security Admin ==&lt;br /&gt;
&lt;br /&gt;
Section to manage the user and security.&lt;br /&gt;
&lt;br /&gt;
Required for 2.0.&lt;br /&gt;
&lt;br /&gt;
See the [[ARK2/Security|Security]] page for more details.&lt;br /&gt;
&lt;br /&gt;
 - Security&lt;br /&gt;
 -- Options&lt;br /&gt;
 -- Users&lt;br /&gt;
 -- Roles&lt;br /&gt;
 -- Permissions&lt;br /&gt;
&lt;br /&gt;
ARK2 implements a Role-Based Access Control system, where Users are assigned Roles, and Roles have Permissions. The usual set of functions will be required for both self-registration and invitation-only models, password resets, and user management.&lt;br /&gt;
&lt;br /&gt;
[http://www.userfrosting.com/ User Frosting] was an early option assessed.&lt;br /&gt;
&lt;br /&gt;
Note that a User Profile page will be available in the main Web frontend, the user view in the Admin frontend should only be focussed on the security admin aspects of the user, but should share a design language with the User Profile.&lt;br /&gt;
&lt;br /&gt;
=== Options ===&lt;br /&gt;
&lt;br /&gt;
Configure security options, such as user registration policy, anonymous users, etc.&lt;br /&gt;
&lt;br /&gt;
=== Users ===&lt;br /&gt;
&lt;br /&gt;
List of users and management tools. Register, approve, reset password, suspend, delete, etc.&lt;br /&gt;
&lt;br /&gt;
=== Roles ===&lt;br /&gt;
&lt;br /&gt;
List of roles and management tools.&lt;br /&gt;
&lt;br /&gt;
=== Permissions ===&lt;br /&gt;
&lt;br /&gt;
List of permissions and management tools.&lt;br /&gt;
&lt;br /&gt;
=== User Registration ===&lt;br /&gt;
&lt;br /&gt;
Register a user, used for both Admin-Register or Self-Register.&lt;br /&gt;
&lt;br /&gt;
=== User Settings ===&lt;br /&gt;
&lt;br /&gt;
The user&amp;#039;s admin-serviced security settings, such as roles, password reset, etc.&lt;br /&gt;
&lt;br /&gt;
=== User Profile ===&lt;br /&gt;
&lt;br /&gt;
The users profile, including self-service security settings, personal details, avatar, notifications, activity stream, social media accounts, etc. Part of the main user facing UX.&lt;br /&gt;
&lt;br /&gt;
== System Admin ==&lt;br /&gt;
&lt;br /&gt;
Section to configure system-level settings.&lt;br /&gt;
&lt;br /&gt;
Only used by Sysadmin level users.&lt;br /&gt;
&lt;br /&gt;
Not required for 2.0, instead sysadmins will use the Sysadmin Console.&lt;br /&gt;
&lt;br /&gt;
Options in the Sysadmin panel will include:&lt;br /&gt;
&lt;br /&gt;
 - System&lt;br /&gt;
 -- Status&lt;br /&gt;
 -- Region&lt;br /&gt;
 -- Alerts&lt;br /&gt;
 -- Messages&lt;br /&gt;
 -- Site Defaults&lt;br /&gt;
 -- Cron&lt;br /&gt;
 -- Logging&lt;br /&gt;
 -- Reports&lt;br /&gt;
 -- Routing&lt;br /&gt;
&lt;br /&gt;
=== Status ===&lt;br /&gt;
&lt;br /&gt;
Install status, maintenance mode / live mode, etc.&lt;br /&gt;
&lt;br /&gt;
=== Region ===&lt;br /&gt;
&lt;br /&gt;
Install-wide default regional and language settings:&lt;br /&gt;
&lt;br /&gt;
* Locale&lt;br /&gt;
* Time Zone&lt;br /&gt;
* Multilingual site&lt;br /&gt;
* Default language&lt;br /&gt;
* Supported Languages&lt;br /&gt;
&lt;br /&gt;
=== Alerts ===&lt;br /&gt;
&lt;br /&gt;
Set install wide alerts, i.e. maintenance announcements.&lt;br /&gt;
&lt;br /&gt;
=== Messages ===&lt;br /&gt;
&lt;br /&gt;
Message maintenance, similar to translations.&lt;br /&gt;
&lt;br /&gt;
=== Site Defaults ===&lt;br /&gt;
&lt;br /&gt;
Default settings for new sites when in multi-site mode.&lt;br /&gt;
&lt;br /&gt;
=== Cron ===&lt;br /&gt;
&lt;br /&gt;
Cron job management.&lt;br /&gt;
&lt;br /&gt;
=== Logging ===&lt;br /&gt;
&lt;br /&gt;
Manage and view logs.&lt;br /&gt;
&lt;br /&gt;
=== Reports ===&lt;br /&gt;
&lt;br /&gt;
Various status reports.&lt;br /&gt;
&lt;br /&gt;
=== Routing ===&lt;br /&gt;
&lt;br /&gt;
Configure routes, api, etc.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Spatial</id>
		<title>ARK2/Spatial</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Spatial"/>
				<updated>2016-11-27T13:52:24Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Design */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Requirements ==&lt;br /&gt;
&lt;br /&gt;
Basic spatial support is required, e.g. storing find points or area bounding boxes, as well as the advanced mapping interface options, such as spatial search and processing. We use the [http://www.opengeospatial.org/standards/sfs OpenGIS standard] as defined by the OGC and implemented by various spatial databases.&lt;br /&gt;
&lt;br /&gt;
Basic back-end support:&lt;br /&gt;
* Lossless storage of standard geometries, including CRS&lt;br /&gt;
* Validate geometries&lt;br /&gt;
* Interchange geometries via API&lt;br /&gt;
&lt;br /&gt;
Advanced back-end support:&lt;br /&gt;
* Spatial search&lt;br /&gt;
* Spatial processing&lt;br /&gt;
* File import/export&lt;br /&gt;
&lt;br /&gt;
== Design ==&lt;br /&gt;
&lt;br /&gt;
The lossless storage and interchange of spatial data is a core function, but cross-database support is poor:&lt;br /&gt;
* MySQL/MariaDB has a native GEOMETRY type, but this is only 2D&lt;br /&gt;
* PostgreSQL and SQLite have 3D support, but only by adding extensions (PostGIS and Spatialite)&lt;br /&gt;
* Adding extensions may be difficult on hosted platforms, or the additional spatial functions provided may not be needed by a site&lt;br /&gt;
&lt;br /&gt;
The lossless storage of geometries in the database therefore needs to use standard datatypes in either WKT or WKB format. The downside to this is that the data cannot then be used for spatial search or processing within the database. If spatial search or processing is required, then the data will need to be duplicated in proper spatial fields.&lt;br /&gt;
&lt;br /&gt;
Again, support for spatial search and processing is uneven:&lt;br /&gt;
* MySQL supports standard SQL spatial functions from 5.6 onwards, and spatial indexes for InnoDB from 5.7.6 onwards&lt;br /&gt;
* MariaDB supports standard SQL spatial functions from 5.5 onwards, and spatial indexes for InnoDB from 10.2.2 onwards&lt;br /&gt;
* Both MySQL and MariaDB support spatial indexes in MyISAM from 5.5 onwards&lt;br /&gt;
* PostgreSQL and SQLite support spatial functions but only by adding extensions (PostGIS and Spatialite)&lt;br /&gt;
&lt;br /&gt;
As spatial search and processing are extended functions, enabling them will require installation on an appropriate platform, however fallbacks will be provided to the extent a platform supports them:&lt;br /&gt;
* On PostGIS and Spatialite the full native facilities will be used on a copy of the data&lt;br /&gt;
* On MySQL between 5.6 and 5.7.6 and on MariaDB, a MyISAM table will be used to store a copy in a GEOMETRY field with a spatial index and processed using the native spatial functions&lt;br /&gt;
* On MySQL 5.5, a MyISAM table will also be used, but the functions will either be the limited set available, or using GEOS if available&lt;br /&gt;
* On PostgreSQL and SQLite if GEOS is available then it will be used on the original data&lt;br /&gt;
* Otherwise spatial search and processing will be unavailable&lt;br /&gt;
* An option is to ship Spatialite with ARK and run it as the spatial engine only&lt;br /&gt;
&lt;br /&gt;
A useful side-effect of this strategy is that the spatial search table could be stored on a separate database server, such as a local Spatialite instance or a shared PostGIS server.&lt;br /&gt;
&lt;br /&gt;
Idea to investigate: if using Redis for cache, then has geospatial cache which can be used for spatial search in bounding box or radius.&lt;br /&gt;
&lt;br /&gt;
== Implementation ==&lt;br /&gt;
&lt;br /&gt;
A number of OpenGIS compliant libraries do exist, but none that meet our full requirements:&lt;br /&gt;
* https://github.com/brick/geo - OpenGIS geometry library, requires GEOS, MySQL, PostGIS, or Spatialite. Has WKT and WKB support, but no file import/export support. Provides DBAL data types. Current but low-level maintenance, but not widely used.&lt;br /&gt;
* https://github.com/phayes/geoPHP - OpenGIS geometry library, internal routines but supports GEOS, lots of basic file import/export 2D only, effectively unmaintained but widely used, would need to fork and do major cleanups.&lt;br /&gt;
* https://github.com/creof/doctrine2-spatial - Modern, currently maintained, Doctrine ORM integration, but MySQL and PostGIS only. Could write backends for spatialite and GEOS?&lt;br /&gt;
* https://github.com/symm/gisconverter (and several others) - Various file importer libraries with partial OpenGIS class support but no functions.&lt;br /&gt;
&lt;br /&gt;
Likely solution will be to use Brick and fork various file libraries to work with it. May also fork geoPHP to work as a Brick backend? Alternative is major refactor of geoPHP, or piecemeal integration of each converter library.&lt;br /&gt;
&lt;br /&gt;
Front-end support will continue to use OpenLayers.&lt;br /&gt;
&lt;br /&gt;
== Platform Support ==&lt;br /&gt;
&lt;br /&gt;
* MySql &amp;gt;= 5.5 supports 2D geometry &amp;amp; MyISAM spatial index, &amp;gt;= 5.6 spatial processing, &amp;gt;= 5.7.6 for InnoDB spatial indexing&lt;br /&gt;
* MariaDB &amp;gt;= 5.5 supports 2D? geometry and spatial processing natively, spatial index in InnoDB &amp;gt;= 10.2.2 https://mariadb.com/kb/en/mysqlmariadb-spatial-support-matrix/&lt;br /&gt;
* PostGIS native 3D geometry, spatial index, and spatial processing&lt;br /&gt;
* Spatialite native 3D geometry, spatial index, and spatial processing&lt;br /&gt;
* Postgresql no support, fake using WKT storage&lt;br /&gt;
* SQLite no support, fake using WKT storage&lt;br /&gt;
* GEOS provides spatial processing&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Files</id>
		<title>ARK2/Files</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Files"/>
				<updated>2016-11-16T11:20:51Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* File Management */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= File Management =&lt;br /&gt;
&lt;br /&gt;
File and Media management have seen major changes in ARK2, with a more flexible system implemented.&lt;br /&gt;
&lt;br /&gt;
* Files are now a core Module instead of a dataclass and look-up table, allowing for flexible metadata based on file type, and using files as either data properties or relationships.&lt;br /&gt;
* The file system is abstracted using [http://flysystem.thephpleague.com/ FlySystem] allowing files to be transparently saved locally or to cloud providers.&lt;br /&gt;
* File versioning is supported.&lt;br /&gt;
* Image manipulation is abstracted using [http://glide.thephpleague.com/ Glide] and [https://github.com/avalanche123/Imagine Imagine] which supports ImageMagick or GD.&lt;br /&gt;
* Thumbnails are stored separately from the master files to make backups, archiving, and regeneration easier&lt;br /&gt;
* Multiple thumbnail profiles can be configured&lt;br /&gt;
* Thumbnails will be generated asynchronously, so can either be queued for batch processing, delayed until a suitable time window, or only generated when needed.&lt;br /&gt;
&lt;br /&gt;
The Media Types and File Types supported are configurable, with the [https://www.iana.org/assignments/media-types/media-types.xhtml IANA standard types] provided by default:&lt;br /&gt;
* Image (jpg, png, etc)&lt;br /&gt;
* Audio (mp3, etc)&lt;br /&gt;
* Video (mkv, etc)&lt;br /&gt;
* Text (txt, etc)&lt;br /&gt;
* Application (pdf, odt, ods, etc)&lt;br /&gt;
&lt;br /&gt;
In multi-tenant mode, the files for each ARK instance are stored separately under the &amp;#039;sites&amp;#039; folder, e.g. &amp;#039;sites/mysite/files&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
The directory structure for each instance is as follows:&lt;br /&gt;
&lt;br /&gt;
 - files&lt;br /&gt;
   |- download&lt;br /&gt;
      |- &amp;lt;user&amp;gt;&lt;br /&gt;
   |- upload&lt;br /&gt;
      |- &amp;lt;user&amp;gt;&lt;br /&gt;
   |- tmp&lt;br /&gt;
      |- &amp;lt;user&amp;gt;&lt;br /&gt;
   |- data&lt;br /&gt;
      |- &amp;lt;mediatype&amp;gt;&lt;br /&gt;
         |- &amp;lt;tokens&amp;gt;&lt;br /&gt;
   |- cache&lt;br /&gt;
      |- &amp;lt;profile&amp;gt;&lt;br /&gt;
         |- &amp;lt;mediatype&amp;gt;&lt;br /&gt;
             |- &amp;lt;tokens&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where the &amp;lt;mediatype&amp;gt; is as defined in the configuration, and the &amp;lt;token&amp;gt; is a configurable token to split the folders into manageable sizes. By default the &amp;lt;token&amp;gt; will be split by file id in groups of 1000, so subfolders for 0, 1000, 2000, 3000, etc.&lt;br /&gt;
&lt;br /&gt;
The individual file names will be in a standard format. Flysystem abstracts folders and file names as a relative path, which will take the form:&lt;br /&gt;
 files/data/&amp;lt;mediatype&amp;gt;/&amp;lt;token&amp;gt;/&amp;lt;id&amp;gt;.&amp;lt;revision&amp;gt;.&amp;lt;suffix&amp;gt;&lt;br /&gt;
 files/cache/&amp;lt;profile&amp;gt;/&amp;lt;mediatype&amp;gt;/&amp;lt;token&amp;gt;/&amp;lt;id&amp;gt;.&amp;lt;revision&amp;gt;.&amp;lt;suffix&amp;gt;&lt;br /&gt;
&lt;br /&gt;
There will be no direct file or image links, all files are considered private and requests to the mapped URL will be security checked. The mapped URL forms will be:&lt;br /&gt;
 files/&amp;lt;id&amp;gt;/&amp;lt;name&amp;gt;&lt;br /&gt;
 files/&amp;lt;id&amp;gt;/&amp;lt;basename&amp;gt;_&amp;lt;profile&amp;gt;.&amp;lt;suffix&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A custom Flysystem manager is provided that allows different filesystems to be transparently mounted at different points in the file path. For example, the root files/ path is mounted locally, but files/data/ is mounted on Amazon S3.&lt;br /&gt;
&lt;br /&gt;
== Metadata ==&lt;br /&gt;
&lt;br /&gt;
Full metadata is supported in line with Dublin Core.&lt;br /&gt;
&lt;br /&gt;
== Versions ==&lt;br /&gt;
&lt;br /&gt;
== Design Work ==&lt;br /&gt;
&lt;br /&gt;
* Data downloads / exports&lt;br /&gt;
* Documentation files&lt;br /&gt;
* Temp files with expiry&lt;br /&gt;
* Mapping files&lt;br /&gt;
&lt;br /&gt;
Very similar to http://documentation.concrete5.org/developers/working-with-files-and-the-file-manager/overview&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Branding</id>
		<title>ARK2/Branding</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Branding"/>
				<updated>2016-11-14T13:41:02Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Branding / Community =&lt;br /&gt;
&lt;br /&gt;
Two potential issues suggest an evolution of the ARK brand is required&lt;br /&gt;
* Building a development and support community may be easier if ARK is branded as a stand-alone project, rather than seen as owned/controlled by LP Archaeology&lt;br /&gt;
* Extending use of ARK and Hosted ARK to areas outside archaeology may be held back by emphasising the archaeology aspect in the branding&lt;br /&gt;
&lt;br /&gt;
Branding as something like &amp;#039;The ARK Project, sponsored by LP Archaeology&amp;#039;, and coining a bacronym like &amp;#039;ARK Recording Kit&amp;#039; might solve these issues.&lt;br /&gt;
&lt;br /&gt;
The Hosted ARK would need a separate identity to the development project to keep the Open Source / Commercial split clear. A simple .com vs .org difference is probably not clear enough. Examples include:&lt;br /&gt;
* Salesforce.com vs Force.com&lt;br /&gt;
* Mediawiki vs Wikia&lt;br /&gt;
* Wordpress .com vs .org&lt;br /&gt;
&lt;br /&gt;
Branding would thus consist of three parts:&lt;br /&gt;
* The project&lt;br /&gt;
* The products&lt;br /&gt;
* The service&lt;br /&gt;
&lt;br /&gt;
The branding would need to be distinctive but consistent to make it clear they are part of a cohesive whole.&lt;br /&gt;
&lt;br /&gt;
Words with Ark / Arc in them (but not arch) for possible project or theme names:&lt;br /&gt;
* Archive / ARKhive&lt;br /&gt;
* Arctic (very white/light theme?)&lt;br /&gt;
* Arcadia&lt;br /&gt;
* [https://en.wikipedia.org/wiki/Arkose Arkose] (type of sediment)&lt;br /&gt;
* Arkaeology (available in .com, .org, .net!)&lt;br /&gt;
* Arcade&lt;br /&gt;
* Archaic / Arcane / Arcanum / Arcana (more apt for ARK v1 ;-)&lt;br /&gt;
* Arcuate / Arcuated (Arc/bow shaped)&lt;br /&gt;
* Architrave&lt;br /&gt;
* Architect&lt;br /&gt;
* Archipeligo&lt;br /&gt;
* Archosaur&lt;br /&gt;
* Arktivity...&lt;br /&gt;
&lt;br /&gt;
Possible ARK Project / Community names:&lt;br /&gt;
* ARKadia&lt;br /&gt;
* ARKaeology&lt;br /&gt;
* ARKforge&lt;br /&gt;
* ARKhitect&lt;br /&gt;
* ARKhive&lt;br /&gt;
* ARKhub&lt;br /&gt;
* ARKproject (not available on github)&lt;br /&gt;
* ProjectARK&lt;br /&gt;
* BuildARK&lt;br /&gt;
* Project Indiana&lt;br /&gt;
* Hangar 51&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Design</id>
		<title>ARK2/Design</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Design"/>
				<updated>2016-11-14T13:02:50Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Spatial */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Design =&lt;br /&gt;
&lt;br /&gt;
High level design decisions for ARK2.&lt;br /&gt;
&lt;br /&gt;
== Supported Platforms ==&lt;br /&gt;
&lt;br /&gt;
ARK2 will be built using modern PHP standards to support multiple Operating Systems and Database Systems. ARK will only actively support platforms that are actively supported by their maintainers. ARK may work on earlier versions but this is not guaranteed.&lt;br /&gt;
&lt;br /&gt;
For more details see the [[ARK2/Technical|Technical Details]] page.&lt;br /&gt;
&lt;br /&gt;
== Framework ==&lt;br /&gt;
&lt;br /&gt;
ARK2 implements a new RESTful Request/Route/Response skeleton using a Front Controller model and token-based security, based on an external micro-framework and components adhering to the PSR standards and managed via Composer. This will reduce the amount of code maintained internally, update the code-base to modern web-app design principals, and provide a degree of future-proofing by allowing switching of components.&lt;br /&gt;
&lt;br /&gt;
The [http://silex.sensiolabs.org/ Silex] micro-framework and [http://symfony.com/ Symphony] components have been selected due to their high quality, long support history, and wide use and support&lt;br /&gt;
&lt;br /&gt;
For more details see the [[ARK2/Technical|Technical Details]] page.&lt;br /&gt;
&lt;br /&gt;
== Database Abstraction ==&lt;br /&gt;
&lt;br /&gt;
ARK2 will support the use of MySQL, PostgreSQL or SQLite as the database by using the [http://doctrine-orm.readthedocs.io/ Doctrine ORM and DBAL] database abstraction layer.&lt;br /&gt;
&lt;br /&gt;
More details can be found on the [[ARK2/Database]] page.&lt;br /&gt;
&lt;br /&gt;
== Security ==&lt;br /&gt;
&lt;br /&gt;
ARK2 will require a new security solution, This solution will be token based, support username/password and OAuth2 authentication, and use Role-Based Access Control for authorization. HTTPS will be required using Let&amp;#039;s Encrypt as the CA..&lt;br /&gt;
&lt;br /&gt;
For more details, see the [[ARK2/Security|Security]] page.&lt;br /&gt;
&lt;br /&gt;
== REST / HATEOAS / Hypermedia ==&lt;br /&gt;
&lt;br /&gt;
An evolution of the ARK data model and API to try realise the [http://ark.lparchaeology.com/hypertext/ full ARK vision] will be based arround the Hypermedia concepts of [https://en.wikipedia.org/wiki/Representational_state_transfer REST] and [https://en.wikipedia.org/wiki/HATEOAS HATEOAS] as developed by Roy Fielding in his doctoral thesis in 2000. These concepts include resources, relationships, state, and discoverability, and are closely related to the Semantic Web. ARK modules will evolve to represent Resources that can be linked in together in the current flat relationship structure, or organised into configurable hierarchies such as the default Site/Module/Item mostly used by ARK instances. These concepts will be most easily exposed through a RESTful API.&lt;br /&gt;
&lt;br /&gt;
For more details see the [[ARK2/API|API]] page.&lt;br /&gt;
&lt;br /&gt;
== Frontend ==&lt;br /&gt;
&lt;br /&gt;
The frontend will be migrated to [http://getbootstrap.com/ Bootstrap], [https://jquery.com/ jQuery], and [http://twig.sensiolabs.org/ Twig], the most popular and well-supported frontend ui component and template systems. This will allow for easier customisation of ARK&amp;#039;s appearance by third parties.&lt;br /&gt;
&lt;br /&gt;
For more details, see the [[ARK2/Frontend|Frontend]] page.&lt;br /&gt;
&lt;br /&gt;
== Migration ==&lt;br /&gt;
&lt;br /&gt;
A migration process from ARK 1 to ARK 2 will be provided.&lt;br /&gt;
&lt;br /&gt;
Data migration. Existing tables will need to change from MyISAM to InnoDB. Change in place carries a degree of risk of data loss if the migration fails part way. Attempting to restart failed migrations is also prone to error. To protect users data, a new database will be created with new tables and the data copied across. Should migration fail users will easily be able to roll back to their old install, or keep retrying the migration until it does succeed. In effect the ARK init script will be run, followed by the migration script.&lt;br /&gt;
&lt;br /&gt;
User migration. Users will be migrated from LiveUser to the new RBAC system. This will require a compatible default user config.&lt;br /&gt;
&lt;br /&gt;
Config migration. A config migration script will be provided, but may require adapting for individual ARKs.&lt;br /&gt;
&lt;br /&gt;
== Sysadmin Console ==&lt;br /&gt;
&lt;br /&gt;
An sysadmin console will be provided for use on the command line. This will provide a number of tools:&lt;br /&gt;
* Database administration, such as creation, migration, backup, etc&lt;br /&gt;
* MultiArk installs&lt;br /&gt;
* ARK wide alerts&lt;br /&gt;
* Maintenance mode (immediate and schedule)&lt;br /&gt;
* Upgrade tools&lt;br /&gt;
* etc&lt;br /&gt;
&lt;br /&gt;
Equivalents for some of these functions will be provided in an ARK Sysadmin panel (separate to the ARK Admin panel):&lt;br /&gt;
* ARK wide alerts&lt;br /&gt;
* Maintenance mode (immediate and schedule)&lt;br /&gt;
* etc&lt;br /&gt;
&lt;br /&gt;
== Translations / Localisation ==&lt;br /&gt;
&lt;br /&gt;
A key to providing Ark-As-A-Service will be translating the user interface and schemas into as many languages as possible to maximise the potential user base. ARK1 does not have the tools to make this process easy to perform or manage, and it would be a waste of resources to build them. It is recommended to use one of the existing online open-source translation projects to crowd-source the translations. This will allow interested parties and potential clients to translate ARK for themselves and to grow a local community to support ARK in their country.&lt;br /&gt;
&lt;br /&gt;
Changes will be made to the translation process to bring ARK into line with industry best practices and tooling, allowing for common features such as correct plural forms. This will be based on the Symfony Translation componant.&lt;br /&gt;
&lt;br /&gt;
More details can be found on the [[ARK2/Localization]] page.&lt;br /&gt;
&lt;br /&gt;
== Action Logging / Activity Streams / Gamification ==&lt;br /&gt;
&lt;br /&gt;
All user actions and events in ARK will be logged, enabling an standard Activity Stream at user level that can support gamification. The actual gamification is considered outside of the scope of core ARK2. Some inspiration for the implementation can be taken from Event Sourcing, but  a full implementation will not be attempted.&lt;br /&gt;
&lt;br /&gt;
* http://martinfowler.com/eaaDev/EventSourcing.html&lt;br /&gt;
* http://activitystrea.ms/&lt;br /&gt;
* https://www.w3.org/TR/activitystreams-core/&lt;br /&gt;
* https://github.com/barnabywalters/php-activitystreams&lt;br /&gt;
* https://github.com/redpanda/ActivityStreams&lt;br /&gt;
* http://jwage.com/post/54480997504/building-activity-streams&lt;br /&gt;
* https://dev.playlyfe.com/guides/getting-started.html&lt;br /&gt;
&lt;br /&gt;
== Command Bus Architecture / Application Services ==&lt;br /&gt;
&lt;br /&gt;
A Command Bus / Event Bus architecture will be implemented to support execution or queuing of synchronous and asynchronous Commands and Events. Console Commands will be wrappers around Commands that parse input from the command line.&lt;br /&gt;
&lt;br /&gt;
* http://php-and-symfony.matthiasnoback.nl/2015/01/a-wave-of-command-buses/&lt;br /&gt;
* https://github.com/SimpleBus/&lt;br /&gt;
* http://tactician.thephpleague.com/&lt;br /&gt;
* http://culttt.com/2014/11/10/creating-using-command-bus/&lt;br /&gt;
&lt;br /&gt;
== Workflow Management ==&lt;br /&gt;
&lt;br /&gt;
Stretch goal. Needed for Avalon. Packages exist to define workflows using state machines.&lt;br /&gt;
&lt;br /&gt;
Possible workflow scenarios:&lt;br /&gt;
* Post-ex&lt;br /&gt;
* Sample taking&lt;br /&gt;
* Avalon jobs and documents&lt;br /&gt;
* Data checking&lt;br /&gt;
&lt;br /&gt;
== Document Management ==&lt;br /&gt;
&lt;br /&gt;
Stretch goal. Needed for Avalon. Management of documents and versions a la Sharepoint. Try use CMIS standard as used in LibreOffice app, or WOPI used by LibreOffice online.&lt;br /&gt;
&lt;br /&gt;
* https://www.alfresco.com/cmis&lt;br /&gt;
* https://packagist.org/packages/dkd/php-cmis&lt;br /&gt;
* http://wopi.readthedocs.io/projects/wopirest/en/latest/&lt;br /&gt;
* https://kolabian.wordpress.com/2016/11/16/collaborative-editing-with-collabora-online-in-kolab/&lt;br /&gt;
* https://www.collaboraoffice.com/code/&lt;br /&gt;
* WebODF?&lt;br /&gt;
&lt;br /&gt;
== CMS / Blog / Project Websites ==&lt;br /&gt;
&lt;br /&gt;
Either provide an OoB Wordpress integration and host client websites, or add features to ARK to provide the basic project website features (home page, blog, contact us, calendar).&lt;br /&gt;
&lt;br /&gt;
* https://github.com/bolt/bolt CMS built using Silex/Symfony&lt;br /&gt;
&lt;br /&gt;
== Errors ==&lt;br /&gt;
&lt;br /&gt;
Standardised error codes will be used, based on the JSON API standard format. Error codes will be stored in a database table and exported via the API, with actual error messages translated via the standard methods, with detailed debug/help available on the ARK wiki via standardised links. Fatal errors will be thrown as exceptions, with the Controller responsible for catching the error and reporting it in the appropriate manner, i.e. via web or api. Non-fatal errors such as validation errors can be batched before return. While numeric error codes are convenient, they make code hard to read and debugging tracebacks harder, so all error conditions should be explicitly commented in the code, and error codes should be as unique as possible..&lt;br /&gt;
&lt;br /&gt;
== Matrix / Graph ==&lt;br /&gt;
&lt;br /&gt;
PHP:&lt;br /&gt;
* https://github.com/clue/graph&lt;br /&gt;
* https://github.com/graphp/algorithms&lt;br /&gt;
* https://github.com/cpettitt/graphlib/wiki/API-Reference&lt;br /&gt;
&lt;br /&gt;
== Spatial ==&lt;br /&gt;
&lt;br /&gt;
Basic spatial support is required, e.g. storing find points or area bounding boxes, as well as the advanced mapping interface options, such as displaying spatial layers, spatial search, etc. See [[ARK2/Spatial|the Spatial page]] for more details.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Model</id>
		<title>ARK2/Model</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Model"/>
				<updated>2016-10-30T15:14:56Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: Replaced content with &amp;quot;= Model =&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Model =&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Architecture</id>
		<title>ARK2/Architecture</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Architecture"/>
				<updated>2016-10-30T14:57:47Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Architecture */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Architecture =&lt;br /&gt;
&lt;br /&gt;
ARK2 has been built to modern web standards using the latest Object-Oriented PHP development methodologies. This includes using widely supported frameworks and components in a Front-controller architecture.&lt;br /&gt;
&lt;br /&gt;
== Frameworks and Components ==&lt;br /&gt;
&lt;br /&gt;
ARK2 is built on the Symfony components using the Silex Micro-Framework to manage the services and routing.&lt;br /&gt;
&lt;br /&gt;
=== Front-Controller ===&lt;br /&gt;
&lt;br /&gt;
Single page, mod-rewrite, run application,builds and renders requested page.&lt;br /&gt;
&lt;br /&gt;
=== Container ===&lt;br /&gt;
&lt;br /&gt;
Why container.&lt;br /&gt;
&lt;br /&gt;
Using http://pimple.sensiolabs.org/&lt;br /&gt;
&lt;br /&gt;
Dependency Injection, etc http://php-di.org/doc/understanding-di.html&lt;br /&gt;
&lt;br /&gt;
=== Router ===&lt;br /&gt;
&lt;br /&gt;
Maps url requested to list of url patterns, then dispatches request to Controller that can fulfil that request.&lt;br /&gt;
&lt;br /&gt;
=== Controllers ===&lt;br /&gt;
&lt;br /&gt;
=== Model ===&lt;br /&gt;
&lt;br /&gt;
=== View ===&lt;br /&gt;
&lt;br /&gt;
=== Object-Relational Mapping (ORM) ===&lt;br /&gt;
&lt;br /&gt;
=== Database Abstraction ===&lt;br /&gt;
&lt;br /&gt;
== Multi-Tenancy / Multi-Site / Multi-Config ==&lt;br /&gt;
&lt;br /&gt;
A number of architectural issues surround Multi-Tenancy, Multi-Site and Multi-Config in an ARK instance. These primarily affect how a hosted ARK service will be run, but also how a standalone organisation will manage their ARK instances.&lt;br /&gt;
&lt;br /&gt;
* An ARK instance is here defined as a combination of ARK users and the ARK site data they are able to access, usually under a single project/brand/organisation.&lt;br /&gt;
* A database is defined as a combination of a database user and the tables it can access, not the database server instance which can hold multiple database.&lt;br /&gt;
* Multi-tenancy is the ability to have multiple ARK instances in a single ARK install.&lt;br /&gt;
* Multi-site is the ability to have multiple sites within an ARK instance.&lt;br /&gt;
* Mulit-config is the ability to have multiple ARK schemas within an ARK instance, i.e. different sites having a different config.&lt;br /&gt;
&lt;br /&gt;
Choosing an architecture involves a series of trade-offs around ease-of-development versus ease-of-maintenance. The simplest solution is the current structure, where an ARK instance has a single tenant with a single config across multiple sites. There are problems with this however:&lt;br /&gt;
* Each instance requires a separate code install, database and URL&lt;br /&gt;
* If a single organisation wants multiple ARK schemas (say trench-based rural and a full urban SCR) they must run separate ARK instances for each schema, meaning users must remember which instance has which sites and maintain separate user IDs, and the apps using the API must know this as well.&lt;br /&gt;
* Making significant upgrades to an organisation&amp;#039;s config requires a separate ARK install&lt;br /&gt;
* Scaling up to 100&amp;#039;s of instances creates 100&amp;#039;s of installs and 100&amp;#039;s of databases which will make support difficult and expensive even with automation&lt;br /&gt;
&lt;br /&gt;
At the opposite extreme is an architecture where a single ARK install supports multiple tenants, sites and configs in a single database. While this solves the above issues by greatly simplifying maintenance there are a number of issues here too:&lt;br /&gt;
* Code and SQL is significantly more complicated, joins especially become difficult&lt;br /&gt;
* Key bloat on all tables as fields required for tenant and site which may affect performance&lt;br /&gt;
* Table bloat with all data being in a single set of tables which may affect performance&lt;br /&gt;
* Back up and archive is an issue as the data for different tenants needs to be separated, probably requiring custom code instead of standard tools&lt;br /&gt;
* Security is an issue with data access control now occurring in the app code&lt;br /&gt;
* A single tenant can overload the server and take all tenants down&lt;br /&gt;
* Distributing load across servers becomes difficult if not impossible&lt;br /&gt;
* Upgrading an install means all site configs must be upgraded too, you cannot leave a site on an old version&lt;br /&gt;
* Existing code and data would make ARK1 migration far more complex&lt;br /&gt;
&lt;br /&gt;
A half-way house model would be to allow a single install to have multiple tenants, but each tenant has its own database instance:&lt;br /&gt;
* A simple key structure is kept, keeping the code simple&lt;br /&gt;
* Each tenants data is kept separate, solving the size, security and backup issues&lt;br /&gt;
* Load can be easily distributed by moving a tenant to another server by simply moving their database and/or redirecting their url&lt;br /&gt;
* Code maintenance is kept simple, but database management becomes more complex again&lt;br /&gt;
* Upgrading an install will still require upgrading all sites&lt;br /&gt;
&lt;br /&gt;
Note: A practical limitation is imposed by MySQL and SQLite support which only allow a single &amp;#039;namespace&amp;#039; per database, unlike PostgreSQL and others which support multiple &amp;#039;namespaces&amp;#039; which would allow each tenant to have separate sets of tables within the same database.&lt;br /&gt;
&lt;br /&gt;
The strongest case can be made for supporting Multi-Config, primarily as a a means of allowing larger clients to host all their data inside a single install with a single set of users (including LP ourselves). This has several implications however:&lt;br /&gt;
* It raises Site Code from an attribute of an item in a module, to being a key at a higher level than the modules themselves, i.e the modules available will change depending on the Site Code&lt;br /&gt;
* As a consequence it substantially changes the api to add the site code above the module&lt;br /&gt;
* It may make searching across site codes difficult&lt;br /&gt;
* ???&lt;br /&gt;
&lt;br /&gt;
The full combination would allow a hosted ARK solution as follows:&lt;br /&gt;
* Lowest price tier (£5) / mass market / community dig type sites are hosted in a single multi-tenant install, only allowed a single site/config, may not allow own domain?&lt;br /&gt;
* Upgrade to lowest tier (£10) still in single multi-tenet install, but allowed say 5 sites/configs, maybe allow own domain?&lt;br /&gt;
* Next tier(s) (£15/£20/£25?) gives separate install, probably in own virtual host, own domain, with unlimited sites/configs?&lt;br /&gt;
* Possible top-tier for large-scale sites with guaranteed support contract&lt;br /&gt;
&lt;br /&gt;
This would keep the maintenance burden on the lowest-profit sites to a minimum, while encouraging up-sells as and when needed.&lt;br /&gt;
&lt;br /&gt;
Install management could be simplified by developing a set of built-in tools.&lt;br /&gt;
* Installs using git, run git pull to upgrade&lt;br /&gt;
* Doctrine migrations enable auto data updates&lt;br /&gt;
* Auto-check function for new releases and notify admin&lt;br /&gt;
* Admin panel to put site into maintenance mode, run code update, run data update&lt;br /&gt;
&lt;br /&gt;
Splitting database roles may assist in this:&lt;br /&gt;
* User database - allows Multi-tenant to choose if shared users for all/some tenants, or any tenant to have own users&lt;br /&gt;
* Config database - The ARK configuration, schemas, forms, etc, allows multi-tenant to share all configs with all/some tenants, or any tenant to have own set&lt;br /&gt;
* Data database - The ARK data, each tenant will have their own database&lt;br /&gt;
&lt;br /&gt;
The framework will manage three separate database connection variables, but where the database roles are shared by a database instance then the connection objects will be the same.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Frontend</id>
		<title>ARK2/Frontend</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Frontend"/>
				<updated>2016-10-30T14:40:00Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Scripts */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Overview ==&lt;br /&gt;
&lt;br /&gt;
ARK2 has imposed a clear separation between the backend and frontend, allowing the frontend to operate completely independently. ARK2 provides a number of standard frontend implementations, but sites can adapt or implement their own. This also supports multi-tenant mode where a single ARK2 install can be configured to run multiple ARK2 sites using different frontends.&lt;br /&gt;
&lt;br /&gt;
Two options exist for building frontends:&lt;br /&gt;
* Integrated frontends using the ARK2 PHP API via TWIG templates and Views defined in the config database&lt;br /&gt;
* Standalone frontends using calls to the ARK2 REST API&lt;br /&gt;
&lt;br /&gt;
The integrated frontends that ship with ARK2 are implemented in [http://getbootstrap.com/ Bootstrap], [https://jquery.com/ jQuery], and [http://twig.sensiolabs.org/ Twig], the most popular and well-supported frontend libraries. Frontends can be cloned and modified for a specific site, allowing for easier customisation of ARK&amp;#039;s appearance by third party designers. Standalone frontends could be implemented in any other technologies such as React and Vue.&lt;br /&gt;
&lt;br /&gt;
The integrated frontends shipped with ARK2 are:&lt;br /&gt;
* admin - A minimal Web Admin front-end for configuring an API-only server&lt;br /&gt;
* ark2 - The default front-end supporting the full ARK2 feature set&lt;br /&gt;
* bootstrap3 - A minimal Bootstrap 3 frontend designed as a base for custom frontends&lt;br /&gt;
* bootstrap4 - A minimal Bootstrap 4 frontend designed as a base for custom frontends&lt;br /&gt;
* flat - A simple, non-js, read-only front-end designed for scraping, e.g. for static archiving or web-bots&lt;br /&gt;
&lt;br /&gt;
The integrated frontends require a build process to assemble the required frontend resources into a distributable form. This page documents the process required to do so.&lt;br /&gt;
&lt;br /&gt;
The resources built into a frontend can be obtained from three sources:&lt;br /&gt;
* Vendor resources: Third-party libraries from outside ARK2, such as Bootstrap, jQuery, and FontAwesome&lt;br /&gt;
* Core resources: Standard resources provided by ARK2 for interacting with ARK2 features, e.g. common widgets, form layouts, etc&lt;br /&gt;
* Custom resources: Custom resources developed for a particular frontend&lt;br /&gt;
&lt;br /&gt;
The build process uses tooling to combine these resources into a single source package that is able to be distributed.&lt;br /&gt;
&lt;br /&gt;
== Source ==&lt;br /&gt;
&lt;br /&gt;
Packaged frontend resources are saved in the src directory by Namespace and Name:&lt;br /&gt;
&lt;br /&gt;
  src/&amp;lt;namespace&amp;gt;/frontend/&amp;lt;frontend&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For example, the main ark2 frontend in the ARK name space is stored in:&lt;br /&gt;
&lt;br /&gt;
  src/ARK/frontend/ark2&lt;br /&gt;
&lt;br /&gt;
Within each frontend source folder, the source is organised by general type:&lt;br /&gt;
&lt;br /&gt;
  |- &amp;lt;frontend&amp;gt;/&lt;br /&gt;
    |- assets/&lt;br /&gt;
      |- fonts/&lt;br /&gt;
      |- images/&lt;br /&gt;
      |- scripts/&lt;br /&gt;
      |- styles/&lt;br /&gt;
    |- bin/&lt;br /&gt;
      |- console&lt;br /&gt;
    |- config/&lt;br /&gt;
      |- credentials.json&lt;br /&gt;
      |- database.json&lt;br /&gt;
      |- site.json&lt;br /&gt;
    |- public/&lt;br /&gt;
      |- .htaccess&lt;br /&gt;
      |- index.php&lt;br /&gt;
    |- templates/&lt;br /&gt;
    |- translations/&lt;br /&gt;
&lt;br /&gt;
The following source types generally use the default source and remain unchanged:&lt;br /&gt;
* bin - Any executables used by the frontend, usually just the site console&lt;br /&gt;
* config - The default config files for the frontend, the main site.json file, the database.json file, and the credentials.json file&lt;br /&gt;
* public - The default contents of the public webroot folder, including the index.php file&lt;br /&gt;
&lt;br /&gt;
The following source types are usually modified for a custom frontend and rebuilt using the build tooling when changed:&lt;br /&gt;
* assets - The public assets for the frontend that get included under the public webroot, i.e. fonts, images, scripts and stylesheets&lt;br /&gt;
* templates - The twig templates used to render the html&lt;br /&gt;
* translations - Vendor provided translation files&lt;br /&gt;
&lt;br /&gt;
Customising the scripts and stylesheets requires various tooling which is covered in the next section.&lt;br /&gt;
&lt;br /&gt;
== Build Tooling ==&lt;br /&gt;
&lt;br /&gt;
Build tooling for frontend resources is required for a number of reasons:&lt;br /&gt;
* Bootstrap can be customised most easily by changing variables used in the Sass templates, which then requires a build step to compile them into CSS&lt;br /&gt;
* Production deployment is more efficient if CSS and JS is stripped, merged and minified, while development is easier if a map is generated for the original code&lt;br /&gt;
* Resources from multiple sources need to be combined into a single package&lt;br /&gt;
* Multiple versions and combinations of resources may be required for performance reasons&lt;br /&gt;
* NPM library management downloads the entire package, not just the resources required, an extra step is required to copy just the required resources into the source folder&lt;br /&gt;
* All the steps required for packaging and release management can be automated, e.g. clean, compile, tag, package, etc&lt;br /&gt;
* The build tooling for the default ARK bootstrap and twig theme can be generalised to allow clients to build and deploy their own customised themes with minimal effort&lt;br /&gt;
&lt;br /&gt;
The build tooling works as follows:&lt;br /&gt;
* All build tooling and resources are isolated in the /build folder so it can be excluded from any release packages or production deployments&lt;br /&gt;
* Nothing in the /build folder may be depended on by any code outside the /build folder or required for running ARK itself&lt;br /&gt;
* [https://nodejs.org/en/ Node], [https://www.npmjs.com/ npm], [http://gulpjs.com/ Gulp] and Symfony Console are used to run the tooling&lt;br /&gt;
* NPM is used to manage the Node packages used which are installed into /build/node_packages&lt;br /&gt;
* Node packages are used both for the build tools themselves and for vendor libraries providing resources&lt;br /&gt;
* Gulp is used to ensure the build scripts run cross-platform&lt;br /&gt;
* Symfony Console is used to manage and run the build tasks&lt;br /&gt;
* Running tasks will only work inside the /build folder, trying to run outside the build folder will fail&lt;br /&gt;
* The resources required to be built for a frontend are defined in a manifest file&lt;br /&gt;
* The built frontend resources are then installed into the frontend source directory&lt;br /&gt;
* Later, each configured site in the ARK2 install links to the frontend it wishes to use&lt;br /&gt;
&lt;br /&gt;
== Build ==&lt;br /&gt;
&lt;br /&gt;
The front end build is managed by the [[ARK2/Console|Build Console]]. The Build console is in the &amp;#039;build/&amp;#039; folder and is used to build/rebuild/install a front-end if required. To run the console you must be in the build folder:&lt;br /&gt;
&lt;br /&gt;
  cd build&lt;br /&gt;
  ./build&lt;br /&gt;
&lt;br /&gt;
Running the console without a chosen command will show the list of available commands:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
ARK Build Console 1.9.80&lt;br /&gt;
&lt;br /&gt;
Usage:&lt;br /&gt;
  command [options] [arguments]&lt;br /&gt;
&lt;br /&gt;
Options:&lt;br /&gt;
  -h, --help            Display this help message&lt;br /&gt;
  -q, --quiet           Do not output any message&lt;br /&gt;
  -V, --version         Display this application version&lt;br /&gt;
      --ansi            Force ANSI output&lt;br /&gt;
      --no-ansi         Disable ANSI output&lt;br /&gt;
  -n, --no-interaction  Do not ask any interactive question&lt;br /&gt;
  -v|vv|vvv, --verbose  Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug&lt;br /&gt;
&lt;br /&gt;
Available commands:&lt;br /&gt;
  help                Displays help for a command&lt;br /&gt;
  list                Lists commands&lt;br /&gt;
 cache&lt;br /&gt;
  cache:clear         Clear the system cache&lt;br /&gt;
 database&lt;br /&gt;
  database:reverse    Reverse engineer an existing database as DoctrineXML&lt;br /&gt;
 frontend&lt;br /&gt;
  frontend:all        Build an ARK frontend. (Args: frontend)&lt;br /&gt;
  frontend:assets     Build the frontend assets (Fonts, Images, Scripts, Styles). (Args: frontend)&lt;br /&gt;
  frontend:base       Build the frontend base (Bin, Config, Templates, Translations, Web). (Args: frontend)&lt;br /&gt;
  frontend:create     Create a new ARK frontend (Args: namespace, frontend).&lt;br /&gt;
  frontend:scripts    Build the frontend scripts (JavaScript). (Args: frontend)&lt;br /&gt;
  frontend:styles     Build the frontend styles (CSS and SASS). (Args: frontend)&lt;br /&gt;
  frontend:templates  Build the frontend templates (Twig). (Args: frontend)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The first time you need to build/rebuild a frontend, you need to install the required Node packages. You will need to have installed Node and NPM on your system first.&lt;br /&gt;
&lt;br /&gt;
  npm install&lt;br /&gt;
&lt;br /&gt;
To update an existing installation, especially after an ARK upgrade:&lt;br /&gt;
&lt;br /&gt;
  npm update&lt;br /&gt;
&lt;br /&gt;
To check the status of your Node environment (including available updates), run:&lt;br /&gt;
&lt;br /&gt;
  npm doctor&lt;br /&gt;
&lt;br /&gt;
To install a new node package to use in the frontend, run:&lt;br /&gt;
&lt;br /&gt;
  npm install &amp;lt;package&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To build a frontend run the frontend command with the name of the frontend:&lt;br /&gt;
&lt;br /&gt;
  ./build frontend:all &amp;lt;frontend&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will install the built front end into &amp;#039;src/&amp;lt;namespace&amp;gt;/frontend/&amp;lt;frontend&amp;gt;&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
You can also choose to build just one type of resource to save time, e.g. if you only changed a template and don&amp;#039;t want to wait for the js to be rebuilt as well:&lt;br /&gt;
&lt;br /&gt;
  ./build frontend:styles &amp;lt;frontend&amp;gt;&lt;br /&gt;
  ./build frontend:scripts &amp;lt;frontend&amp;gt;&lt;br /&gt;
  ./build frontend:templates &amp;lt;frontend&amp;gt;&lt;br /&gt;
  ./build frontend:assets &amp;lt;frontend&amp;gt;&lt;br /&gt;
  ./build frontend:base &amp;lt;frontend&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The /build folder is organised by resource source as follows:&lt;br /&gt;
&lt;br /&gt;
 |- build/&lt;br /&gt;
   |- core/&lt;br /&gt;
   |- frontends/&lt;br /&gt;
     |- &amp;lt;frontend1&amp;gt;/&lt;br /&gt;
     |- &amp;lt;frontend2&amp;gt;/&lt;br /&gt;
     |- &amp;lt;frontend3&amp;gt;/&lt;br /&gt;
   |- node_modules/&lt;br /&gt;
   |- .jsbeautifyrc&lt;br /&gt;
   |- .jshintrc&lt;br /&gt;
   |- build&lt;br /&gt;
   |- gulpfile.js&lt;br /&gt;
   |- packages.json&lt;br /&gt;
&lt;br /&gt;
* The /node_modules folder holds the vendor resources managed by NPM as defined in the packages.json file&lt;br /&gt;
* The/ core folder holds the core resources provided by ark2&lt;br /&gt;
* The /frontends folder holds the custom resources for the various integrated frontends&lt;br /&gt;
* The /gulpfile.js defines the Gulp build scripts&lt;br /&gt;
* The /build console runs the build scripts&lt;br /&gt;
* The /.jsbeautifyrc and /.jshintrc files define the JavaScript coding standards used in ARK2&lt;br /&gt;
&lt;br /&gt;
Within the /core folder and each custom frontend folder, the resources provided are organised in folders by resource source type:&lt;br /&gt;
&lt;br /&gt;
  |- &amp;lt;frontend&amp;gt;/&lt;br /&gt;
    |- bin/&lt;br /&gt;
    |- config/&lt;br /&gt;
    |- fonts/&lt;br /&gt;
    |- images/&lt;br /&gt;
    |- js/&lt;br /&gt;
    |- public/&lt;br /&gt;
    |- scss/&lt;br /&gt;
    |- twig/&lt;br /&gt;
    |- xliff/&lt;br /&gt;
&lt;br /&gt;
== Manifest ==&lt;br /&gt;
&lt;br /&gt;
The combination of resources that are built into a frontend are defined by the build manifest.json file in the root of each frontend folder, e.g. /build/frontends/ark2/manifest.json.&lt;br /&gt;
&lt;br /&gt;
 {&lt;br /&gt;
     &amp;quot;frontend&amp;quot;: &amp;quot;ark2&amp;quot;,&lt;br /&gt;
     &amp;quot;namespace&amp;quot;: &amp;quot;ARK&amp;quot;,&lt;br /&gt;
     &amp;quot;options&amp;quot;: {},&lt;br /&gt;
     &amp;quot;assets&amp;quot;: {&lt;br /&gt;
         &amp;quot;fonts&amp;quot;: {},&lt;br /&gt;
         &amp;quot;images&amp;quot;: {},&lt;br /&gt;
         &amp;quot;scripts&amp;quot;: {},&lt;br /&gt;
         &amp;quot;styles&amp;quot;: {}&lt;br /&gt;
     },&lt;br /&gt;
     &amp;quot;bin&amp;quot;: {},&lt;br /&gt;
     &amp;quot;config&amp;quot;: {},&lt;br /&gt;
     &amp;quot;templates&amp;quot;: {},&lt;br /&gt;
     &amp;quot;translations&amp;quot;: {},&lt;br /&gt;
     &amp;quot;public&amp;quot;: {}&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
Here you see the root level of the manifest defines the same resource classes as is used to organise the frontend source folder, i.e. these sections define the resources that will be packaged together to be installed into the source folder.&lt;br /&gt;
&lt;br /&gt;
There are also three extra root level keys:&lt;br /&gt;
* frontend - the name of the frontend used in the source path&lt;br /&gt;
* namespace - the namespace of the frontend used in the source path&lt;br /&gt;
* options - various options to be used in the build tooling, keyed by the Gulp module that uses them&lt;br /&gt;
&lt;br /&gt;
The default build options are as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;quot;options&amp;quot;: {&lt;br /&gt;
     &amp;quot;uglify&amp;quot;: {&lt;br /&gt;
         &amp;quot;compress&amp;quot;: false&lt;br /&gt;
     },&lt;br /&gt;
     &amp;quot;sass&amp;quot;: {&lt;br /&gt;
         &amp;quot;outputStyle&amp;quot;: &amp;quot;compressed&amp;quot;,&lt;br /&gt;
         &amp;quot;precision&amp;quot;: 8,&lt;br /&gt;
         &amp;quot;includePaths&amp;quot;: [&lt;br /&gt;
             &amp;quot;node_modules/bootstrap-sass/assets/stylesheets&amp;quot;&lt;br /&gt;
         ]&lt;br /&gt;
     },&lt;br /&gt;
     &amp;quot;sourcemaps&amp;quot;: {&lt;br /&gt;
         &amp;quot;loadMaps&amp;quot;: true&lt;br /&gt;
     },&lt;br /&gt;
     &amp;quot;autoprefixer&amp;quot;: {&lt;br /&gt;
         &amp;quot;browsers&amp;quot;: [&lt;br /&gt;
             &amp;quot;Android 2.3&amp;quot;,&lt;br /&gt;
             &amp;quot;Android &amp;gt;= 4&amp;quot;,&lt;br /&gt;
             &amp;quot;Chrome &amp;gt;= 20&amp;quot;,&lt;br /&gt;
             &amp;quot;Firefox &amp;gt;= 24&amp;quot;,&lt;br /&gt;
             &amp;quot;Explorer &amp;gt;= 8&amp;quot;,&lt;br /&gt;
             &amp;quot;iOS &amp;gt;= 6&amp;quot;,&lt;br /&gt;
             &amp;quot;Opera &amp;gt;= 12&amp;quot;,&lt;br /&gt;
             &amp;quot;Safari &amp;gt;= 6&amp;quot;&lt;br /&gt;
         ]&lt;br /&gt;
     }&lt;br /&gt;
 },&lt;br /&gt;
&lt;br /&gt;
Not that the autoprefixer settings are those required by Bootstrap and should not be altered.&lt;br /&gt;
&lt;br /&gt;
Within each resource class, you must define what resources are to be included from the three resource sources: vendor, core and custom.&lt;br /&gt;
&lt;br /&gt;
For most resource classes this defines what files to copy into the source folder, either by individual file names or (more usually for core and custom) all files in a folder:&lt;br /&gt;
&lt;br /&gt;
 &amp;quot;templates&amp;quot;: {&lt;br /&gt;
     &amp;quot;vendor&amp;quot;: [&lt;br /&gt;
         &amp;quot;symfony-collection/jquery.collection.html.twig&amp;quot;&lt;br /&gt;
     ],&lt;br /&gt;
     &amp;quot;core&amp;quot;: [&lt;br /&gt;
         &amp;quot;twig/**/*&amp;quot;,&lt;br /&gt;
         &amp;quot;twig/**/.*&amp;quot;&lt;br /&gt;
     ],&lt;br /&gt;
     &amp;quot;custom&amp;quot;: [&lt;br /&gt;
         &amp;quot;twig/**/*&amp;quot;,&lt;br /&gt;
         &amp;quot;twig/**/.*&amp;quot;&lt;br /&gt;
     ]&lt;br /&gt;
 },&lt;br /&gt;
&lt;br /&gt;
When copying files in this way, the order used is vendor, core, then custom, so files in core will override files in vendor and files in custom will override files in core. The vendor file paths are relative to /build/node_modules, the core files are paths relative to /build/core, and the custom files are paths relative to /build/frontends/&amp;lt;frontend&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The scripts and styles groups work differently however as they must call the SASS and JavaScript build tools to compile the destination source code.&lt;br /&gt;
&lt;br /&gt;
The scripts class defines a set of build targets, that is named minified javascript files to be compiled, and the javascript files that are merged to create that file. For example, to build script files ark-default.min.js and ark-map.min.js you could define the following:&lt;br /&gt;
&lt;br /&gt;
 &amp;quot;scripts&amp;quot;: {&lt;br /&gt;
     &amp;quot;ark-default&amp;quot;: {&lt;br /&gt;
         &amp;quot;vendor&amp;quot;: [&lt;br /&gt;
             &amp;quot;jquery/dist/jquery.js&amp;quot;,&lt;br /&gt;
             &amp;quot;bootstrap-sass/assets/javascripts/bootstrap.js&amp;quot;&lt;br /&gt;
         ],&lt;br /&gt;
         &amp;quot;core&amp;quot;: [&lt;br /&gt;
             &amp;quot;js/core-ready.js&amp;quot;&lt;br /&gt;
         ],&lt;br /&gt;
         &amp;quot;custom&amp;quot;: [&lt;br /&gt;
             &amp;quot;js/frontend-ready.js&amp;quot;,&lt;br /&gt;
         ]&lt;br /&gt;
     },&lt;br /&gt;
     &amp;quot;ark-map&amp;quot;: {&lt;br /&gt;
         &amp;quot;vendor&amp;quot;: [&lt;br /&gt;
             &amp;quot;proj4/dist/proj4.js&amp;quot;,&lt;br /&gt;
             &amp;quot;openlayers/dist/ol.js&amp;quot;&lt;br /&gt;
         ],&lt;br /&gt;
         &amp;quot;core&amp;quot;: [],&lt;br /&gt;
         &amp;quot;custom&amp;quot;: [&lt;br /&gt;
             &amp;quot;js/map-ready.js&amp;quot;&lt;br /&gt;
         ]&lt;br /&gt;
     }&lt;br /&gt;
 },&lt;br /&gt;
&lt;br /&gt;
The javascript files are merged in the order defined in the groups, so it is recommended to explicitly list the files so that the correct order of dependencies can be defined. Sourcemap files will be created if specified in the options.&lt;br /&gt;
&lt;br /&gt;
The scripts class defines a set of build targets, that is named minified CSS stylesheet files to be compiled, and the list of Gulp build streams required to built by the SASS compiler before being combined into that target file. For example, to build style files ark-default.min.css and ark-map.min.css you could define the following:&lt;br /&gt;
&lt;br /&gt;
 &amp;quot;styles&amp;quot;: {&lt;br /&gt;
     &amp;quot;ark-default&amp;quot;: [{&lt;br /&gt;
             &amp;quot;stream&amp;quot;: &amp;quot;bootstrap&amp;quot;,&lt;br /&gt;
             &amp;quot;vendor&amp;quot;: [],&lt;br /&gt;
             &amp;quot;core&amp;quot;: [],&lt;br /&gt;
             &amp;quot;custom&amp;quot;: [&lt;br /&gt;
                 &amp;quot;scss/vendor.scss&amp;quot;&lt;br /&gt;
             ]&lt;br /&gt;
         },&lt;br /&gt;
         {&lt;br /&gt;
             &amp;quot;stream&amp;quot;: &amp;quot;main&amp;quot;,&lt;br /&gt;
             &amp;quot;vendor&amp;quot;: [&lt;br /&gt;
                 &amp;quot;font-awesome/css/font-awesome.css&amp;quot;&lt;br /&gt;
             ],&lt;br /&gt;
             &amp;quot;core&amp;quot;: [],&lt;br /&gt;
             &amp;quot;custom&amp;quot;: [&lt;br /&gt;
                 &amp;quot;scss/default.scss&amp;quot;&lt;br /&gt;
             ]&lt;br /&gt;
         }&lt;br /&gt;
     ],&lt;br /&gt;
     &amp;quot;ark-map&amp;quot;: [{&lt;br /&gt;
         &amp;quot;stream&amp;quot;: &amp;quot;main&amp;quot;,&lt;br /&gt;
         &amp;quot;vendor&amp;quot;: [&lt;br /&gt;
             &amp;quot;openlayers/dist/ol.css&amp;quot;&lt;br /&gt;
         ],&lt;br /&gt;
         &amp;quot;core&amp;quot;: [],&lt;br /&gt;
         &amp;quot;custom&amp;quot;: [&lt;br /&gt;
             &amp;quot;scss/map.scss&amp;quot;&lt;br /&gt;
         ]&lt;br /&gt;
     }]&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
The defining of streams within each target allows for the mixing of SASS and CSS source in a defined order so the cascading of stylesheets is applied in the correct order&lt;br /&gt;
&lt;br /&gt;
== Templates ==&lt;br /&gt;
&lt;br /&gt;
Twig template resources are organised using a convention to make dynamic mixing of templates to create many different Views possible.&lt;br /&gt;
&lt;br /&gt;
The twig folder for a frontend is organised as follows:&lt;br /&gt;
&lt;br /&gt;
 |- twig/&lt;br /&gt;
   |- blocks/&lt;br /&gt;
   |- errors/&lt;br /&gt;
   |- framework/&lt;br /&gt;
   |- layouts/&lt;br /&gt;
   |- pages/&lt;br /&gt;
   |- profiler/&lt;br /&gt;
   |- user/&lt;br /&gt;
     |- emails/&lt;br /&gt;
     |- layouts/&lt;br /&gt;
&lt;br /&gt;
* blocks - Small chunks of twig code designed to be reused and repeated using Twig Block inheritance, e.g. form fields, widgets, etc.&lt;br /&gt;
* layouts - Arrangements of blocks into generic or task specific layouts, e.g. grids, tables, custom content views, etc. &lt;br /&gt;
* pages - Definitions of the sets of standard blocks to use when building the HTML document for a particular page&lt;br /&gt;
* framework - Definition of the standard HTML document and default page blocks&lt;br /&gt;
* errors - Standard error pages, i.e. 404, 500, etc&lt;br /&gt;
* user - Required layouts for the user security system, e.g. user verification emails, login forms, etc.&lt;br /&gt;
* profiler - Custom templates to be used in the Symfony profiler&lt;br /&gt;
&lt;br /&gt;
The blocks used fall into three general groups:&lt;br /&gt;
* Standard page blocks - blocks that define or override standard page elements such as scripts, navbars, etc, which are saved in separate block files.&lt;br /&gt;
* Form blocks - blocks that define standard Symfony Form elements such as Textarea, Select, Radio, etc, which are saved in a single blocks/forms.html.twig file&lt;br /&gt;
* Custom widget blocks - blocks that define custom widgets that do not use Symfony Forms and are saved in separate block files&lt;br /&gt;
&lt;br /&gt;
The standard page blocks are:&lt;br /&gt;
* head - defines the document &amp;lt;head&amp;gt; element&lt;br /&gt;
* styles - stylesheets to be included at the top of the document &amp;lt;head&amp;gt; element&lt;br /&gt;
* body - defines the document &amp;lt;body&amp;gt; element, usually how the navbar, sidebar, content and footer blocks are arranged in the body&lt;br /&gt;
* navbar - defines the navbar or header at the top of the document body&lt;br /&gt;
* sidebar - defines the sidebar or menu at the side of the document body&lt;br /&gt;
* content - defines the main content of the document body&lt;br /&gt;
* footer - defines the footer at the bottom of the document body&lt;br /&gt;
* scripts - scripts to be included at the bottom of the document &amp;lt;body&amp;gt; element&lt;br /&gt;
* link - defines the link element used in the navbar/sidebar/footer&lt;br /&gt;
* flash - defines the page flash element&lt;br /&gt;
&lt;br /&gt;
The standard ARK2 page view is built in Twig as follows:&lt;br /&gt;
* framework/doc.html.twig - Skeleton of the HTML5 document, includes undefined blocks for styles, head, body and scripts&lt;br /&gt;
* framework/page.html.twig - Extends doc.html.twig and defines the full default set of blocks to use for styles, head, body, and scripts, includes other default blocks used by those blocks such as navbar, but excludes the content block to be used&lt;br /&gt;
* pages/&amp;lt;page&amp;gt;.html.twig - Extends framework/page.html.twig to set the content block to be used by a page, and overrides any standard blocks with custom blocks to be used, e.g. override the standard styles or navbar blocks on this page. This is the root template rendered by a page view.&lt;br /&gt;
&lt;br /&gt;
== Scripts ==&lt;br /&gt;
&lt;br /&gt;
The use of Javascript in ARK2 is not very well defined or organised as yet beyond the use of jQuery and various Bootstrap-based widgets.&lt;br /&gt;
&lt;br /&gt;
Core Javascript resources in /build/core/js:&lt;br /&gt;
* alert.js - Utilies for working with the ARK2/Bootstrap alerts&lt;br /&gt;
* core-ready.js -  Initialise the core javascript on document ready&lt;br /&gt;
* form.js - Various form related tools, such as the AJAX form mappper&lt;br /&gt;
* form-ready.js - Initialise the form javascript on document ready&lt;br /&gt;
* location.js - An OpenLayers map picker widget as configured in the ark_map table.&lt;br /&gt;
* map-ol4.js - An OpenLayers map widget as configured in the ark_map table.&lt;br /&gt;
* map-ready.js - Initialise the map widget on document ready&lt;br /&gt;
* pageedit.js - Static page editing using Summernote Editor&lt;br /&gt;
* routing.js - The Routing module to use to generate paths from Route IDs.&lt;br /&gt;
* utilities.js - Some utility routines, such as debounce.&lt;br /&gt;
&lt;br /&gt;
Common vendor libraries used via NPM:&lt;br /&gt;
* jquery&lt;br /&gt;
* jquery-form&lt;br /&gt;
* moment&lt;br /&gt;
* bazinga-translator&lt;br /&gt;
* select2&lt;br /&gt;
* bootstrap&lt;br /&gt;
* bootbox&lt;br /&gt;
* bootstrap-datetime-picker&lt;br /&gt;
* bootstrap-fileinput&lt;br /&gt;
* bootstrap-table&lt;br /&gt;
&lt;br /&gt;
== Styles ==&lt;br /&gt;
&lt;br /&gt;
Styles use a combination of SASS and CSS as required with Bootstrap as the chosen ui style.&lt;br /&gt;
&lt;br /&gt;
== Useful References ==&lt;br /&gt;
&lt;br /&gt;
* https://symfony.com/doc/3.4/form/form_customization.html&lt;br /&gt;
* https://symfony.com/doc/3.4/reference/forms/twig_reference.html&lt;br /&gt;
* http://www.helloerik.com/the-subtle-magic-behind-why-the-bootstrap-3-grid-works&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Security</id>
		<title>ARK2/Security</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Security"/>
				<updated>2016-10-30T14:25:14Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* User Levels */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Security =&lt;br /&gt;
&lt;br /&gt;
ARK2 uses the Symfony Security component. ARK2 extends this component with its own User Provider and Role-Based Access Control to manage user rights within an ARK.&lt;br /&gt;
&lt;br /&gt;
* User Authentication&lt;br /&gt;
** Token-based&lt;br /&gt;
** Local user database for stand-alone/internal use&lt;br /&gt;
** Distributed Via OAuth and OpenID authentication services (Google, Facebook, etc)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* User Authorisation&lt;br /&gt;
** Role-Based Access Control (RBAC) model based on Users/Roles/Permissions&lt;br /&gt;
&lt;br /&gt;
HTTPS is required and is supported using LetsEncrypt to obtain SSL certificates.&lt;br /&gt;
&lt;br /&gt;
=== User Status ===&lt;br /&gt;
&lt;br /&gt;
The User account has the following possible statuses:&lt;br /&gt;
&lt;br /&gt;
* Registered - The user has registered with the website but not yet verified their email (if required)&lt;br /&gt;
* Verified - The user has responded to the email verification but not yet been enabled by the admin (if required)&lt;br /&gt;
* Enabled - The user is enabled to use the website&lt;br /&gt;
* Disabled - The user has been disabled by the admin and cannot login or reset their account&lt;br /&gt;
* Locked - The user has failed the password check and must reset their password, or the admin has required them to reset their password&lt;br /&gt;
* Expired - The expiry date for the account has passed and must be extended by the admin&lt;br /&gt;
&lt;br /&gt;
=== User Levels ===&lt;br /&gt;
&lt;br /&gt;
ARK User Levels are a renaming of Symfony Security module Roles to prevent confusion with ARK RBAC Roles:&lt;br /&gt;
&lt;br /&gt;
* ROLE_SYSADMIN - System Admin - Admin rights for an ARK system install.&lt;br /&gt;
* ROLE_ADMIN - ARK Admin - Admin rights for an ARK instance.&lt;br /&gt;
* ROLE_USER - General user rights for any other role within an ARK instance.&lt;br /&gt;
* ROLE_ANON - Anonymous users.&lt;br /&gt;
&lt;br /&gt;
== RBAC Model ==&lt;br /&gt;
&lt;br /&gt;
* Permission - A specific right that may be granted to view data or perform an action within the system&lt;br /&gt;
* Actor - A persistent entity who can view data or perform actions within the system&lt;br /&gt;
* Role - A set of Permissions that can be assigned to an Actor&lt;br /&gt;
* User - A security account for logging into the system that can be linked to one or more Actors&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/API</id>
		<title>ARK2/API</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/API"/>
				<updated>2016-10-29T19:30:32Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* API */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= API =&lt;br /&gt;
&lt;br /&gt;
ARK2 provides a new, standards-compliant, secure, complete API for query and update.&lt;br /&gt;
&lt;br /&gt;
A number of popular API standards exits. ARK2 has chosen JSON:API as the default API standard, as this is the best suited to the full update functionality required by external apps. However, given the very large user base for JSON-LD within the heritage community, and Google&amp;#039;s use of it for SEO, support will be added for a read-only API and semantically-tagged HTML. The library used for JSON-LD will also provide HAL, JSON, and CSV standards support. Facebook&amp;#039;s [http://graphql.org/ GraphQL] will be considered in the future.&lt;br /&gt;
&lt;br /&gt;
== Background ==&lt;br /&gt;
&lt;br /&gt;
An evolution of the ARK data model and API to try realise the [http://ark.lparchaeology.com/hypertext/ full ARK vision] will be based arround the Hypermedia concepts of [https://en.wikipedia.org/wiki/Representational_state_transfer REST] and [https://en.wikipedia.org/wiki/HATEOAS HATEOAS] as developed by Roy Fielding in his doctoral thesis in 2000. These concepts include resources, relationships, state, and discoverability, and are closely related to the Semantic Web. ARK modules will evolve to represent Resources that can be linked in together in the current flat relationship structure, or organised into configurable hierarchies such as the default Site/Module/Item mostly used by ARK instances. These concepts will be most easily exposed through a RESTful API.&lt;br /&gt;
&lt;br /&gt;
A RESTful API will be implemented using best practices which are outlined in the following articles:&lt;br /&gt;
* http://www.vinaysahni.com/best-practices-for-a-pragmatic-restful-api&lt;br /&gt;
* http://blogs.mulesoft.com/dev/api-best-practices-series-intro/&lt;br /&gt;
&lt;br /&gt;
In particular, the following rules will be applied:&lt;br /&gt;
* Full level 4 [http://timelessrepo.com/haters-gonna-hateoas HATEOAS REST implementation]&lt;br /&gt;
* JSON will be the only format supported&lt;br /&gt;
* The [http://jsonapi.org/ JSON API] standard will be used to construct the response body, with [http://json-schema.org/ JSON Schema] standard defining the structure of the data payload.&lt;br /&gt;
* API versioning will be used to version the resource path structure, error messaging, and other API infrastructure. The actual data formats will be controlled by the JSON schema which will be available via a standard end-point.&lt;br /&gt;
* Authenticated access will only be available using HTTPS, API tokens, and OAuth2&lt;br /&gt;
* Read-only unauthenticated unencrypted access will be supported only if explicitly enabled&lt;br /&gt;
* Translation keys will be used, with the client downloading a translation catalogue for their required language&lt;br /&gt;
&lt;br /&gt;
The general API URL structure will be as follows:&lt;br /&gt;
* /api/v2/&amp;lt;module&amp;gt;/&amp;lt;item&amp;gt;/&amp;lt;submodule&amp;gt;/&amp;lt;item&amp;gt;&lt;br /&gt;
&lt;br /&gt;
e.g. for Site MNO12 and Context MNO12_1 the resource will be www.lparchaeology.com/ark/api/v2/sites/MNO12/contexts/1&lt;br /&gt;
&lt;br /&gt;
A question remains over the structure for hosted ARK installs:&lt;br /&gt;
* www.arkhive.org/api/v2/arks/lamas/sites/ABC12/cxt/1 - Allows easy exposure of all instances for LD consumption&lt;br /&gt;
* lamas.arkhive.org/api/v2/sites/MNO12/cxt/1 - Easier for migration to stand-alone ARK, more &amp;#039;private&amp;#039;&lt;br /&gt;
* www.arkhive.org/lamas/api/v2/sites/MNO12/cxt/1 - As for 2.&lt;br /&gt;
&lt;br /&gt;
The following HTTP actions will be supported:&lt;br /&gt;
* GET - fetch resource&lt;br /&gt;
* POST - insert new resource with next available id, i.e. insert a new item with next item number&lt;br /&gt;
* PUT - insert or update resource with a specified id, i.e. insert a new item or update an existing item with a set item number&lt;br /&gt;
* PATCH - update part of a resource, i.e. update a single field or group&lt;br /&gt;
* DELETE - delete a resource&lt;br /&gt;
* OPTIONS - What HTTP verbs the current authenticated API user can perform on a resource&lt;br /&gt;
&lt;br /&gt;
The following other endpoints will be supported:&lt;br /&gt;
* /filters - The global saved filters&lt;br /&gt;
* /filters/123 - The filter definition&lt;br /&gt;
* /filters/123/items - The filter result set&lt;br /&gt;
* /users - The users&lt;br /&gt;
* /users/jlayt - The user details&lt;br /&gt;
* /users/jlayt/filters - returns the the list of user filters, etc as per filters endpoint&lt;br /&gt;
* /actors - The global actors&lt;br /&gt;
* /actors/123 - The actor details&lt;br /&gt;
&lt;br /&gt;
The JSON:API query values will be supported:&lt;br /&gt;
* ?filter - basic search in fields (use /filters for advanced search)&lt;br /&gt;
* ?sort - sorts results by fields&lt;br /&gt;
* ?fields - return selected fields &lt;br /&gt;
* ?page - pagination of results&lt;br /&gt;
* ?q - not standard, free-text search?&lt;br /&gt;
&lt;br /&gt;
Notes:&lt;br /&gt;
* Updating a resource will require some kind of timestamp or last update key to prevent overwriting subsequent changes&lt;br /&gt;
* All security / OPTIONS / anon access will be controlled by user roles&lt;br /&gt;
&lt;br /&gt;
JSO Schema Implementations:&lt;br /&gt;
* JSON Schema validation via PHP League (simple, complete, extendable) or Justin Rainbow (most widely used)&lt;br /&gt;
&lt;br /&gt;
JSON-API Implementations:&lt;br /&gt;
* http://fractal.thephpleague.com/ PHP League Fractal library to serialize as JSON-API - nice, multi-format, but missing some needed features&lt;br /&gt;
* https://github.com/woohoolabs/yin - Very nice but PSR-7 and JSON Schema validation uses Rainbow, 5 contrib, 29 releases, last update 2 weeks&lt;br /&gt;
* https://github.com/tobscure/json-api - Good, clean, complete standard, agnostic, but no extras/schema/header handling. 17 contrib, 5 releases, last update 1 month, 2nd popularity rank&lt;br /&gt;
* https://github.com/neomerx/json-api - 7 contribs, 42 releases, last update 1 week&lt;br /&gt;
* https://github.com/nilportugues/php-json-api - 8 contribs, 63 releases, last update 3 weeks&lt;br /&gt;
* https://github.com/nilportugues/symfony-jsonapi - Symfony 2 bundle, last update 2 weeks&lt;br /&gt;
* https://github.com/mauro-moreno/silex-jsonapi - Silex provider for nilportugues, ast update 2 months&lt;br /&gt;
* https://github.com/lode/jsonapi - Simple, 2 contrib, 10 releasses, last update 3 weeks&lt;br /&gt;
* PHP Client: https://github.com/Art4/json-api-client&lt;br /&gt;
&lt;br /&gt;
Not considered:&lt;br /&gt;
* https://github.com/matthiasbayer/json-api - 1 contrib, last update 1 year&lt;br /&gt;
* https://github.com/matthiasbayer/BayerJsonApiBundle - Symfony2 bundle,1 contrib, last update 1 year&lt;br /&gt;
* https://github.com/rstgroup/json-api-php - 3 contrib, last update 2 years&lt;br /&gt;
* https://github.com/GoIntegro/hateoas deep symfony integration, would be ideal but is driven by Doctrine ORM map and RAML&lt;br /&gt;
&lt;br /&gt;
== Query Parameters ==&lt;br /&gt;
&lt;br /&gt;
The JSON:API standard does not specify how to structure filter/search query parameters, other than to define &amp;#039;filter=&amp;#039; for this purpose. The following standard, based mainly on [https://developers.google.com/analytics/devguides/reporting/core/v3/reference#filters Google APIs], is used.&lt;br /&gt;
&lt;br /&gt;
Operators (must be encoded where appropriate):&lt;br /&gt;
 ==	Equals/ Exact match&lt;br /&gt;
 !=	Does not equal / Does not match&lt;br /&gt;
 &amp;gt;	Greater than&lt;br /&gt;
 &amp;lt;	Less than&lt;br /&gt;
 &amp;gt;=	Greater than or equal to&lt;br /&gt;
 &amp;lt;=	Less than or equal to&lt;br /&gt;
 =@	Contains substring	&lt;br /&gt;
 !@	Does not contain substring&lt;br /&gt;
 =~	Contains a match for the regular expression&lt;br /&gt;
 !~	Does not match regular expression&lt;br /&gt;
 !	Not&lt;br /&gt;
 ,	Or&lt;br /&gt;
 ;	And&lt;br /&gt;
 ()	Grouping&lt;br /&gt;
 []	In&lt;br /&gt;
 &amp;#039;&amp;#039;	Literal string&lt;br /&gt;
&lt;br /&gt;
For example:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;filter=foo==3,foo==5;bar=@bong;magic[this,that,other]&lt;br /&gt;
&lt;br /&gt;
Calling functions, such as beginsWith() or intersects() could be added later, but advanced filter may be better served by a JSON format that can be persisted.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Development</id>
		<title>ARK2/Development</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Development"/>
				<updated>2016-10-29T17:54:02Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Supported Platforms */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Technical Details =&lt;br /&gt;
&lt;br /&gt;
== Supported Platforms ==&lt;br /&gt;
&lt;br /&gt;
ARK2 will only actively support platforms that are actively supported with security fixes by the upstream developers. ARK2 may run on platforms not actively supported, but this is not guaranteed and ARK2 may in the future require features only available in the supported platform versions.&lt;br /&gt;
&lt;br /&gt;
* Apache is supported and will require mod_rewrite, other servers may work.&lt;br /&gt;
* PHP: PHP 7.4 is required due to new language features. The minimum version will be the minimum supported by PHP (see in [http://php.net/supported-versions.php PHP Supported Versions].&lt;br /&gt;
* PHP intl extension and ICU will be required, the opcache and APCu cache extensions are strongly recommended for performance.&lt;br /&gt;
* MySQL/MariaDB v5.7.8 or later (lowest supported MySQL, required for timestamps, full-text index, spatial index, and JSON type), utf8mb4 codeset only&lt;br /&gt;
* PostgreSQL v10 or later&lt;br /&gt;
* SQLite 3.9 or later (required for multiple inserts, full-text index, JSON type), Spatialite extension for spatial data&lt;br /&gt;
* Redis is recommended for data caching&lt;br /&gt;
* Linux and Mac are actively supported, Windows is also supported but minimally tested&lt;br /&gt;
&lt;br /&gt;
== Browsers ==&lt;br /&gt;
&lt;br /&gt;
ARK2 uses Bootstrap 3 for the default frontend. ARK2 therefore supports the browser versions supported by Bootstrap 3:&lt;br /&gt;
&lt;br /&gt;
* Android 2.3&lt;br /&gt;
* Android &amp;gt;= 4&lt;br /&gt;
* Chrome &amp;gt;= 20&lt;br /&gt;
* Firefox &amp;gt;= 24&lt;br /&gt;
* Explorer &amp;gt;= 8&lt;br /&gt;
* iOS &amp;gt;= 6&lt;br /&gt;
* Opera &amp;gt;= 12&lt;br /&gt;
* Safari &amp;gt;= 6&lt;br /&gt;
&lt;br /&gt;
Note that particular features provided by add-ons may not support this set of browsers. Due to the separation of the ARK2 frontend, you are free to implement your own frontend in any toolkit should you have other requirements.&lt;br /&gt;
&lt;br /&gt;
== Standards ==&lt;br /&gt;
&lt;br /&gt;
The [http://www.php-fig.org/psr/ PHP-FIG standards] will be used:&lt;br /&gt;
* [http://www.php-fig.org/psr/psr-1/ PSR-1] and [http://www.php-fig.org/psr/psr-2/ PSR-2] Coding Standards&lt;br /&gt;
* [http://www.php-fig.org/psr/psr-3/ PSR-3] Logging API Standard&lt;br /&gt;
* [http://www.php-fig.org/psr/psr-4/ PSR-4] Auto-Loading Standard&lt;br /&gt;
* [http://www.php-fig.org/psr/psr-5/ PSR-5] PHPDoc Standard Proposal&lt;br /&gt;
* [http://www.php-fig.org/psr/psr-6/ PSR-6] Caching API Standard&lt;br /&gt;
* [http://symfony.com/doc/current/components/http_foundation.html Symfony HTTP Foundation] for interchangeable Request/Response objects&lt;br /&gt;
* [http://www.php-fig.org/psr/psr-7/ PSR-7] HTTP Message Interface for interchangeable Request/Response objects if required for some components&lt;br /&gt;
* HTML5 / CSS3 ES vTBD&lt;br /&gt;
* All files will be UTF8 using UNIX LF&lt;br /&gt;
&lt;br /&gt;
Plugins are available for Eclipse, Atom, and other IDEs to automatically check and/or apply these standards.&lt;br /&gt;
&lt;br /&gt;
== Framework and Components ==&lt;br /&gt;
&lt;br /&gt;
The chosen framework is the [http://silex.sensiolabs.org/ Silex] micro-framework built using [http://symfony.com/ Symphony] components, with a future upgrade path to the full Symfony Framework&lt;br /&gt;
&lt;br /&gt;
Components will be carefully chosen to be well supported, stable, and interchangeable wherever possible. A number of criteria will be applied in selection:&lt;br /&gt;
* Must be standards compliant&lt;br /&gt;
* Must be well supported with a solid development history&lt;br /&gt;
* Must be well documented&lt;br /&gt;
* Must be widely used and supported&lt;br /&gt;
* Must have a strong community, small one-person efforts will only be considered if they are the de-facto standard or a &amp;#039;well-known&amp;#039; developer&lt;br /&gt;
* Any database access must use Doctrine DBAL or ORM&lt;br /&gt;
&lt;br /&gt;
Significant and reliable sources of components include:&lt;br /&gt;
* [https://packagist.org/ Packagist], the Composer index &lt;br /&gt;
* [http://symfony.com/components Symfony]&lt;br /&gt;
* [http://thephpleague.com/#packages PHP League]&lt;br /&gt;
* [https://zendframework.github.io/ Zend]&lt;br /&gt;
* [http://docs.sylius.org/en/latest/components/index.html Sylius], components from an e-commerce platform based on Symfony&lt;br /&gt;
* [http://auraphp.com/ Aura]&lt;br /&gt;
* [https://github.com/silexphp/Silex/wiki/Third-Party-ServiceProviders-for-Silex-2.x Silex providers]&lt;br /&gt;
&lt;br /&gt;
== PHP Autoloading ==&lt;br /&gt;
&lt;br /&gt;
PSR-4 is used for packaging, namespace and auto-loading of code.&lt;br /&gt;
* [https://getcomposer.org/ Composer] will be required for dependency management and PSR-4 auto-loading&lt;br /&gt;
* All external libraries will be installed by Composer under vendor/&lt;br /&gt;
* All code to be Object Oriented and implemented using a namespace of ARK&lt;br /&gt;
* All code will be under src/&amp;lt;namespace&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A good series of articles explaining PSR-4 and modern development and packaging in general can be found at the following:&lt;br /&gt;
* http://culttt.com/2013/01/07/what-is-php-composer/&lt;br /&gt;
* http://culttt.com/2014/03/12/build-php-package/&lt;br /&gt;
* http://culttt.com/2014/05/07/create-psr-4-php-package/&lt;br /&gt;
&lt;br /&gt;
== Project Management ==&lt;br /&gt;
&lt;br /&gt;
The ARK project is hosted on [https://gitlab.com/ GitLab], so you will need a free GitLab account to contribute to development. Bug reports may be opened using a Google or Facebook account. The code is also mirrored on GitHub.&lt;br /&gt;
&lt;br /&gt;
The umbrella ARK project is organised under the [https://gitlab.com/arklab @arklab] group on GitLab, which includes the [https://gitlab.com/arklab/arkserver ARK Server] project. All public development and supported releases occur in this project repository. All code, issues, and wiki documentation on this project are public. All code contributions must pass formal code review before being merged. A separate GitLab group for [https://gitlab.com/lparchaeology L - P : Archaeology] manages private client forks and deployments of ARK Server.&lt;br /&gt;
&lt;br /&gt;
GitLab provides a very powerful web application for managing projects, but most local development is done using the standard git command line tools. If you are new to Git, you may find a desktop application easier to use. Options include [https://www.sourcetreeapp.com/ SourceTree], [https://www.gitkraken.com/ GitKraken], and [https://desktop.github.com/ Github desktop].&lt;br /&gt;
&lt;br /&gt;
=== Branching Strategy ===&lt;br /&gt;
&lt;br /&gt;
We will use a simplified version of the [https://wiki.qt.io/Branch_Guidelines Qt git workflow].&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;master&amp;#039;&amp;#039;&amp;#039; branch is the semi-stable development branch for the next release which should always be in a stable enough state to pass CI testing&lt;br /&gt;
* New feature or bugfix branches for the next release are branched off &amp;#039;&amp;#039;&amp;#039;master&amp;#039;&amp;#039;&amp;#039; prefixed with the name of the author/group/client and including the feature or bug number, e.g. &amp;#039;&amp;#039;&amp;#039;jlayt/linked-data&amp;#039;&amp;#039;&amp;#039; or &amp;#039;&amp;#039;&amp;#039;jlayt/issue-1234&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* Once a new feature is finished and passes testing, it is rebased onto the current &amp;#039;&amp;#039;&amp;#039;master&amp;#039;&amp;#039;&amp;#039; and merged via a merge request with review&lt;br /&gt;
* Alpha and Beta testing releases will be tagged on &amp;#039;&amp;#039;&amp;#039;master&amp;#039;&amp;#039;&amp;#039; and not branched&lt;br /&gt;
* Once &amp;#039;&amp;#039;&amp;#039;master&amp;#039;&amp;#039;&amp;#039; is deemed feature complete and stable enough for a Release Candidate then a release branch will be branched off &amp;#039;&amp;#039;&amp;#039;master&amp;#039;&amp;#039;&amp;#039; with the minor release number, e.g. &amp;#039;&amp;#039;&amp;#039;release/2.0&amp;#039;&amp;#039;&amp;#039;, &amp;#039;&amp;#039;&amp;#039;release/2.1&amp;#039;&amp;#039;&amp;#039;, etc&lt;br /&gt;
* Further testing will take place on the release branch, with fixes applied to to the release branch as required&lt;br /&gt;
* Once ready for release, the release will be tagged with the point release number (e.g. 2.0.0) and all bugfixes merged back into &amp;#039;&amp;#039;&amp;#039;master&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* Any bugfixes for the stable release will be made in the earliest release branch they apply to and then merged forward through each release then eventually into &amp;#039;&amp;#039;&amp;#039;master&amp;#039;&amp;#039;&amp;#039; (merges may be immediate or periodic depending on the volume)&lt;br /&gt;
* Bugfix branches for the stable release are branched off the release branch prefixed with the name of the branch and including the feature or bug number, e.g. &amp;#039;&amp;#039;&amp;#039;fix/2.1/issue-1234&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
For practical purposes during alpha development of ARK Server 2.0 a simplified approach will be used:&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;dev&amp;#039;&amp;#039;&amp;#039; branch is a temporary unstable development branch where code changes are developed&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;master&amp;#039;&amp;#039;&amp;#039; branch will occasionally be refreshed from &amp;#039;&amp;#039;&amp;#039;dev&amp;#039;&amp;#039;&amp;#039; with finished near-stable features&lt;br /&gt;
&lt;br /&gt;
=== Custom Forks ===&lt;br /&gt;
&lt;br /&gt;
The following approach is recommended for developing custom versions of ARK Server outside the main ARK Server project&lt;br /&gt;
* Create a new empty development repository&lt;br /&gt;
* Add the arklab/arkserver repository as a git remote&lt;br /&gt;
* Create a &amp;#039;&amp;#039;&amp;#039;dev&amp;#039;&amp;#039;&amp;#039; branch tracking a formal release branch on arklab/arkserver&lt;br /&gt;
* Create a &amp;#039;&amp;#039;&amp;#039;test&amp;#039;&amp;#039;&amp;#039; branch tracking the &amp;#039;&amp;#039;&amp;#039;dev&amp;#039;&amp;#039;&amp;#039; branch&lt;br /&gt;
* Create a &amp;#039;&amp;#039;&amp;#039;prod&amp;#039;&amp;#039;&amp;#039; branch tracking the &amp;#039;&amp;#039;&amp;#039;test&amp;#039;&amp;#039;&amp;#039; branch&lt;br /&gt;
* All custom code development occurs on the &amp;#039;&amp;#039;&amp;#039;dev&amp;#039;&amp;#039;&amp;#039; branch&lt;br /&gt;
* When custom code is stable for deployment to test server the &amp;#039;&amp;#039;&amp;#039;dev&amp;#039;&amp;#039;&amp;#039; branch is merged into the &amp;#039;&amp;#039;&amp;#039;test&amp;#039;&amp;#039;&amp;#039; branch&lt;br /&gt;
* When custom code is stable for deployment to production server the &amp;#039;&amp;#039;&amp;#039;test&amp;#039;&amp;#039;&amp;#039; branch is merged into the &amp;#039;&amp;#039;&amp;#039;prod&amp;#039;&amp;#039;&amp;#039; branch&lt;br /&gt;
* Production hotfixes can be developed on &amp;#039;&amp;#039;&amp;#039;prod&amp;#039;&amp;#039;&amp;#039; or a branch forked from &amp;#039;&amp;#039;&amp;#039;prod&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
* When a new ARK Server version is released the &amp;#039;&amp;#039;&amp;#039;dev&amp;#039;&amp;#039;&amp;#039; branch is rebased onto the new remote release branch for testing and then merged forward for testing&lt;br /&gt;
* Test server deployment is a clone of the dev repository checked-out to the &amp;#039;&amp;#039;&amp;#039;test&amp;#039;&amp;#039;&amp;#039; branch and rebased when new test releases occur. Test config settings may be committed to the repo here.&lt;br /&gt;
* Production server deployment is a clone of the dev repository checked-out to the &amp;#039;&amp;#039;&amp;#039;prod&amp;#039;&amp;#039;&amp;#039; branch and rebased when new production releases occur. Prod config settings may be committed to the repo here.&lt;br /&gt;
&lt;br /&gt;
The steps to set this up on GitLab are:&lt;br /&gt;
* Create the new project&lt;br /&gt;
* Create the dev branch tracking the arklab/arkserver release branch&lt;br /&gt;
* Create the test branch tracking the dev branch&lt;br /&gt;
* Create the prod branch tracking the test branch&lt;br /&gt;
* Protect the test and prod branches to allow only push/merge by Masters&lt;br /&gt;
&lt;br /&gt;
The git commands required to set this up on a local server:&lt;br /&gt;
* mkdir &amp;lt;project&amp;gt;&lt;br /&gt;
* cd &amp;lt;project&amp;gt;&lt;br /&gt;
* git init&lt;br /&gt;
* git remote add arklab git@gitlab.com:arklab/arkserver.git&lt;br /&gt;
* git fetch arklab&lt;br /&gt;
* git branch -t dev arklab/master&lt;br /&gt;
* git branch -t test dev&lt;br /&gt;
* git branch -t prod test&lt;br /&gt;
* git checkout dev&lt;br /&gt;
&lt;br /&gt;
== Folder Structure ==&lt;br /&gt;
&lt;br /&gt;
The following install root folder structure is used by ARK2, based on the default Silex and Composer structure, but adapted to support multi-site and multi-tenant.&lt;br /&gt;
&lt;br /&gt;
 /&lt;br /&gt;
 |- bin/&lt;br /&gt;
   |- sysadmin&lt;br /&gt;
 |- build/&lt;br /&gt;
   |- &amp;lt;see [[ARK2/Frontend|Frontend]]&amp;gt;&lt;br /&gt;
 |- sites/&lt;br /&gt;
 |- src/&lt;br /&gt;
 |- tests/&lt;br /&gt;
 |- var/&lt;br /&gt;
   |- cache/&lt;br /&gt;
   |- log/&lt;br /&gt;
 |- vendor/&lt;br /&gt;
&lt;br /&gt;
* The &amp;#039;bin&amp;#039; folder holds any executable binaries, primarily the sysadmin console script&lt;br /&gt;
* The &amp;#039;build&amp;#039; folder holds tools and source files for building [[ARK2/Frontend|frontends]]&lt;br /&gt;
* The &amp;#039;sites&amp;#039; folder holds the site specific files in a way that supports multi-site installs&lt;br /&gt;
* The &amp;#039;src&amp;#039; folder holds the namespaced source code, e.g. src/ARK, src/MySite, etc&lt;br /&gt;
* The &amp;#039;tests&amp;#039; folder holds the ARK auto-tests&lt;br /&gt;
* The &amp;#039;var&amp;#039; folder holds install-wide transitory files, such as caches and logs (site-specific go in the site folder)&lt;br /&gt;
* The &amp;#039;vendor&amp;#039; holds the component library code managed by Composer&lt;br /&gt;
&lt;br /&gt;
Tarball packaging for release will not include the &amp;#039;build&amp;#039;, &amp;#039;test&amp;#039;, or &amp;#039;vendor&amp;#039; folders.&lt;br /&gt;
&lt;br /&gt;
The ARK2 &amp;#039;src&amp;#039; folder is organised as follows:&lt;br /&gt;
&lt;br /&gt;
 /&lt;br /&gt;
 |- src/&lt;br /&gt;
   |- ARK/&lt;br /&gt;
     |- frontend/&lt;br /&gt;
       |- api/&lt;br /&gt;
       |- admin/&lt;br /&gt;
       |- core/&lt;br /&gt;
     |- server/&lt;br /&gt;
       |- php/&lt;br /&gt;
       |- schema/&lt;br /&gt;
         |- database/&lt;br /&gt;
         |- json/&lt;br /&gt;
   |- &amp;lt;project&amp;gt;/&lt;br /&gt;
     |- frontend/&lt;br /&gt;
       |- &amp;lt;custom&amp;gt;/&lt;br /&gt;
     |- server/&lt;br /&gt;
       |- &amp;lt;custom&amp;gt;/&lt;br /&gt;
&lt;br /&gt;
* The &amp;#039;src/ARK&amp;#039; folder holds the ARK Project specific code, this code is not intended for custom site code and will be over-written by any ARK update&lt;br /&gt;
* The &amp;#039;src/ARK/server&amp;#039; folder holds the ARK Server code, i.e. the backend code, API, database, etc&lt;br /&gt;
* The &amp;#039;src/ARK/frontend&amp;#039; folder holds the ARK Web Front-end code. See [[ARK2/Frontend|Frontend]] for more details.&lt;br /&gt;
* The &amp;#039;src/ARK/schema&amp;#039; folder holds the ARK Server data schemas, such as database table definitions, instance data models, etc&lt;br /&gt;
* The &amp;#039;src/&amp;lt;project&amp;gt;&amp;#039; folder would hold custom code where another project wishes to run their own multi-site install with a single custom frontend, see [[ARK2/Frontend|Frontend]] for more details&lt;br /&gt;
&lt;br /&gt;
The ARK2 &amp;#039;sites&amp;#039; folder is organised as follows:&lt;br /&gt;
&lt;br /&gt;
 /&lt;br /&gt;
 |- sites/&lt;br /&gt;
   |- &amp;lt;site&amp;gt;/&lt;br /&gt;
     |- bin/&lt;br /&gt;
       |- console&lt;br /&gt;
     |- config/&lt;br /&gt;
       |- credentials.json&lt;br /&gt;
       |- database.json&lt;br /&gt;
       |- site.json&lt;br /&gt;
     |- files&lt;br /&gt;
       |- &amp;lt;see [[ARK2/Files|Files]]&amp;gt;&lt;br /&gt;
     |- schema/&lt;br /&gt;
     |- templates/&lt;br /&gt;
       |- &amp;lt;frontend&amp;gt;/&lt;br /&gt;
     |- translations/&lt;br /&gt;
       |- &amp;lt;frontend&amp;gt;/&lt;br /&gt;
     |- var/&lt;br /&gt;
       |- cache/&lt;br /&gt;
       |- log/&lt;br /&gt;
     |- web/&lt;br /&gt;
       |- .htaccess&lt;br /&gt;
       |- index.php&lt;br /&gt;
       |- assets/&lt;br /&gt;
         |- &amp;lt;frontend&amp;gt;/&lt;br /&gt;
&lt;br /&gt;
* The &amp;#039;sites/&amp;lt;site&amp;gt;&amp;#039; folder holds all the custom files required for a site. This allows for multi-site installs, as well as a simple site backup/transfer strategy. The &amp;lt;site&amp;gt; name is recommended to be the reverse domain name for the site if unique (e.g. com.example.www) or the subfolder if using a shared domain (e.g. mysite).&lt;br /&gt;
* The &amp;#039;sites/&amp;lt;site&amp;gt;/bin&amp;#039; folder holds any site-specific executable binaries, primarily the site admin console script&lt;br /&gt;
* The &amp;#039;sites/&amp;lt;site&amp;gt;/config&amp;#039; folder holds all the configuration files for the site.&lt;br /&gt;
* The &amp;#039;sites/&amp;lt;site&amp;gt;/files&amp;#039; folder holds all the data files for the site, such as photos and documents. See [[ARK2/Files|Files]] for more details.&lt;br /&gt;
* The &amp;#039;sites/&amp;lt;site&amp;gt;/schema&amp;#039; folder holds the site specific JSON Schema files.&lt;br /&gt;
* The &amp;#039;sites/&amp;lt;site&amp;gt;/templates&amp;#039; folder holds the frontend template files.&lt;br /&gt;
* The &amp;#039;sites/&amp;lt;site&amp;gt;/translations&amp;#039; folder holds the frontend translation files.&lt;br /&gt;
* The &amp;#039;sites/&amp;lt;site&amp;gt;/web&amp;#039; folder is the webroot for the site, isolating the front-controller and assets in this folder improves security.&lt;br /&gt;
* The &amp;#039;sites/&amp;lt;site&amp;gt;/web/assets&amp;#039; folder holds the assets for the frontend(s), usually as a symlink back to the &amp;#039;src/ARK/web/&amp;lt;frontend&amp;gt;/assets&amp;#039; folder to allow for easy updates. See [[ARK2/Frontend|Frontend]] for more details.&lt;br /&gt;
&lt;br /&gt;
=== IDE ===&lt;br /&gt;
&lt;br /&gt;
While text editors and IDEs are a deeply personal choice, we recommend using Eclipse or [https://atom.io/ Atom] as they are cross-platform Open Source IDEs with powerful plugins to support the tools used by ARK. Using Eclipse or Atom ensures you have an environment consistent with the core ARK developers and ARK development standards.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Database</id>
		<title>ARK2/Database</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Database"/>
				<updated>2016-10-29T17:10:14Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Note: This page is very outdated and pending revision.&lt;br /&gt;
&lt;br /&gt;
= Database =&lt;br /&gt;
&lt;br /&gt;
In ARK1, PDO is used to directly access only MySQL databases, and DB access statements are widely spread through the code base and manually coded. While PDO abstracts the connection, it doesn&amp;#039;t abstract the SQL dialect so adding support for other databases such as Postgres or SQLite would require considerable work. It also makes migration to proper transaction support and performance improvements difficult, and is a security risk due to programmer error. &lt;br /&gt;
&lt;br /&gt;
A Database Abstraction Layer (DAL) can abstract away the differences in SQL between database systems, and also provide Query Builders, Schema Management, and Migration tools to address the other issues. Most are built on PDO and can seamlessly integrate with legacy code to make for an easier migration path. The [http://doctrine-orm.readthedocs.io/projects/doctrine-dbal/en/latest/ Doctrine DBAL] DAL has been selected due to it&amp;#039;s use in Symfony and the ORM extension being a Data Mapping ORM.&lt;br /&gt;
&lt;br /&gt;
== Database Abstraction ==&lt;br /&gt;
&lt;br /&gt;
Currently, PDO is used to directly access only MySQL databases, and DB access statements are widely spread through the code base and manually coded. While PDO abstracts the connection, it doesn&amp;#039;t abstract the SQL dialect so adding support for other databases such as Postgres or SQLite would require considerable work. It also makes migration to proper transaction support and performance improvements difficult, and is a security risk due to programmer error. A Database Abstraction Layer (DAL) can abstract away the differences in SQL between database systems, and also provide Query Builders, Schema Management, and Migration tools to address the other issues. Most are built on PDO and can seamlessly integrate with legacy code to make for an easier migration path.&lt;br /&gt;
&lt;br /&gt;
Longer term, full OO code, most frameworks, and many components use an ORM to map relational data to objects. A key part of choosing a framework or component eco-system is the ORM it uses. Most ORMs however use the Active Record pattern which cannot map onto the existing ARK data model. ARK would require a Data Mapper ORM to access the legacy database structure. While using multiple ORMs would be possible, it is not recommended due to performance overhead and potential contention.&lt;br /&gt;
&lt;br /&gt;
[http://www.doctrine-project.org/ Doctrine ORM] is the only PHP Data Mapper available, and is built on the [http://doctrine-orm.readthedocs.io/projects/doctrine-dbal/en/latest/ Doctrine DBAL] DAL. Doctrine is widely use and under active development, being the main ORM for the Symfony eco-system as well as many independent components. DBAL also provides the full set of required Drivers, Query Builder, Schema Management and Migration tools to abstract access to the required databases.&lt;br /&gt;
&lt;br /&gt;
Automated database creation and upgrade will be implemented using Doctrine Migrations:&lt;br /&gt;
* The core database schema will be defined in [http://andrewembler.com/2015/05/describe-parse-and-utilize-database-schemas-doctrine-xml/ doctrine-xml] (possibly initially reversed engineered from existing v1.x database). This schema will be stored in the build tools folder and will not be deployed.&lt;br /&gt;
* A custom Doctrine\DBAL\Migrations\Provider\SchemaProvider class will use the doctrine-xml schema to generate the full schema for new databases.&lt;br /&gt;
* A custom Doctrine\DBAL\Migrations\Provider\SchemaProvider class will use the doctrine-xml schema to generate schema diff to automatically create the Doctrine Migration class required for each version upgrade.&lt;br /&gt;
* The admin console will provide the standard migration tools (diff perhaps only from build console?)&lt;br /&gt;
* The ARK install script will call the doctrine tools to create the database&lt;br /&gt;
* If outstanding migrations are found after an upgrade, then the site will go into maintenance mode&lt;br /&gt;
&lt;br /&gt;
The creation of tables required for custom modules will be provided via API and not via the Migrations. This will be part of the data schema creation code and not the core database code.&lt;br /&gt;
&lt;br /&gt;
Multiple database connections within an ARK will be supported, with the database to be used by any data model passed in using dependency injection. This will improve the code used for import, export and migration. It will also allow for separate databases for the admin (user, config, etc) and the data which may assist with AaaS and Multi-tenancy.&lt;br /&gt;
&lt;br /&gt;
Database security will be tightly controlled to prevent security breaches in the AaaS model. There will be four levels of database account:&lt;br /&gt;
* Database Admin - Full admin account, credentials never stored on webserver, asked for by install script&lt;br /&gt;
* AaaS Admin - Limited admin account for AaaS client admin, only allowed to create new database and add required users, credentials never stored on webserver, passed in to install script by portal script&lt;br /&gt;
* ARK Admin - Limited admin account for ARK instance admin (create module tables only?), created by install script, credentials never stored on server, requested from user when needed (create modules, etc)&lt;br /&gt;
* ARK User - Limited user account for read/write data access only, created by install script, credentials stored on webserver&lt;br /&gt;
&lt;br /&gt;
== ID Generation ==&lt;br /&gt;
&lt;br /&gt;
A number of possible strategies exist for the allocation of Item numbers, which must be performed in a way abstracted from the database server used, and allowing for the use of offline mobile devices.&lt;br /&gt;
* Monotonically increasing sequence within any parent (default)&lt;br /&gt;
* Monotonically increasing sequence within any parent and within a predefined range determined by some compulsory attribute of the object, e.g. Trench Number&lt;br /&gt;
* Manually allocated IDs in any sequence, but still with the option for default monotonic IDs&lt;br /&gt;
&lt;br /&gt;
Due to the cascading of the generated ID throughout the database structure, the ID needs to be pre-allocated before the update can be performed. However, this risks leaving IDs allocated but unused should the actual update transaction be rolled back. The update to the sequence cannot be reversed, as it may have been further updated by another transaction. Instead such orphans will need to be tracked for later recycling.&lt;br /&gt;
&lt;br /&gt;
Taking all these factors into account, the ID Allocation will function as follows:&lt;br /&gt;
* On creation of a new Item, the Entity Manager will be called to create a new ID&lt;br /&gt;
* The EM will decide which sequence to use for the ID&lt;br /&gt;
* The EM creates a new update transaction on the database and looks in the sequence lock table for any IDs to be recycled&lt;br /&gt;
* If there is one to be recycled, it is updated to locked and the ID returned&lt;br /&gt;
* If there are none to be recycled, then the EM updates the sequence in the sequence table, creates a new sequence lock entry, and returns the allocated ID&lt;br /&gt;
* When the EM performs the actual persistence of the object, then the sequence lock will be deleted&lt;br /&gt;
* If the insert transactions fails and is rolled back, then the EM will update the sequence lock to be recycled&lt;br /&gt;
&lt;br /&gt;
For offline mobile use, there are two possible strategies:&lt;br /&gt;
* Where the ID carries no inherent meaning, or is not used in the field, then a temporary hidden ID can be used until sync when real IDs are allocated using the standard method above&lt;br /&gt;
* Where the ID has meaning and is used in the field, such  as numbering context bags or sample buckets, then the real IDs will have to be pre-allocated to the mobile device&lt;br /&gt;
&lt;br /&gt;
The API will provide a method for a mobile device to &amp;#039;check-out&amp;#039; a block of numbers for use, and the ability to check them back in again:&lt;br /&gt;
* The device requests a new block of IDs&lt;br /&gt;
* The EM creates a new update transaction on the database, updates the sequence table, and creates an entry in the sequence reserve table for the allocated range with a token which is returned to the device&lt;br /&gt;
* The device uses the allocated range when creating new items&lt;br /&gt;
* If the device runs out of IDs the user is warned that subsequent IDs may be duplicated&lt;br /&gt;
* On syncing, the device tells the API what ID it allocated and the token of the reserved sequence&lt;br /&gt;
* On inserting, the EM uses the sequence reserve table instead of the main sequence table to track the IDs&lt;br /&gt;
* If the device attempts to use IDs outside the reserved sequence then and those IDs are free, then they will be allowed, otherwise the updates will be rejected/quarantined&lt;br /&gt;
* When the sync is finished, the user will be asked if they want to recycle any left-over IDs, or if they want more allocated&lt;br /&gt;
&lt;br /&gt;
== Chains ==&lt;br /&gt;
&lt;br /&gt;
Chains are a technique in ARK for storing hierarchical tree data in relation form. This is done using an adjacency table method. This is a problem in ARK2 for a number of reasons:&lt;br /&gt;
* Knowledge of when data is stored in chains is held solely in the subform code that creates or reads the chain, which causes issues when the schema will need to represent the data structure without the subform&lt;br /&gt;
* Chains are an internal implementation detail, their existence should not &amp;#039;leak&amp;#039; into the schema or api for external clients, they must be free to choose their own storage solution&lt;br /&gt;
* Access to chains can be slow and inefficient, especially walking down a tree when you don&amp;#039;t know how &amp;#039;wide&amp;#039; it is (i.e. what data fragments it has as descendants).&lt;br /&gt;
&lt;br /&gt;
The data schema will not represent data as chains, trees or graphs. Instead the schema will merely represent the inherent hierarchical structure of the data using groups/objects/lists. The data persistence layer will know to persist those repeating groups in its model. In the case of the current ARK SQL database this means repeating groups will need to be stored as chains.&lt;br /&gt;
&lt;br /&gt;
A number of other techniques exist to make reading/writing of trees faster, such as Nested Sets. The Closure Table technique has been chosen for a number of reasons:&lt;br /&gt;
* Is a simple extension to the existing Adjacency Table method&lt;br /&gt;
* Is fast to both read and write&lt;br /&gt;
* An entire tree can be read with a single SQL query&lt;br /&gt;
* Supports storing DAGs, i.e. Harris Matrix&lt;br /&gt;
&lt;br /&gt;
The proposed implementation will be:&lt;br /&gt;
* Chains may be renamed as Graphs?&lt;br /&gt;
* Nodes and Edges are stored separately&lt;br /&gt;
* The Nodes in a Graph are either Items or Fragments, but not both&lt;br /&gt;
* The Nodes continue to be stored in their current tables&lt;br /&gt;
* Edges are stored in a new ark_data_graph table&lt;br /&gt;
* Item Graphs store their itemkey/itemvalue Edges in the ark_data_graph table&lt;br /&gt;
* Fragment Graphs store their table/id Edges in the ark_data_graph table&lt;br /&gt;
* Descendent Fragment Nodes will no longer be keyed by their direct parent table/id, but will instead be keyed by their root itemkey/itemvalue. This allows faster access to all nodes, and means the nodes never need to be updated whenever the graph is altered.&lt;br /&gt;
* Root Fragment Nodes may need to carry a flag to indicate they are a root, otherwise a lookup is required every time on the graph table.&lt;br /&gt;
&lt;br /&gt;
New code will be needed to create and maintain graphs in place of the current chain code. Migration code will be required to build the graph for existing data and update the nodes.&lt;br /&gt;
&lt;br /&gt;
References:&lt;br /&gt;
* SQL Anti-patterns book&lt;br /&gt;
* http://technobytz.com/closure_table_store_hierarchical_data.html&lt;br /&gt;
* http://people.apache.org/~dongsheng/horak/100309_dag_structures_sql.pdf&lt;br /&gt;
* http://timwi.blogspot.co.uk/2010/03/query-tree-structures-and-dags-in-sql.html&lt;br /&gt;
* http://dirtsimple.org/2010/11/simplest-way-to-do-tree-based-queries.html&lt;br /&gt;
* http://mikehillyer.com/articles/managing-hierarchical-data-in-mysql/&lt;br /&gt;
* https://github.com/Atlantic18/DoctrineExtensions/blob/master/doc/tree.md&lt;br /&gt;
* https://github.com/EspadaV8/ClosureTable&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2/Localization</id>
		<title>ARK2/Localization</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2/Localization"/>
				<updated>2016-10-29T16:46:30Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Localization */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Localization =&lt;br /&gt;
&lt;br /&gt;
Localization is the process of translating the user interface and data into the language and formats of the user.&lt;br /&gt;
&lt;br /&gt;
ARK2 uses the following components for localization and translation:&lt;br /&gt;
* The [http://symfony.com/doc/current/components/intl.html Symfony Intl] component as a wrapper for the [http://php.net/manual/en/book.intl.php PHP Intl] extension and ICU, for collation, formatting and parsing&lt;br /&gt;
* The [http://symfony.com/doc/current/components/translation.html Symfony Translation] component for translation&lt;br /&gt;
* The standard JS [https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl Intl API], or the [https://github.com/andyearnshaw/Intl.js Intl Polyfill] where Intl is not available&lt;br /&gt;
&lt;br /&gt;
== Translation ==&lt;br /&gt;
&lt;br /&gt;
* Translations are stored in the core database&lt;br /&gt;
* Translations are exported into XLIFF file format, allowing offline apps to download the full catalogue&lt;br /&gt;
* Translations uses keys rather than source strings&lt;br /&gt;
* Translations will be split in a number of catalogues:&lt;br /&gt;
** Vocabulary&lt;br /&gt;
** Core interface&lt;br /&gt;
** User interface&lt;br /&gt;
** Admin interface&lt;br /&gt;
** Schema (one for each created)&lt;br /&gt;
* Actor and User IDs are translated live using a custom loader from the database&lt;br /&gt;
&lt;br /&gt;
The Admin Interface provides a basic interface for the maintaining of translation. Export and import interfaces are provided for the chosen online translation community.&lt;br /&gt;
&lt;br /&gt;
== Translation Workflow ==&lt;br /&gt;
&lt;br /&gt;
Translation workflow will have two modes, Debug and Live.&lt;br /&gt;
* In Debug mode, the database is the canonical source for translations&lt;br /&gt;
* In Live mode, the XLIFF files are the canonical source&lt;br /&gt;
&lt;br /&gt;
In Debug mode:&lt;br /&gt;
* Translations can be disabled in the site.json file for testing or development purposes&lt;br /&gt;
* Translations are loaded live from the database&lt;br /&gt;
* Translation Admin page shows stats, allows editing of translations, and import/export to XLIFF (also to translation website)&lt;br /&gt;
* Translation extractors can be run to extract the used keys from code files&lt;br /&gt;
* Translations can be edited in the Translation Profiler page&lt;br /&gt;
** Profiler bar shows translation stats for the page&lt;br /&gt;
** Profiler page allows live editing of translations used on the page with persistence back to the database and flagging as fuzzy&lt;br /&gt;
&lt;br /&gt;
In Live mode:&lt;br /&gt;
* Translations are always active, sites.json disable is ignored&lt;br /&gt;
* Translations are loaded from the XLIFF files, database is only used for Actors/Users&lt;br /&gt;
* Translation Admin page is available, but changes do not take effect until exported to XLIFF&lt;br /&gt;
&lt;br /&gt;
== Development Required ==&lt;br /&gt;
&lt;br /&gt;
No existing package supports our requirements so we will need to fork a number of existing projects (see below):&lt;br /&gt;
* Translation extractors&lt;br /&gt;
* Translation admin page&lt;br /&gt;
* Translation Profiler page&lt;br /&gt;
&lt;br /&gt;
== Design Decisions To Be Made ==&lt;br /&gt;
&lt;br /&gt;
Potential online portals include:&lt;br /&gt;
* [https://www.transifex.com Transifex] - Market leader, but now closed source, offers free hosting to open source projects, large community, great features and automated workflow, API, Github integration, etc.&lt;br /&gt;
* [http://zanata.org/ Zanata] - A Red Hat open-source project (in response to Transifex going closed) with free hosting and large existing community, or can be self-hosted (JBoss based), great features and automated workflow, API, Github integration, etc. No RTL?&lt;br /&gt;
* [https://weblate.org/en/features/ Weblate] - An open-source project with free and paid-for hosting, but no central community, or can be self-hosted, good features, API, Github integration, etc. Django based.&lt;br /&gt;
* https://localise.biz/ Free or GBP5 p/m plan may be enough, good api, Symfony bundle&lt;br /&gt;
* [http://translationproject.org/html/welcome.html Translation Project] - A FSF open-source project with free hosting and large existing community, but very basic features and manual workflow.&lt;br /&gt;
* [http://pootle.translatehouse.org/index.html Pootle] - An open-source project, self-hosted, Django based&lt;br /&gt;
&lt;br /&gt;
Zanata would seem the preferred option for a hosted service, but Weblate might be better if self-hosting.&lt;br /&gt;
&lt;br /&gt;
A number of options exist for automating extraction of Symfony translations, or for allowing interactive editing inside the admin panel or profiler panel:&lt;br /&gt;
* https://jolicode.com/blog/translation-workflow-with-symfony2&lt;br /&gt;
* https://developer.happyr.com/how-happyr-work-with-symfony-translations&lt;br /&gt;
* https://github.com/deanc/silex-web-translator&lt;br /&gt;
* https://github.com/Aecf/TranslatorToolBundle&lt;br /&gt;
* https://github.com/instaclick/TranslationEditorBundle&lt;br /&gt;
* https://github.com/lexik/LexikTranslationBundle&lt;br /&gt;
* https://github.com/manuelj555/ManuelTranslationBundle&lt;br /&gt;
* https://github.com/Happyr/TranslationBundle&lt;br /&gt;
* http://jmsyst.com/bundles/JMSTranslationBundle&lt;br /&gt;
&lt;br /&gt;
None of these quite match our requirements, but may be adapted to achieve our workflow.&lt;br /&gt;
&lt;br /&gt;
Translations in javascript:&lt;br /&gt;
* https://github.com/willdurand/BazingaJsTranslationBundle&lt;br /&gt;
* https://github.com/wikimedia/jquery.i18n&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/QGIS/ARK_Grid</id>
		<title>QGIS/ARK Grid</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/QGIS/ARK_Grid"/>
				<updated>2016-08-09T13:06:27Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* ARK Grid */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= ARK Grid =&lt;br /&gt;
&lt;br /&gt;
A QGIS Plugin to create and work with local site grids as commonly used in archaeology.&lt;br /&gt;
&lt;br /&gt;
A grid wizard allows you to create grids from two known points, or from a known origin and baseline. Interactive tools are provided to convert between local coordinates and map coordinates.&lt;br /&gt;
&lt;br /&gt;
[[File:ark_grid.png|center|link=|ARK Grid - Panel]]&lt;br /&gt;
&lt;br /&gt;
For details on installation, support, licensing, and development, please see the main [[QGIS|ARK QGIS plugins page]]&lt;br /&gt;
&lt;br /&gt;
== Settings Wizard ==&lt;br /&gt;
&lt;br /&gt;
To use &amp;#039;&amp;#039;ARK Grid&amp;#039;&amp;#039; click on the &amp;#039;&amp;#039;ARK Grid&amp;#039;&amp;#039; icon in the main toolbar.&lt;br /&gt;
&lt;br /&gt;
[[File:grid_icon.png|center|link=|ARK Grid - Logo]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If you have not run &amp;#039;&amp;#039;ARK Grid&amp;#039;&amp;#039; before then the &amp;#039;&amp;#039;Settings Wizard&amp;#039;&amp;#039; will be run to set up the required grid layers. Your chosen settings will be written into your current QGIS project, you must save your project after the wizard has run otherwise your settings will be lost. If you do not save your settings then the wizard will run again and you will be able to setup where your layers are already saved.&lt;br /&gt;
&lt;br /&gt;
[[File:grid_wizard1.png|center|link=|ARK Grid - Project Wizard Page 1]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Choose where your project home folder is located. If your QGIS project already has a project home folder set then this will be shown as the default folder. The &amp;#039;&amp;#039;ARK Grid&amp;#039;&amp;#039; layers will be saved in the Project Folder in a subfolder &amp;#039;vector/grid&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
[[File:grid_wizard2.png|center|link=|ARK Grid - Project Wizard Page 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Choose what you want to name the grid layers and layer group, recommended default names are provided. You must have a grid point layer to use for the calculations, but the line and polygon layers are optional.&lt;br /&gt;
&lt;br /&gt;
[[File:grid_wizard3.png|center|link=|ARK Grid - Project Wizard Page 3]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
On clicking Done the required folders and files will be created if they do not already exist. Existing files will &amp;#039;&amp;#039;&amp;#039;never&amp;#039;&amp;#039;&amp;#039; be overwritten. The layers will then be added to the project &amp;#039;&amp;#039;Layers Panel&amp;#039;&amp;#039; and the &amp;#039;&amp;#039;ARK Grid Panel&amp;#039;&amp;#039; will be displayed. Only the &amp;#039;&amp;#039;Create New Grid&amp;#039;&amp;#039; tool will be enabled at this stage.&lt;br /&gt;
&lt;br /&gt;
[[File:grid_layers.png|center|link=|ARK Grid - New Layers]]&lt;br /&gt;
&lt;br /&gt;
[[File:grid_panel_new.png|center|link=|ARK Grid - New Panel]]&lt;br /&gt;
&lt;br /&gt;
== New Grid Wizard ==&lt;br /&gt;
&lt;br /&gt;
To create a new grid, click on the &amp;#039;&amp;#039;Create New Grid&amp;#039;&amp;#039; tool.&lt;br /&gt;
&lt;br /&gt;
[[File:grid_new_icon.png|center|link=|ARK Grid - Create New Grid Icon]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:grid_wizard_new1.png|center|link=|ARK Grid - New Grid Wizard Page 1]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:grid_wizard_new2.png|center|link=|ARK Grid - New Grid Wizard Page 2]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:grid_wizard_new3.png|center|link=|ARK Grid - New Grid Wizard Page 3]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:grid_wizard_new4.png|center|link=|ARK Grid - New Grid Wizard Page 4]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:grid_new.png|800px|center|link=|ARK Grid - New Grid]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Grid Tools ==&lt;br /&gt;
&lt;br /&gt;
Once you have created a valid grid, all the &amp;#039;&amp;#039;Grid Tools&amp;#039;&amp;#039; will be enabled.&lt;br /&gt;
&lt;br /&gt;
[[File:grid_panel_full.png|center|link=|ARK Grid - Grid Panel]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; Current Grid Dropdown&lt;br /&gt;
: If you create more than one grid, you can switch between grids using the grid selection dropdown box. Only the selected grid is displayed and used in calculations.&lt;br /&gt;
&lt;br /&gt;
[[File:grid_grid_combo.png|center|link=|ARK Grid - Choose Grid Combo]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; Map Point Entry&lt;br /&gt;
: The &amp;#039;&amp;#039;Map Point&amp;#039;&amp;#039; input boxes display the currently calculated Map Point. You can manually enter a Map Point and the Local Point will be automatically updated.&lt;br /&gt;
&lt;br /&gt;
[[File:grid_map_entry.png|center|link=|ARK Grid - Map Point Entry]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; Local Point Entry&lt;br /&gt;
: The &amp;#039;&amp;#039;Local Point&amp;#039;&amp;#039; input boxes display the currently calculated Local Point. You can manually enter a Local Point and the Map Point will be automatically updated.&lt;br /&gt;
&lt;br /&gt;
[[File:grid_local_entry.png|center|link=|ARK Grid - Local Point Entry]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; [[File:grid_tool_icon.png|link=|ARK Grid - Identify Grid Coordinates Tool]] Identify Grid Coordinates Tool&lt;br /&gt;
: The &amp;#039;&amp;#039;Identify Grid Coordinates&amp;#039;&amp;#039; tool allows you to click on the map and have the Map Point and Local Point coordinates displayed for the point clicked on.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; [[File:grid_pan_icon.png|link=|ARK Grid - Pan Map Tool]] Pan Map Tool&lt;br /&gt;
: The &amp;#039;&amp;#039;Pan Map&amp;#039;&amp;#039; tool will pan the map to the currently entered Map Point.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; [[File:grid_paste_icon.png|link=|ARK Grid - Paste Map Point Tool]] Paste Map Point Tool&lt;br /&gt;
: The &amp;#039;&amp;#039;Paste Map Point&amp;#039;&amp;#039; tool will paste a Map Point in WKT format from the clipboard. This can be used to copy a point from a layer in QGIS.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; [[File:grid_point_icon.png|link=|ARK Grid - Add Point Tool]] Add Point Tool&lt;br /&gt;
: The &amp;#039;&amp;#039;Add Point&amp;#039;&amp;#039; tool adds the current Map Point to the currently selected layer if it is a vector point layer in editing mode.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; [[File:grid_update_icon.png|link=|ARK Grid - Update Layer Coordinates Tool]] Update Layer Coordinates Tool&lt;br /&gt;
: The &amp;#039;&amp;#039;Update Layer Coordinates&amp;#039;&amp;#039; tool shows a dialog to let you update a point vector layer to either add the local coordinates as attribute fields or to set the map point from local coordinate attribute fields.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; [[File:grid_settings_icon.png|link=|ARK Grid - Run Settings Wizard Tool]] Run Settings Wizard Tool&lt;br /&gt;
: The &amp;#039;&amp;#039;Run Settings Wizard&amp;#039;&amp;#039; tool will run the settings wizard.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
; [[File:grid_copy_icon.png|link=|ARK Grid - Copy Point Tool]] Copy Point Tool&lt;br /&gt;
: The &amp;#039;&amp;#039;Copy Point&amp;#039;&amp;#039; tool will copy the Map Point or Local Point to the clipboard in WKT format.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Layer Styles ==&lt;br /&gt;
&lt;br /&gt;
The plugin ships with a default set of style files for the grid layers. If you wish to modify the styles, simply save your modified style files into your grid folder with the same names as your grid layers.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/QGIS</id>
		<title>QGIS</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/QGIS"/>
				<updated>2016-08-09T11:11:09Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Setup */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= QGIS =&lt;br /&gt;
&lt;br /&gt;
[http://www.qgis.org/en/site/about/index.html QGIS] is a powerful, user friendly, free and Open Source Geographic Information System (GIS). It runs on Windows, Mac OS X, Linux, Unix, and Android and supports numerous vector, raster, and database formats and functionalities.&lt;br /&gt;
&lt;br /&gt;
At L ~ P : Archaeology we exclusively use QGIS for all our GIS requirements and have developed a number of plugins to support archaeological projects and to integrate with ARK Database. We have released some of these plugins for all archaeologists to benefit from and will release more over time.&lt;br /&gt;
&lt;br /&gt;
Currently these plugins are hosted in our beta testing repository and are marked as experimental, but once stable will be submitted to the main QGIS repository. You are welcome to try out these plugins and to provide feedback, but please be aware that they are in beta and so may still have some bugs. To provide feedback, either open an issue on the plugin&amp;#039;s GitHub issue tracker, or email ark@lparchaeology.com.&lt;br /&gt;
&lt;br /&gt;
== Development ==&lt;br /&gt;
&lt;br /&gt;
Development of these plugins is sponsored by [http://www.lparchaeology.com/cms/ L ~ P : Archaeology] using the Free Software philosophy and Open Source development methodologies. All of the code is developed in the open on [https://github.com/lparchaeology/ GitHub] and contributions from other interested parties are always welcome. If you would like to commission or sponsor development of new features or plugins then please contact us.&lt;br /&gt;
&lt;br /&gt;
== Support ==&lt;br /&gt;
&lt;br /&gt;
The plugins offered here are in beta and no warranty or support is offered for them. That said, we are keen to receive feedback on the plugins and will respond as best we can. We plan to set up appropriate community support channels in the future. In the meantime, you can raise issues via the appropriate GitHub page, or email us at ark@lparchaeology.com.&lt;br /&gt;
&lt;br /&gt;
== Licence ==&lt;br /&gt;
&lt;br /&gt;
All L ~ P : Archaeology plugins are developed under the [https://simple.wikipedia.org/wiki/GNU_General_Public_License GPL2 licence], the same as QGIS itself and all plugins in the main QGIS repository. The GPL allows you to freely use and modify the plugin as you wish, provided you share with the community any improvements to the code you might distribute. Share and share alike, it&amp;#039;s only fair.&lt;br /&gt;
&lt;br /&gt;
== Setup ==&lt;br /&gt;
&lt;br /&gt;
To install the plugins you need to add the L ~ P : Archaeology QGIS Plugins repository in your QGIS plugins settings.&lt;br /&gt;
&lt;br /&gt;
* From the &amp;#039;&amp;#039;Plugins&amp;#039;&amp;#039; menu choose &amp;#039;&amp;#039;Manage and Install Plugins&amp;#039;&amp;#039;&lt;br /&gt;
* In the &amp;#039;&amp;#039;Plugins&amp;#039;&amp;#039; window choose the &amp;#039;&amp;#039;Settings&amp;#039;&amp;#039; tab&lt;br /&gt;
* Select the &amp;#039;&amp;#039;Show also experimental plugins&amp;#039;&amp;#039; option&lt;br /&gt;
* Select the &amp;#039;&amp;#039;Add...&amp;#039;&amp;#039; button&lt;br /&gt;
* Add the new repository details with the name &amp;#039;&amp;#039;ARK Plugins&amp;#039;&amp;#039; and a URL of &amp;#039;&amp;#039;https://plugins.lparchaeology.com/qgis/plugins.xml&amp;#039;&amp;#039;&lt;br /&gt;
* After clicking &amp;#039;&amp;#039;OK&amp;#039;&amp;#039; the repository will be loaded and the new plugins will be listed in the &amp;#039;&amp;#039;New&amp;#039;&amp;#039; tab&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The &amp;#039;&amp;#039;Plugins Settings&amp;#039;&amp;#039; dialog should look similar to this before adding the ARK repository:&lt;br /&gt;
&lt;br /&gt;
[[File:qgis_plugins.png|600px|center|QGIS Plugin Settings]]&lt;br /&gt;
&lt;br /&gt;
The &amp;#039;&amp;#039;Repository Details&amp;#039;&amp;#039; dialog should look similar to this:&lt;br /&gt;
&lt;br /&gt;
[[File:qgis_repo.png|center|QGIS Repository Settings]]&lt;br /&gt;
&lt;br /&gt;
== Available Plugins ==&lt;br /&gt;
&lt;br /&gt;
The following plugins are currently available in the repository.&lt;br /&gt;
&lt;br /&gt;
=== ARK Clone ===&lt;br /&gt;
&lt;br /&gt;
A QGIS Plugin to clone existing vector layers including styles as shapefiles or temporary memory layers.&lt;br /&gt;
&lt;br /&gt;
This plugin adds an option to the legend context menu and the main vector menu to clone the current layer. Users can choose to clone just the layer structure, just the selected features, or all the features.&lt;br /&gt;
&lt;br /&gt;
Development of &amp;#039;&amp;#039;ARK Clone&amp;#039;&amp;#039; is hosted on GitHub at https://github.com/lparchaeology/ArkClone. You can open an issue at https://github.com/lparchaeology/ArkClone/issues, or email ark@lparchaeology.com.&lt;br /&gt;
&lt;br /&gt;
=== ARK Grid ===&lt;br /&gt;
&lt;br /&gt;
A QGIS Plugin to create and work with local site grids as commonly used in archaeology.&lt;br /&gt;
&lt;br /&gt;
A grid wizard allows you to create grids from two known points, or from a known origin and baseline. Interactive tools are provided to convert between local coordinates and map coordinates.&lt;br /&gt;
&lt;br /&gt;
[[File:ark_grid.png|center|ARK Grid Panel]]&lt;br /&gt;
&lt;br /&gt;
Detailed documentation can be found on the [[QGIS/ARK_Grid|ARK Grid page]].&lt;br /&gt;
&lt;br /&gt;
Development of &amp;#039;&amp;#039;ARK Grid&amp;#039;&amp;#039; is hosted on GitHub at https://github.com/lparchaeology/ArkGrid. You can open an issue at https://github.com/lparchaeology/ArkGrid/issues, or email ark@lparchaeology.com.&lt;br /&gt;
&lt;br /&gt;
== Future Plugins ==&lt;br /&gt;
&lt;br /&gt;
The following plugins are currently under development.&lt;br /&gt;
&lt;br /&gt;
=== ARK Snapping ===&lt;br /&gt;
&lt;br /&gt;
A QGIS Plugin to speed-up snapping configuration.&lt;br /&gt;
&lt;br /&gt;
This plugin is currently in alpha and will be released as beta shortly.&lt;br /&gt;
&lt;br /&gt;
Main Toolbar buttons allow you to quickly switch between All Layers, Current Layer, and Selected Layers, and to toggle Intersection Snapping and Topological Editing:&lt;br /&gt;
&lt;br /&gt;
[[File:ark_snap_main.png|center|ARK Snapping Toolbar Buttons]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
When in Selected Layers mode, the Layer Context Menu allows you to configure snapping on the selected layers.&lt;br /&gt;
&lt;br /&gt;
[[File:ark_snap.png|center|ARK Snapping Layer Context Menu]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In Selected Layers mode, a new panel will list all selected layers and allow for more detailed configuration. This has yet to be implemented.&lt;br /&gt;
&lt;br /&gt;
A custom version of the panel is implemented in ARK Spatial, the action buttons for each layer will be changed to a list of layer names, with buttons to add/remove available layers.&lt;br /&gt;
&lt;br /&gt;
[[File:ark_snap_panel.png|center|ARK Snapping Layer Panel]]&lt;br /&gt;
&lt;br /&gt;
=== ARK Spatial ===&lt;br /&gt;
&lt;br /&gt;
A QGIS Plugin to record and query archaeological spatial data.&lt;br /&gt;
&lt;br /&gt;
This plugin is currently in alpha and will be released as beta shortly.&lt;br /&gt;
&lt;br /&gt;
Features include:&lt;br /&gt;
* Simplified geo-referencing of permatrace to a site grid or baseline&lt;br /&gt;
* Rapid digitising of archaeological plans and sections using MoLAS drawing conventions&lt;br /&gt;
* Powerful query and filter tools working at Context level&lt;br /&gt;
* Post-excavation checking workflow and reports&lt;br /&gt;
* Live data link to an ARK Database&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:ark_spatial.png|800px|center|ARK Spatial]]&lt;br /&gt;
&lt;br /&gt;
=== ARK Georeferencer ===&lt;br /&gt;
&lt;br /&gt;
A QGIS Plugin to georeference permatrace to a site grid.&lt;br /&gt;
&lt;br /&gt;
This plugin is currently part of ARK Spatial but may be released as a separate plugin.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File:ark_georef.png|800px|center|ARK Georeferencer]]&lt;br /&gt;
&lt;br /&gt;
== Library for Plugin Developers ==&lt;br /&gt;
&lt;br /&gt;
Many common functions and classes needed in the development of QGIS plugins have been aggregated into a common library [https://github.com/lparchaeology/libarkqgis libarkqgis] that is reused by all our plugins. Other plugin developers may find this library useful, although we do not provide a stable API guarantee as yet or a even a stable release branch.&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/ARK2</id>
		<title>ARK2</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/ARK2"/>
				<updated>2016-02-03T12:01:50Z</updated>
		
		<summary type="html">&lt;p&gt;John Layt: /* Aims */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page details the progress on development of ARK 2.0&lt;br /&gt;
&lt;br /&gt;
== Aims ==&lt;br /&gt;
&lt;br /&gt;
The primary aims of ARK2 are:&lt;br /&gt;
* Full code re-write to modern standards using modern components&lt;br /&gt;
* Separate the ARK Database backend from the ARK Web frontend&lt;br /&gt;
* Implement a modern REST API to allow other frontends and apps to access and update the ARK Database&lt;br /&gt;
* Simplify the setup and configuration of ARK by moving the config into the database and providing online config tools&lt;br /&gt;
* Improve the overall performance and data integrity of ARK&lt;br /&gt;
* Make it possible to provide an ARK hosting service&lt;br /&gt;
&lt;br /&gt;
Modern frontend&lt;br /&gt;
* HTML5&lt;br /&gt;
* Bootstrap based&lt;br /&gt;
* Twig templates&lt;br /&gt;
* Front Controller model&lt;br /&gt;
* Config driven pages views&lt;br /&gt;
&lt;br /&gt;
Modern backend&lt;br /&gt;
* Full REST API to access and update all ARK data&lt;br /&gt;
* Database abstraction and Object Relational Mapping&lt;br /&gt;
* Config driven data schema&lt;br /&gt;
* Controlled Vocabularies and Linked Open Data&lt;br /&gt;
* User Authentication via internal user/password and external OAuth2 providers (Facebook, Google, etc)&lt;br /&gt;
* User Authorisation via Role Based Access Control (RBAC) using hierarchical Roles and Permissions structure&lt;br /&gt;
* Field-level data access control&lt;br /&gt;
* Data Workflows in conjunction with User Authorisation control&lt;br /&gt;
&lt;br /&gt;
== Documentation ==&lt;br /&gt;
&lt;br /&gt;
Details of ARK2 can be found in the following sections:&lt;br /&gt;
&lt;br /&gt;
* [[ARK2/Design|Design]] - High Level Design Decisions&lt;br /&gt;
* [[ARK2/Technical|Technical]] - Technical details, Development tools and procedures&lt;br /&gt;
* [[ARK2/The_ARK_Way|The ARK Way]] - Web Development - The ARK2 Way&lt;br /&gt;
* [[ARK2/Install|Install]] - Installation Instructions&lt;br /&gt;
* [[ARK2/Architecture|Architecture]] - System Architecture&lt;br /&gt;
* [[ARK2/Database|Database]] - Database / ORM details&lt;br /&gt;
* [[ARK2/Cache|Cache]] - Cache details&lt;br /&gt;
* [[ARK2/Model|Model]] - Data model / Schema&lt;br /&gt;
* [[ARK2/View|View]] - Views on the Data Model&lt;br /&gt;
* [[ARK2/Spatial|Spatial]] - Spatial data&lt;br /&gt;
* [[ARK2/Vocabulary|Vocabulary]] - Controlled Vocabularies&lt;br /&gt;
* [[ARK2/Files|File Management]] - File, Image, and other Media Management&lt;br /&gt;
* [[ARK2/Localization|Localization]] - Internationalization, Localization, and Translation&lt;br /&gt;
* [[ARK2/Security|Security]] - Security, Authentication, Authorisation, User Management&lt;br /&gt;
* [[ARK2/API|API]] - REST API implementation&lt;br /&gt;
* [[ARK2/Frontend|Frontend]] - Web Frontend&lt;br /&gt;
* [[ARK2/Templates|Templates]] - Using Twig for the Web Frontend&lt;br /&gt;
* [[ARK2/Console|Console]] - Admin Consoles&lt;br /&gt;
* [[ARK2/Admin|Admin]] - Admin Frontend&lt;br /&gt;
* [[ARK2/Branding|Branding]] - Branding of the ARK Project, Products, and Service&lt;/div&gt;</summary>
		<author><name>John Layt</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/Sf_chaintable</id>
		<title>Sf chaintable</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/Sf_chaintable"/>
				<updated>2015-10-12T16:24:37Z</updated>
		
		<summary type="html">&lt;p&gt;Mike: /* Example Configuration */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;===Description===&lt;br /&gt;
&lt;br /&gt;
sf_chaintable can be used for displaying and editing data fragments that are chained to other data fragments. One &amp;#039;root&amp;#039; field is linked to the item being viewed, which may have one or more fragments per item creating rows for the table and then one or more fragments can be chained to these to create additional columns. Examples of this include attaching numbers to find attributes - mirroring and supplements [[sf_assemblage]] for linking usage to periods of sites, or for levels tables.&lt;br /&gt;
&lt;br /&gt;
By default the chaintable hides any empty columns. As of version 1.2 the new records feature is incomplete and only some of the edit functions are supported - numbers, text and attributes.&lt;br /&gt;
&lt;br /&gt;
===Additional Fields===&lt;br /&gt;
&lt;br /&gt;
The sf_assemblage needs a number of different &amp;#039;op&amp;#039; variables set in the sf_conf:&lt;br /&gt;
*&amp;#039;&amp;#039;&amp;#039;op_assemblage_type&amp;#039;&amp;#039;&amp;#039; - the root field which is connected to the item&lt;br /&gt;
*&amp;#039;&amp;#039;&amp;#039;op_sum_field&amp;#039;&amp;#039;&amp;#039; - if this is set then the rows will be aggregated where they are identical and the number in this field will be summed for the output. this field must be a number!&lt;br /&gt;
*&amp;#039;&amp;#039;&amp;#039;fields&amp;#039;&amp;#039;&amp;#039; - the columns that will be added to the table&lt;br /&gt;
&lt;br /&gt;
===Example Configuration===&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$conf_mcd_assemblage =&lt;br /&gt;
    array(&lt;br /&gt;
        &amp;#039;view_state&amp;#039; =&amp;gt; &amp;#039;max&amp;#039;,&lt;br /&gt;
        &amp;#039;edit_state&amp;#039; =&amp;gt; &amp;#039;view&amp;#039;,&lt;br /&gt;
        &amp;#039;sf_title&amp;#039; =&amp;gt; &amp;#039;assemblage&amp;#039;, //appears in the titlebar of the subform (mk nname)&lt;br /&gt;
        &amp;#039;sf_html_id&amp;#039; =&amp;gt; &amp;#039;pottery_ass&amp;#039;, //the form id tag (must be unique)&lt;br /&gt;
        &amp;#039;sf_nav_type&amp;#039; =&amp;gt; &amp;#039;nmedit&amp;#039;,&lt;br /&gt;
        &amp;#039;script&amp;#039; =&amp;gt; &amp;#039;php/subforms/sf_chaintable.php&amp;#039;,&lt;br /&gt;
        &amp;#039;op_assemblage_type&amp;#039; =&amp;gt;  $conf_field_sherd_class,// the field of data attached to the item&lt;br /&gt;
        &amp;#039;op_sum_field&amp;#039; =&amp;gt; $conf_field_total,&lt;br /&gt;
        &amp;#039;default&amp;#039; =&amp;gt; &amp;#039;0&amp;#039;, //the default value for creating new records&lt;br /&gt;
        &amp;#039;op_label&amp;#039; =&amp;gt; &amp;#039;space&amp;#039;,&lt;br /&gt;
        &amp;#039;op_input&amp;#039; =&amp;gt; &amp;#039;save&amp;#039;,&lt;br /&gt;
        &amp;#039;fields&amp;#039; =&amp;gt; array(&lt;br /&gt;
            $conf_field_sherd_class,&lt;br /&gt;
            $conf_field_sherd_form,&lt;br /&gt;
            $conf_field_sherd_type,&lt;br /&gt;
            $conf_field_finddates,&lt;br /&gt;
            $conf_field_sherdfunction,&lt;br /&gt;
            $conf_field_catxmiloc,&lt;br /&gt;
            $conf_field_total,&lt;br /&gt;
        ),&lt;br /&gt;
);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[category: Administrator]]&lt;/div&gt;</summary>
		<author><name>Mike</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/Importing_Text_Data</id>
		<title>Importing Text Data</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/Importing_Text_Data"/>
				<updated>2015-09-14T08:44:07Z</updated>
		
		<summary type="html">&lt;p&gt;Mike: /* Step 1. Identify datafile */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==ARK textfile importer user guide==&lt;br /&gt;
Since v1.1.2 ARK has had a tool to import text based files in either JSON or CSV. &lt;br /&gt;
.The file can be filtered so that only certain records are uploaded. It can create new records or add to existing ones.&lt;br /&gt;
&lt;br /&gt;
===Step 1. Identify datafile===&lt;br /&gt;
[[File:jsonhowto_fig1.png|thumb|400px|right|Figure 1: File Picker]]&lt;br /&gt;
;Specify the location of the file.&lt;br /&gt;
:The import page of ARK in 1.1.2 includes a function for importing data directly from a text file or a data stream available online. Currently the file must be available on a web server. (Fig. 1) Enter the location of the file, either a relative path from the ARK root eg data/uploads/your_data.csv or a remote web address eg http://www.example.com/ARK/data?format=json.&lt;br /&gt;
Click Submit.&lt;br /&gt;
&lt;br /&gt;
Depend on the size of the file it may take some time to load into your browser. Once it is loaded it will be available to manipulate very quickly.A spinner will appear while this is happening.&lt;br /&gt;
&lt;br /&gt;
===Step 2. Determine &amp;#039;Root&amp;#039; of the data structure.===&lt;br /&gt;
&lt;br /&gt;
The data you have will likely include information that relates to several ARK items. Within your data structure there will be a level that includes all of these item representations - in the same way as rows in a table. In a csv file where there is a single record per row the root will be &amp;#039;root&amp;gt;items&amp;#039;. In a more complicated json file (for example one with file level metadata held in the root as well as the items) the records may be contained in an object within the root object. Json allows for extensible representation, so each &amp;#039;row&amp;#039; in the json file may not include all the same fields. It may be necessary to use the filter tools to only import objects which have a certain criteria.&lt;br /&gt;
&lt;br /&gt;
The example shown here has many items in the items object in root. The first available column is used to identify each of the contained objects - in this case it is an ARK ID, but it could be anything and may not be unique if it is not unique in your structure. For example if field 1 in your table is a site code or context type.&lt;br /&gt;
&lt;br /&gt;
[[File:jsonhowto_fig2.png|thumb|400px|left|none|Figure 2: Objects in &amp;#039;root&amp;gt;items&amp;#039;]]&lt;br /&gt;
&lt;br /&gt;
In order to define this level you will need to navigate to it.The path at the top of the page describes where in the data structure you currently are.The large panel below the advanced options shows the identifiers held in the current level.At the root level of a CSV file the first column will be used as an identifier. Clicking on these will open the data attached to that identifier for viewing.(Fig. 2) It is possible to go up one level using the button at the end of the list of objects, or any part of the location at the top of the page can be used to navigate to that level.When the main window would contain more than 20 items it is truncated and only the first 20 are shown.&lt;br /&gt;
&lt;br /&gt;
Use the &amp;#039;this is root&amp;#039; button in the navigation panel at the top of the page when the root is displayed in the main panel.&lt;br /&gt;
&lt;br /&gt;
===Step 3. Determine ARK IDs===&lt;br /&gt;
&lt;br /&gt;
[[File:jsonhowto_fig3.png|thumb|right|600px|Figure 3: Root and ARK ID specified]]&lt;br /&gt;
&lt;br /&gt;
Using the navigation method above find the path to the ARK id within your data. This will often be as simple as &amp;#039;root&amp;gt;items&amp;gt;item1&amp;gt;Ark_id&amp;#039;.The object that you define the ARK ID in is not important. As long as the objects are structured consistently the ARK IDs will be retrieved automatically based on the root defined in the step above. so for instance the importer will import the ARK ID for METSUR_152 from root &amp;gt; items &amp;gt; METSUR_152 &amp;gt; ARK_id and then the ARK ID for METSUR_153 from root &amp;gt; items &amp;gt; METSUR_153 &amp;gt; ARK_id, and so on.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If you do not have ARK IDs in your data refer to the [[#Advanced Options|advanced options]].&lt;br /&gt;
Otherwise, click &amp;#039;This is ARK ID&amp;#039; button below the identifier that contains the ARK ID.&lt;br /&gt;
&lt;br /&gt;
===Step 4. Test Import===&lt;br /&gt;
&lt;br /&gt;
[[File:jsonhowto_fig4.png|thumb|right|400px|Figure 4: Example of dry run]]&lt;br /&gt;
&lt;br /&gt;
Click &amp;#039;Import this&amp;#039; below the identifier that you would like to import. If you have completed the steps above a new panel will appear below the viewer. Confirm that this looks how you expect – &amp;#039;&amp;#039;&amp;#039;this is what will be imported into the database&amp;#039;&amp;#039;&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
The final panel allows you to define which records will be imported. A type must be specified. If you are importing a file it may be necessary to do a separate import of each type. This is because different types have different fields attached to them, the drop down menus respond to the ones above them, presenting only the options available. If they are not completed in order it may result in unexpected behaviour.&lt;br /&gt;
&lt;br /&gt;
===Step 5.===&lt;br /&gt;
When you are happy that you are importing the correct data into the correct field, click &amp;#039;Submit&amp;#039;.&lt;br /&gt;
You will be shown the results of your import. Click &amp;#039;Import Json&amp;#039; to repeat the process for any other fields you wish to import.&lt;br /&gt;
&lt;br /&gt;
==Advanced Options==&lt;br /&gt;
;Ste_cd:&lt;br /&gt;
:The site code that imported items will have, is one is not specified in the data – uses the ARK default if not set. No site code: This check box will remove site codes from the import itemvalue, for use with chains.&lt;br /&gt;
;Regular Expression:&lt;br /&gt;
:This is used to extract the itemvalue from the ARK ID column – by default it grabs the first run of numbers in the field.&lt;br /&gt;
;Start at Arbitrary Number:&lt;br /&gt;
:If you wish to create a sequence of numbers starting from a given point, (including 1) you will need to specify this here, and the number to start on. A unique &amp;#039;ARK ID&amp;#039; must still be specified in the data, but it will not be used.&lt;/div&gt;</summary>
		<author><name>Mike</name></author>	</entry>

	<entry>
		<id>https://ark.lparchaeology.com/wiki/index.php/Failed_to_find_markup</id>
		<title>Failed to find markup</title>
		<link rel="alternate" type="text/html" href="https://ark.lparchaeology.com/wiki/index.php/Failed_to_find_markup"/>
				<updated>2015-08-28T11:33:29Z</updated>
		
		<summary type="html">&lt;p&gt;Mike: Created page with &amp;quot;This is a common error message in ARK, don&amp;#039;t panic, it simply means that the text fragment for this part of the ARK is not available in either the default or your chosen language...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This is a common error message in ARK, don&amp;#039;t panic, it simply means that the text fragment for this part of the ARK is not available in either the default or your chosen language.&lt;br /&gt;
&lt;br /&gt;
Often you can make an educated guess at what it might be from the internal nickname the text has, which is also displayed in the error message.&lt;br /&gt;
&lt;br /&gt;
If you have admin privileges you can add the missing markup in the &amp;#039;Markup tab&amp;#039; see [[Markup Administration]] for help with that.&lt;/div&gt;</summary>
		<author><name>Mike</name></author>	</entry>

	</feed>