forked from iDigBio/TcnImageTools
-
Notifications
You must be signed in to change notification settings - Fork 0
/
TcnImageConfig.php.dist
57 lines (50 loc) · 2.19 KB
/
TcnImageConfig.php.dist
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
//Variables needing security
//Base folder containing herbarium folder ; read access needed
$sourcePathBase = '';
//Folder where images are to be placed; write access needed
$targetPathBase = '';
//Url base needed to build image URL that will be save in DB
$imgUrlBase = '';
//Path to where log files will be placed
$logPath = $sourcePathBase;
//Full path to Symbiota project root folder
$serverRoot = '/var/www/html/symbiota';
// Path to Symbiota Class Files, set to null if class files are
// not available. Correct path is required for the processing of
// xml batch files.
$symbiotaClassPath = $serverRoot."/classes/";
//If silent is set, script will produce not produce a log file
$silent = 0;
//If record matching PK is not found, should a new blank record be created?
$createNewRec = 1;
//Weather to copyover images with matching names (includes path) or rename new image and keep both
$copyOverImg = 1;
$webPixWidth = 800;
$tnPixWidth = 130;
$lgPixWidth = 2000;
//Whether to use ImageMagick for creating thumbnails and web images. ImageMagick must be installed on server.
// 0 = use GD library (default), 1 = use ImageMagick
$useImageMagick = 0;
//Value between 0 and 100
$jpgCompression = 80;
//Create thumbnail versions of image
$createTnImg = 1;
//Create large version of image, given source image is large enough
$createLgImg = 1;
$keepOrig = 1;
//0 = write image metadata to file; 1 = write metadata to Symbiota database
$dbMetadata = 1;
/**
* Array of parameters for collections to process.
* 'collection:project' => array(
* 'pmterm' => '/A(\d{8})\D+/', // regular expression to match collectionCode and catalogNumber in filename, first backreference is used as the catalogNumber.
* 'collid' => 0, // symbiota collid corresponding with the pterm pattern.
* 'prpatt' => '/^/', // optional regular expression for match on catalogNumber to be replaced with prrepl.
* 'prrepl' => 'barcode-' // optional replacement to apply for prpatt matches on catalogNumber.
* // given above description, 'A01234567.jpg' will yield catalogNumber = 'barcode-01234567'
* )
*
*/
$collArr = array(
'bry:lichens' => array('pmterm' => '/^(BRY-L-\d{7})\D*/', 'collid' => 13)
);