Difference between revisions of "Settings.php"

From ARK
Jump to: navigation, search
(OLD OLD OLD OLD OLD)
 
(84 intermediate revisions by 6 users not shown)
Line 1: Line 1:
This is the main settings file for each instance of ARK. The file is divide into sections as set out below
+
This is the main settings file for administrators to set defaults for security settings and permissions, loaded modules, etc. for each instance of ARK. As of v1.0, for settings related to page display and navigation see [[page_settings.php]], and those related to server settings see [[env_settings.php]].
  
===General===
+
==Server Setup==
This contains general configuration for the ARK.
+
The server setup being used (can include"ms4w", "mac", or "linux"):
 +
<pre>
 +
$server="ms4w";
 +
</pre>
  
====Minimiser====
+
And include the settings related to your server environment contained within the [[env_settings.php]]:
Is the minimiser enabled?
 
 
<pre>
 
<pre>
// Set to TRUE if you want to use the minimising right hand navigation bar
+
// Include settings related to your server environment
$minimiser = TRUE;
+
include('env_settings.php');
 
</pre>
 
</pre>
  
====ARK Name====
+
==ARK Name and Markup==
The name of this instance of ARK
+
The name of this instance of ARK -  can not contain spaces!
 
<pre>
 
<pre>
 
// The Ark name
 
// The Ark name
 
$ark_name = 'Tutorial';
 
$ark_name = 'Tutorial';
 +
</pre>
 +
The name of this instance of ARK -  as markup. Appears on the index (home) page and in the browser window/tab title. Should be entered in cor_tbl_markup accordingly.
 +
<pre>
 +
// The nickname for the markup ARK name that appears on the index page and
 +
// as browser window/tab title
 +
$arkname_mk = 'arkname';
 
</pre>
 
</pre>
  
===Live Search===
+
==Live Search==
 
The controls for the live search function
 
The controls for the live search function
 
<pre>
 
<pre>
Line 30: Line 38:
 
</pre>
 
</pre>
  
Also the controls for live search for XMI
+
'''NB- Controls for xmi live search should not be included in the global settings, this has been moved to the subform configuration as of v0.7'''
 +
 
 +
<strike>Also the controls for live search for XMI </strike>
 
<pre>
 
<pre>
 
// Live search controls for xmi
 
// Live search controls for xmi
Line 41: Line 51:
 
</pre>
 
</pre>
  
===Modules===
+
==Fancy Text Search==
 +
The controls for fancy text search, using boolean functions such as +, -, "search term", etc (like Google).
 +
<pre>
 +
// Free text search mode
 +
/*
 +
* fancy - this allows complex search options such as +, -, "" (like Google!)
 +
* plain = plain free text search, no fancy options
 +
*/
 +
$ftx_mode = "fancy";
 +
</pre>
 +
 
 +
==Modules==
 
Configure the modules to be used in this ARK project:
 
Configure the modules to be used in this ARK project:
 
<pre>
 
<pre>
Line 79: Line 100:
 
</pre>
 
</pre>
  
 +
==Security and Permissions==
 +
The security and permissions for ARK is handled by LiveUser. 
 
===Security===
 
===Security===
The security for ARK is handled by LiveUser. The liveuser configuration is as follows:
+
The liveuser settings need to be set, as well as the variables for allowing anonymous logins. The liveuser configuration is as follows:
 
<pre>
 
<pre>
 +
// -- SECURITY -- //
 
// Liveuser:  
 
// Liveuser:  
 
// These are the names of the liveuser objects. They should be unique per ARK  
 
// These are the names of the liveuser objects. They should be unique per ARK  
Line 90: Line 114:
 
// The path to the login script (relative to the document root)
 
// The path to the login script (relative to the document root)
 
$loginScript = 'index.php';
 
$loginScript = 'index.php';
 +
 
// Anonymous Logins
 
// Anonymous Logins
 
// If these variables are set then you are allowing anonymous logins
 
// If these variables are set then you are allowing anonymous logins
 
// This is a security risk! Its best to leave these statements commented out.
 
// This is a security risk! Its best to leave these statements commented out.
// Bear in mind that this does not need to be a real user.
+
// Bear in mind that for this to work - you will also need to make a new user (using the ARK user_admin tools).
 
$anonymous_login['username'] = 'anon';
 
$anonymous_login['username'] = 'anon';
 
$anonymous_login['password'] = 'anon';
 
$anonymous_login['password'] = 'anon';
 +
</pre>
 +
 +
===Permissions===
 +
A variety of permissions need to be set to ensure the appropriate users are making use of advanced functions. All permissions are based on the numerical id of security groups (from the cor_lvu_groups table). For instance, it is possible to  allow some users to make their personal saved filters public for all to use. As of v0.8, adding to control lists (adding attributes), and perhaps most importantly, advanced record functions such as edit module types and delete entire records need to also have sgrps defined.
 +
<pre>
 +
// Filter permissions
 +
// Members of the following (sgrp) groups will have permission to make their own filters public
 +
// and permission to make other users (and their own) filters got private
 +
$ftr_admin_grps =
 +
    array(
 +
        1
 +
);
 +
 +
// Control list permissions
 +
// Members of the following (sgrp) groups will have permission to add items to controlled lists
 +
$ctrllist_admin_grps =
 +
    array(
 +
        1
 +
);
 +
// Record admin permissions
 +
// Members of the following (sgrp) groups will have access to the advanced record functions
 +
$record_admin_grps =
 +
    array(
 +
        2
 +
);
 +
</pre>
 +
 +
==Forms==
 +
===Form Methods===
 +
Choose between 'get' or 'post' form methods.
 +
<pre>
 +
// -- FORMS -- //
 
// Method used in forms:
 
// Method used in forms:
// get = form messages sent via get method - vissible in browser bar.
+
// get = form messages sent via get method - visible in browser bar.
 
// post = form message sent via post method - invisible to the user.
 
// post = form message sent via post method - invisible to the user.
 
$form_method = 'get';
 
$form_method = 'get';
 +
</pre>
 +
===Form Defaults===
 +
Set default year and site code for data entry and viewing:
 +
<pre>
 +
//Default year as a setting for form data entry
 +
$default_year = '2008';
 +
//Default site code
 +
$default_site_cd = 'PCO06';
 
</pre>
 
</pre>
  
===Skin===
+
==Skin==
 
Sets the skin name and skin path for this ARK project:
 
Sets the skin name and skin path for this ARK project:
 
<pre>
 
<pre>
Line 111: Line 176:
 
</pre>
 
</pre>
  
===Thumbnails===
+
==Thumbnails==
 
Sets thumbnail sizes for ARK (this will be used when uploading files)
 
Sets thumbnail sizes for ARK (this will be used when uploading files)
 
<pre>
 
<pre>
Line 124: Line 189:
 
</pre>
 
</pre>
  
===Forms===
 
Set default year and site code for data entry and viewing:
 
<pre>
 
//Default year as a setting for form data entry
 
$default_year = '2008';
 
//Default site code
 
$default_site_cd = 'PCO06';
 
</pre>
 
 
===Viewers===
 
Configure the viewers to display a set number of rows:
 
<pre>
 
// Number of rows to display on the data viewer
 
$conf_viewer_rows = 25;
 
</pre>
 
  
Also configure the index pages for Micro View, Data View, and Search pages:
+
==Logging==
<pre>
+
Configures logging levels to record logging into database and changes to data. Set to 'on' to turn the logging on, otherwise set to FALSE.
// Default Micro viewer page (used by search result handlers)
 
$conf_micro_viewer = $ark_dir."micro_view.php";
 
// Default data viewer page
 
$conf_data_viewer = $ark_dir."data_view.php";
 
// Default search page - search funtions will send data thru to this page
 
$conf_search_viewer = $ark_dir."data_view.php";
 
</pre>
 
 
 
Set the default for search results display:
 
<pre>
 
// Default $output_mode for the data viewer
 
$default_output_mode = 'tbl';
 
</pre>
 
 
 
===Mapping===
 
Set the basic configuration for mapping functions (map directory, temp directory, etc):
 
<pre>
 
// Path to temp directory (server)
 
$ark_maptemp_dir = 'C:/ms4w/Apache/htdocs/'.$ark_dir.'mapserver/tmp/';
 
// Path to temp directory (web)
 
$ark_web_maptemp_dir = 'mapserver/tmp/';
 
// Path to WMS mapfile (server)
 
$ark_wms_map = 'C:/ms4w/Apache/htdocs/'.$ark_dir.'mapserver/mapfiles/ark_wms.map';
 
// Path to WFS mapfile (server)
 
$ark_wfs_map = 'C:/ms4w/Apache/htdocs/'.$ark_dir.'mapserver/mapfiles/ark_wfs.map';
 
// Map scales
 
$map_scales = '[1000,750,500,250,150,100,50,25,10]';
 
// Tilecache_path - only set this if you have a tilecache setup on your server
 
//$tilecache_path = '/cgi-bin/tilecache.cgi?';
 
</pre>
 
 
 
Configure the wms query layers:
 
<pre>
 
/*$wms_qlayers = array (
 
array(
 
'name' => 'cxt_schm',
 
'geom' => 'pgn'
 
),
 
array(
 
'name' => 'sfi_points',
 
'geom' => 'pt'
 
),
 
);*/
 
</pre>
 
 
 
Set up the map projection and extents to suit the location of the ARK project:
 
<pre>
 
// Map projection (in form: "EPSG:4326")
 
$map_projection = 'EPSG:27700';
 
// Map extents (in form: "1075,970,1115,1010")
 
$map_extents = '533866, 180940,533963, 181000';
 
</pre>
 
 
 
Set the layer from WMS to be used in map view
 
<pre>
 
// Maplayers from the WMS layer used in the map view
 
$mapview_layers = array ('contexts');
 
</pre>
 
 
 
===Logging===
 
Cofigures logging levels to record logging into database and changes to data.
 
 
<pre>
 
<pre>
 
//Logging levels
 
//Logging levels
Line 210: Line 199:
 
</pre>
 
</pre>
  
===Search Engine===
+
==Search Engine==
 
Configures words to cut out of multi-string searches to streamline the search process and maximise results.
 
Configures words to cut out of multi-string searches to streamline the search process and maximise results.
 
<pre>
 
<pre>
Line 217: Line 206:
 
</pre>
 
</pre>
  
===Languages===
+
==Languages==
 
Configures the default language and other languages in use.
 
Configures the default language and other languages in use.
 
<pre>
 
<pre>
Line 226: Line 215:
 
</pre>
 
</pre>
  
===Fields===
+
==Fields==
 
Used to include the [[field_settings.php]] file.
 
Used to include the [[field_settings.php]] file.
 
<pre>
 
<pre>
Line 232: Line 221:
 
</pre>
 
</pre>
  
===Document Type===
+
==Document Type==
 
Configures the document type to use for web output
 
Configures the document type to use for web output
 
<pre>
 
<pre>
Line 240: Line 229:
 
</pre>
 
</pre>
  
===Navigation===
+
[[Category: Administrator]]
====Navigation Links====
 
Configure to state what links will appear in the end of the navigation bar.
 
<pre>
 
$conf_linklist =
 
    array(
 
        'file' => 'index.php',
 
        'vars' => 'logout=true',
 
        'label' => 'logout'
 
);
 
</pre>
 
 
 
====Navigation Pages====
 
Unless listed in this array, all pages will appear in the main nav.
 
<pre>
 
$conf_hide_pages =
 
    array(
 
        'index.php',
 
        'record_view.php',
 
        'contact.php',
 
        'about.php',
 
        'search.php',
 
        'folder.php',
 
);
 
</pre>
 
 
 
===Left Panel Configuration===
 
 
 
====Left Panel- Data Entry====
 
Configures the left panel in the data entry pages, requires the following:
 
*'''view''' - the view the link should point to (regist, detfrm, files or a custom view)
 
*'''item_key''' - itemkey to point to if any (cxt_cd, smp_cd)
 
*'''href''' - link to the output
 
*'''mknname''' - mark-up nickname will search the markup table for this nickname and print the markup
 
 
 
<pre>
 
$data_entry_left_panel[] =
 
array(
 
        'href' => "{$_SERVER['PHP_SELF']}?view=regist&amp;item_key=cxt_cd",
 
        'mknname' => 'regcxt'
 
);
 
$data_entry_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?view=detfrm&amp;item_key=cxt_cd",
 
'mknname' => 'detcxt'
 
);
 
$data_entry_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?view=regist&amp;item_key=pln_cd",
 
'mknname' => 'regpln'
 
);
 
$data_entry_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?view=regist&amp;item_key=sph_cd",
 
'mknname' => 'regsph'
 
);
 
$data_entry_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?view=regist&amp;item_key=abk_cd",
 
'mknname' => 'regabk'
 
);
 
$data_entry_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?view=regist&amp;item_key=smp_cd",
 
'mknname' => 'regsmp'
 
);
 
$data_entry_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?view=detfrm&amp;item_key=smp_cd",
 
'mknname' => 'detsmp'
 
);
 
$data_entry_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?view=materi&amp;item_key=smp_cd",
 
'mknname' => 'matsmp'
 
);
 
$data_entry_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?view=regist&amp;item_key=spf_cd",
 
'mknname' => 'regspf'
 
);
 
$data_entry_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?view=files",
 
'mknname' => 'uplfile'
 
);
 
</pre>
 
 
 
====Left Panel- Micro View====
 
Configures the left panel in the micro view pages, requires the following:
 
*'''item_key''' - itemkey to point to if any (cxt_cd, smp_cd)
 
*'''href''' - link to the output
 
*'''mknname''' - mark-up nickname will search the markup table for this nickname and print the markup
 
 
 
<pre>
 
$micro_view_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?item_key=cxt_cd",
 
'mknname' => 'vwcxt'
 
);
 
$micro_view_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?item_key=pln_cd",
 
'mknname' => 'vwpln'
 
);
 
$micro_view_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?item_key=smp_cd",
 
'mknname' => 'vwsmp'
 
);
 
$micro_view_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?item_key=spf_cd",
 
'mknname' => 'vwspf'
 
);
 
$micro_view_left_panel[] =
 
array(
 
'href' => "{$_SERVER['PHP_SELF']}?item_key=sph_cd",
 
'mknname' => 'vwsph'
 
);
 
</pre>
 
 
 
====Left Panel- Data View====
 
This configures the left panel for the data view pages and needs the following:
 
*'''href''' - link to the output ({$_SERVER['PHP_SELF']} is on same page, $ark_dir/export.php is on export page)
 
*'''output_mode''' - output format for internal links
 
*'''output''' - is output format for external links
 
*'''mknname''' - mark-up nickname will search the markup table for this nickname and print the markup
 
 
 
<pre>
 
$data_view_left_panel[] =
 
    array(
 
        'href' => "$ark_dir/export.php?output=CSVExt",
 
        'mknname' => 'expcsv'
 
);
 
$data_view_left_panel[] =
 
    array(
 
        'href' => "$ark_dir/export.php?output=XMLExt",
 
        'mknname' => 'expxml'
 
);
 
$data_view_left_panel[] =
 
    array(
 
        'href' => "{$_SERVER['PHP_SELF']}?output_mode=tbl",
 
        'mknname' => 'vwtbl'
 
);
 
$data_view_left_panel[] =
 
    array(
 
        'href' => "{$_SERVER['PHP_SELF']}?output_mode=chat",
 
        'mknname' => 'vwchat'
 
);
 
</pre>
 
 
 
====Left Panel- User Home====
 
This configures the left-panel for the user home pages and needs the following fields:
 
*'''href''' - link to the output
 
*'''mknname''' - mark-up nickname will search the markup table for this nickname and print the markup
 
 
 
<pre>
 
$user_home_left_panel[] =
 
    array(
 
        'href' => "data_view.php?vtok=1&amp;nname=All_Contexts&amp;ftype=key&amp;key=1&amp;ktype=all",
 
        'mknname' => 'vwcxt'
 
);
 
</pre>
 
 
 
 
 
 
 
 
 
==General==
 
 
 
This sets the display name of the ARK instance. Used in page titles etc.
 
<pre>
 
// The Ark name
 
$ark_name = 'FASTI admin';
 
</pre>
 
 
 
The folder name of THIS instance of Ark (relative to the document root of the host in which it is hosted)
 
<pre>
 
// The folder name of THIS instance of Ark (relative to the document root of the host in which it is hosted)
 
$ark_dir = '/v2/';
 
<pre>
 
 
 
A list of loaded modules
 
<pre>
 
//array of loaded modules
 
$loaded_modules =
 
    array(
 
        'fst',
 
        'sea',
 
        'bib',
 
        'rpt',
 
        'abk',
 
);
 
</pre>
 
 
 
A default itemkey. Not essential but handy in guessing the itemkey sometimes.
 
<pre>
 
//  The default item key for this instance of Ark.
 
$default_itemkey = 'fst_cd';
 
</pre>
 
 
 
==Database==
 
 
 
<pre>
 
// DATABASE
 
// The mysql db name of this instance of ark
 
$ark_db = 'fasti_db2';
 
// The mysqlserver
 
$sql_server = 'localhost';
 
// The mysql user who will make all the db calls
 
$sql_user = 'sql_php_user';
 
// The mysql user's password
 
$sql_pwd = 'test';
 
// DSN (this shouldn;t need adjusting)
 
$dsn = 'mysql://'.$sql_user.':'.$sql_pwd.'@'.$sql_server.'/'.$ark_db;
 
</pre>
 
 
 
==Security==
 
 
 
<pre>
 
/*SECURITY
 
*these are the names of the liveuser objects. They should be unique per ARK
 
*(to prevent cross ark hacking). They need to be called in the code as
 
* $$liveuser and $$liveuser_admin
 
*/
 
$liveuser = $ark_name . 'usr';
 
$liveuser_admin = $ark_name . 'usr' . '_admin';
 
//the path to the login script (relative to the document root)
 
$loginScript = 'index.php';
 
//Anonymous Logins
 
//If these variables are set then you are allowing anonymous logins
 
//This is a security risk! Its best to leave these statements commented out.
 
//Bear in mind that this does not need to be a real user.
 
//$anonymous_login['username'] = 'anon';
 
//$anonymous_login['password'] = 'anon';
 
</pre>
 
 
 
==Skin==
 
 
 
<pre>
 
// SKIN
 
// Skin name
 
$skin = 'fasti';
 
// Skin path
 
$skin_path = "$ark_dir"."skins/$skin";
 
</pre>
 
 
 
==Forms==
 
 
 
<pre>
 
// FORMS
 
//Default year as a setting for form data entry
 
$default_year = '2005';
 
//Default site code
 
$default_site_cd = 'AIAC';
 
</pre>
 
 
 
==Viewers==
 
 
 
<pre>
 
// VIEWERS
 
// FIXME: make this an option of the table setup array
 
// Number of rows to display on the data viewer
 
$conf_viewer_rows = 15;
 
// Default Micro viewer page (used by search result handlers)
 
$conf_micro_viewer = $ark_dir."micro_view.php";
 
// Default data viewer page
 
$conf_data_viewer = $ark_dir."data_view.php";
 
// Default search page - search funtions will send data thru to this page
 
$conf_search_viewer = $ark_dir."data_view.php";
 
//Default $output_mode for the data viewer
 
$default_output_mode = 'tbl';
 
</pre>
 
 
 
==Mapping==
 
 
 
<pre>
 
// MAPPING
 
// Path to clarent (web)
 
$clarent_path = "clarent/0_6/clarent";
 
// Path to data directory (server)
 
$ark_mapdata_dir = '/srv/www/htdocs/fasti/'.$ark_dir.'mapserver/data/';
 
// Path to temp directory (server)
 
$ark_maptemp_dir = '/srv/www/htdocs/fasti/'.$ark_dir.'mapserver/tmp/';
 
// Path to temp directory (web)
 
$ark_web_maptemp_dir = 'mapserver/tmp/';
 
// Default maptype (STU WHATS THIS)
 
$default_maptype = 1;
 
// Path to base_map (server)
 
$default_base_map = '/srv/www/htdocs/fasti/'.$ark_dir.'mapserver/mapfiles/base.map';
 
//$default_base_map = '/srv/www/htdocs/fasti/mapserver/base.map';
 
// Path to WMS mapfile (server)
 
$wms_map = '/srv/www/htdocs/fasti/'.$ark_dir.'mapserver/mapfiles/fasti_wms.map';
 
// Path to WFS mapfile (server)
 
$wfs_map = '/srv/www/htdocs/fasti/'.$ark_dir.'mapserver/mapfiles/fasti_wfs.map';
 
//spatial modules - these are the modules that have geometry
 
$spat_mods = array('cor');
 
</pre>
 
 
 
==Logging==
 
 
 
<pre>
 
// LOGGING
 
//Logging levels
 
$conf_log_add = 'on';
 
$conf_log_edt = 'on';
 
$conf_log_del = 'on';
 
</pre>
 
 
 
==Search Engine==
 
 
 
<pre>
 
// SEARCH ENGINE
 
// words to cut out of multi string searches
 
$conf_non_search_words = array('and', 'di', 'in');
 
</pre>
 
 
 
==Languages==
 
 
 
<pre>
 
// LANGUAGES
 
// The default lang
 
$default_lang = 'en';
 
// These are the languages in use (in order)
 
$conf_langs = array('en', 'it', 'ro', 'mk');
 
</pre>
 
 
 
==Fields==
 
 
 
<pre>
 
// FIELDS
 
include_once('field_settings.php');
 
</pre>
 
 
 
==Doctype==
 
 
 
<pre>
 
// DOCTYPE
 
// The doctype to use for web output
 
$doctype = "html \n
 
    PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\"\n
 
    \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\"";
 
</pre>
 
 
 
==Navigation Links==
 
 
 
<pre>
 
// NAV LINKS
 
// these links will appear in the end of the navbar
 
$conf_linklist =
 
    array(
 
        'file' => 'index.php',
 
        'vars' => 'logout=true',
 
        'label' => 'logout'
 
);
 
</pre>
 
 
 
==Navigation Pages==
 
 
 
<pre>
 
// NAV PAGES
 
// unless listed in this array, all pages will appear int he main nav
 
$conf_hide_pages =
 
    array(
 
        'index.php',
 
        'record_view.php',
 
        'contact.php',
 
        'about.php',
 
        'search.php',
 
        'folder.php',
 
        'export.php'
 
);
 
</pre>
 
 
 
 
 
[[category: Administrator]]
 

Latest revision as of 15:49, 21 March 2012

This is the main settings file for administrators to set defaults for security settings and permissions, loaded modules, etc. for each instance of ARK. As of v1.0, for settings related to page display and navigation see page_settings.php, and those related to server settings see env_settings.php.

Server Setup

The server setup being used (can include"ms4w", "mac", or "linux"):

$server="ms4w";

And include the settings related to your server environment contained within the env_settings.php:

// Include settings related to your server environment
include('env_settings.php');

ARK Name and Markup

The name of this instance of ARK - can not contain spaces!

// The Ark name
$ark_name = 'Tutorial';

The name of this instance of ARK - as markup. Appears on the index (home) page and in the browser window/tab title. Should be entered in cor_tbl_markup accordingly.

// The nickname for the markup ARK name that appears on the index page and
// as browser window/tab title
$arkname_mk = 'arkname';

Live Search

The controls for the live search function

// Live search controls 
/*
* live = live search 
* dd = drop down menu
* plain = plain text search
*/
$mode = "live";

NB- Controls for xmi live search should not be included in the global settings, this has been moved to the subform configuration as of v0.7

Also the controls for live search for XMI

// Live search controls for xmi
/*
* live = live search - this should only be set to live if you are using the collapsing data entry
* dd = drop down menu
* plain = plain text search
*/
$xmi_mode = "live";

Fancy Text Search

The controls for fancy text search, using boolean functions such as +, -, "search term", etc (like Google).

// Free text search mode
/*
* fancy - this allows complex search options such as +, -, "" (like Google!)
* plain = plain free text search, no fancy options
*/
$ftx_mode = "fancy";

Modules

Configure the modules to be used in this ARK project:

// List the modules that need to be loaded in this ARK project
$loaded_modules = 
    array(
	'abk', // address book
        'cxt', // contexts
        'pln', // plans
	'smp', // samples
        'spf', // Special finds
        'sph', // Site photos
        
);

Also configure the modules to load mapping data:

// Lists the modules to load maps for
$loaded_map_mods = 
    array(
        'cxt', // context
	'smp', // samples
);

Set the default item key for this ARK setup:

// The default item key for this instance of Ark - format: mod_cd
$default_itemkey = 'cxt_cd'; // context

Set the DSN for this ARK (this should generally NOT need adjusting)

// DSN (this shouldn't need adjusting)
$dsn = 'mysql://'.$sql_user.':'.$sql_pwd.'@'.$sql_server.'/'.$ark_db;

Security and Permissions

The security and permissions for ARK is handled by LiveUser.

Security

The liveuser settings need to be set, as well as the variables for allowing anonymous logins. The liveuser configuration is as follows:

// -- SECURITY -- //
// Liveuser: 
// These are the names of the liveuser objects. They should be unique per ARK 
// (to prevent cross ark hacking). They need to be called in the code as
// $$liveuser and $$liveuser_admin
$liveuser = $ark_name . 'usr';
$liveuser_admin = $ark_name . 'usr' . '_admin';
// The path to the login script (relative to the document root)
$loginScript = 'index.php';

// Anonymous Logins
// If these variables are set then you are allowing anonymous logins
// This is a security risk! Its best to leave these statements commented out.
// Bear in mind that for this to work - you will also need to make a new user (using the ARK user_admin tools).
$anonymous_login['username'] = 'anon';
$anonymous_login['password'] = 'anon';

Permissions

A variety of permissions need to be set to ensure the appropriate users are making use of advanced functions. All permissions are based on the numerical id of security groups (from the cor_lvu_groups table). For instance, it is possible to allow some users to make their personal saved filters public for all to use. As of v0.8, adding to control lists (adding attributes), and perhaps most importantly, advanced record functions such as edit module types and delete entire records need to also have sgrps defined.

// Filter permissions
// Members of the following (sgrp) groups will have permission to make their own filters public
// and permission to make other users (and their own) filters got private
$ftr_admin_grps =
    array(
        1
);

// Control list permissions
// Members of the following (sgrp) groups will have permission to add items to controlled lists
$ctrllist_admin_grps =
    array(
        1
);
// Record admin permissions
// Members of the following (sgrp) groups will have access to the advanced record functions
$record_admin_grps =
    array(
        2
);

Forms

Form Methods

Choose between 'get' or 'post' form methods.

// -- FORMS -- //
// Method used in forms:
// get = form messages sent via get method - visible in browser bar.
// post = form message sent via post method - invisible to the user.
$form_method = 'get';

Form Defaults

Set default year and site code for data entry and viewing:

//Default year as a setting for form data entry
$default_year = '2008';
//Default site code
$default_site_cd = 'PCO06';

Skin

Sets the skin name and skin path for this ARK project:

// Skin name
$skin = 'arkologik';
// Skin path
$skin_path = "$ark_dir/skins/$skin";

Thumbnails

Sets thumbnail sizes for ARK (this will be used when uploading files)

// Optional
$thumbnail_sizes =
    array(
        'arkthumb_width' => 100,
        'arkthumb_height' => 100,
        'webthumb_width' => 500,
        'webthumb_height' => 500
);


Logging

Configures logging levels to record logging into database and changes to data. Set to 'on' to turn the logging on, otherwise set to FALSE.

//Logging levels
$conf_log_add = 'on';
$conf_log_edt = 'on';
$conf_log_del = 'on';

Search Engine

Configures words to cut out of multi-string searches to streamline the search process and maximise results.

// words to cut out of multi string searches
$conf_non_search_words = array('and', 'di', 'in');

Languages

Configures the default language and other languages in use.

// The default lang
$default_lang = 'en';
// These are the languages in use (in order)
$conf_langs = array('en', 'da');

Fields

Used to include the field_settings.php file.

include_once('field_settings.php');

Document Type

Configures the document type to use for web output

$doctype = "html \n
     PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\"\n
     \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\"";