first commit
3
.well-known/security.txt
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
Contact: https://www.resourcespace.com/bug_report
|
||||||
|
Expires: 2025-06-30T22:59:00.000Z
|
||||||
|
Policy: https://www.resourcespace.com/bug_report
|
43
api/example.php
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
/*
|
||||||
|
*
|
||||||
|
* Example of API integration
|
||||||
|
* --------------------------
|
||||||
|
*
|
||||||
|
* Pure PHP example... does not require any local RS elements (connects to RS via HTTP).
|
||||||
|
* This code would be on a client (non ResourceSpace) system.
|
||||||
|
*
|
||||||
|
* For documentation please see: http://www.resourcespace.com/knowledge-base/api/
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
$private_key = "e6ee5970359e1cfc24091aa7b0237feb25db1efb69a8b83d7959fb2f6b340ee0"; # <--- From RS user edit page for the user to log in as
|
||||||
|
$user = "admin"; # <-- RS username of the user you want to log in as
|
||||||
|
|
||||||
|
# Some example function calls.
|
||||||
|
#
|
||||||
|
#$query="user=" . $user . "&function=do_search¶m1="; # <--- The function to execute, and parameters
|
||||||
|
$query = "user=" . $user . "&function=get_resource_field_data¶m1=1"; # <--- The function to execute, and parameters
|
||||||
|
#$query="user=" . $user . "&function=create_resource¶m1=1"; # <--- The function to execute, and parameters
|
||||||
|
#$query="user=" . $user . "&function=update_field¶m1=1¶m2=8¶m3=Example"; # <--- The function to execute, and parameters
|
||||||
|
#$query="user=" . $user . "&function=delete_resource¶m1=1"; # <--- The function to execute, and parameters
|
||||||
|
#$query="user=" . $user . "&function=copy_resource¶m1=2"; # <--- The function to execute, and parameters
|
||||||
|
#$query="user=" . $user . "&function=get_resource_data¶m1=2"; # <--- The function to execute, and parameters
|
||||||
|
#$query="user=" . $user . "&function=get_alternative_files¶m1=2"; # <--- The function to execute, and parameters
|
||||||
|
#$query="user=" . $user . "&function=get_resource_types"; # <--- The function to execute, and parameters
|
||||||
|
#$query="user=" . $user . "&function=add_alternative_file¶m1=2¶m2=Test"; # <--- The function to execute, and parameters
|
||||||
|
#$query="user=" . $user . "&function=get_resource_log¶m1=2"; # <--- The function to execute, and parameters
|
||||||
|
#$query="user=" . $user . "&function=upload_file_by_url¶m1=2¶m2=¶m3=¶m4=¶m5=" . urlencode("http://www.montala.com/img/slideshow/montala-bg.jpg"); # <--- The function to execute, and parameters
|
||||||
|
# Create resource, add a file and add metadata in one pass.
|
||||||
|
$query = "user=" . $user . "&function=create_resource¶m1=1¶m2=¶m3=" . urlencode("http://www.montala.com/img/slideshow/montala-bg.jpg") . "¶m4=¶m5=¶m6=¶m7=" . urlencode(json_encode(array(1 => "Foo",8 => "Bar"))); # <--- The function to execute, and parameters
|
||||||
|
|
||||||
|
# Sign the query using the private key
|
||||||
|
$sign = hash("sha256", $private_key . $query);
|
||||||
|
|
||||||
|
# Make the request.
|
||||||
|
$results = file_get_contents("http://localhost/resourcespace/api/?" . $query . "&sign=" . $sign);
|
||||||
|
|
||||||
|
# Output the JSON
|
||||||
|
echo "<pre>";
|
||||||
|
echo escape($results);
|
100
api/iiif/handler.php
Executable file
@@ -0,0 +1,100 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
$suppress_headers = true;
|
||||||
|
$disable_browser_check = true;
|
||||||
|
|
||||||
|
include_once __DIR__ . "/../../include/boot.php";
|
||||||
|
include_once __DIR__ . "/../../include/image_processing.php";
|
||||||
|
include_once __DIR__ . "/../../include/video_functions.php";
|
||||||
|
|
||||||
|
// Some viewer pre-flight checks seem to require this to be explicitly set
|
||||||
|
header("Access-Control-Allow-Origin: *");
|
||||||
|
|
||||||
|
if (!$iiif_enabled || !isset($iiif_identifier_field) || !is_numeric($iiif_identifier_field) || !isset($iiif_userid) || !is_numeric($iiif_userid) || !isset($iiif_description_field)) {
|
||||||
|
exit($lang["iiif_disabled"]);
|
||||||
|
}
|
||||||
|
|
||||||
|
include_once "../../include/api_functions.php";
|
||||||
|
|
||||||
|
if ($iiif_version === "2") {
|
||||||
|
// Older version of the standard. Needed if clients don't support v3.0 - see https://iiif.io/api/presentation/3.0/change-log/
|
||||||
|
include __DIR__ . "/handler2.php";
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Set up request object
|
||||||
|
$iiif_options["rootlevel"] = $baseurl_short . "iiif/";
|
||||||
|
$iiif_options["rooturl"] = $baseurl . "/iiif/";
|
||||||
|
$iiif_options["rootimageurl"] = $baseurl . "/iiif/image/";
|
||||||
|
$iiif_options["identifier_field"] = $iiif_identifier_field;
|
||||||
|
$iiif_options["description_field"] = $iiif_description_field;
|
||||||
|
$iiif_options["sequence_field"] = $iiif_sequence_field ?? 0;
|
||||||
|
$iiif_options["license_field"] = (int) ($iiif_license_field ?? 0);
|
||||||
|
$iiif_options["title_field"] = $view_title_field;
|
||||||
|
$iiif_options["max_width"] = $iiif_max_width ?? 1024;
|
||||||
|
$iiif_options["max_height"] = $iiif_max_height ?? 1024;
|
||||||
|
$iiif_options["custom_sizes"] = (bool) $iiif_custom_sizes ?? true;
|
||||||
|
$iiif_options["preview_tiles"] = (bool) $preview_tiles ?? true;
|
||||||
|
$iiif_options["preview_tile_size"] = $preview_tile_size ?? 1024;
|
||||||
|
$iiif_options["preview_tile_scale_factors"] = $preview_tile_scale_factors ?? [1,2,4];
|
||||||
|
$iiif_options["download_chunk_size"] = $download_chunk_size;
|
||||||
|
$iiif_options["rights"] = $iiif_rights_statement ?? "";
|
||||||
|
$iiif_options["media_extensions"] = $iiif_media_extensions;
|
||||||
|
$iiif_options["only_power_of_two_sizes"] = $iiif_only_power_of_two_sizes;
|
||||||
|
if (isset($iiif_sequence_prefix)) {
|
||||||
|
$iiif_options["iiif_sequence_prefix"] = $iiif_sequence_prefix;
|
||||||
|
}
|
||||||
|
|
||||||
|
$iiif = new IIIFRequest($iiif_options);
|
||||||
|
|
||||||
|
$iiif_user = get_user($iiif_userid);
|
||||||
|
if ($iiif_user === false) {
|
||||||
|
$iiif->errors[] = 'Invalid \$iiif_userid.';
|
||||||
|
$iiif->triggerError(500);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Creating $userdata for use in do_search()
|
||||||
|
$userdata[0] = $iiif_user;
|
||||||
|
setup_user($iiif_user);
|
||||||
|
|
||||||
|
// Extract request details
|
||||||
|
$iiif->parseUrl($_SERVER["REQUEST_URI"] ?? "");
|
||||||
|
|
||||||
|
if ($iiif->getRequest("api") == "root") {
|
||||||
|
# Root level request - send information file only
|
||||||
|
$iiif->infodoc();
|
||||||
|
} elseif ($iiif->getRequest("api") == "image") {
|
||||||
|
$iiif->processImageRequest();
|
||||||
|
} elseif ($iiif->getRequest("api") == "presentation") {
|
||||||
|
$iiif->processPresentationRequest();
|
||||||
|
} else {
|
||||||
|
$iiif->errorcode = 404;
|
||||||
|
$iiif->errors[] = "Bad request. Valid options are 'manifest', 'sequence' or 'canvas' e.g. ";
|
||||||
|
$iiif->errors[] = "For the manifest: " . $iiif->rooturl . $iiif->getRequest("id") . "/manifest";
|
||||||
|
$iiif->errors[] = "For a sequence : " . $iiif->rooturl . $iiif->getRequest("id") . "/sequence";
|
||||||
|
$iiif->errors[] = "For a canvas : " . $iiif->rooturl . $iiif->getRequest("id") . "/canvas/<identifier>";
|
||||||
|
}
|
||||||
|
|
||||||
|
// Send the response
|
||||||
|
if ($iiif->isValidRequest()) {
|
||||||
|
if (function_exists("http_response_code")) {
|
||||||
|
http_response_code(200); # Send OK
|
||||||
|
}
|
||||||
|
header("Access-Control-Allow-Origin: *");
|
||||||
|
header("Access-Control-Allow-Headers: Accept");
|
||||||
|
if ($iiif->is_image_response()) {
|
||||||
|
$iiif->renderImage();
|
||||||
|
} else {
|
||||||
|
header('Content-Type: application/ld+json;profile="http://iiif.io/api/image/3/context.json"');
|
||||||
|
foreach ($iiif->headers as $iiif_header) {
|
||||||
|
header($iiif_header);
|
||||||
|
}
|
||||||
|
if (defined('JSON_PRETTY_PRINT')) {
|
||||||
|
echo json_encode($iiif->getResponse(), JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
|
||||||
|
} else {
|
||||||
|
echo json_encode($iiif->getResponse());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} elseif (count($iiif->errors) > 0) {
|
||||||
|
$iiif->triggerError();
|
||||||
|
}
|
681
api/iiif/handler2.php
Normal file
@@ -0,0 +1,681 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
$suppress_headers = true;
|
||||||
|
|
||||||
|
if (!$iiif_enabled || !isset($iiif_identifier_field) || !is_numeric($iiif_identifier_field) || !isset($iiif_userid) || !is_numeric($iiif_userid) || !isset($iiif_description_field)) {
|
||||||
|
exit($lang["iiif_disabled"]);
|
||||||
|
}
|
||||||
|
|
||||||
|
$iiif_user = get_user($iiif_userid);
|
||||||
|
if ($iiif_user === false) {
|
||||||
|
iiif_error(500, ['Invalid $iiif_userid.']);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Creating $userdata for use in do_search()
|
||||||
|
$userdata[0] = $iiif_user;
|
||||||
|
|
||||||
|
setup_user($iiif_user);
|
||||||
|
$rootlevel = $baseurl_short . "iiif/";
|
||||||
|
$rooturl = $baseurl . "/iiif/";
|
||||||
|
$rootimageurl = $baseurl . "/iiif/image/";
|
||||||
|
$request_url = strtok($_SERVER["REQUEST_URI"], '?');
|
||||||
|
$path = substr($request_url, strpos($request_url, $rootlevel) + strlen($rootlevel));
|
||||||
|
$xpath = explode("/", $path);
|
||||||
|
$getext = "";
|
||||||
|
$response = array();
|
||||||
|
$validrequest = false;
|
||||||
|
$iiif_headers = array();
|
||||||
|
$errors = array();
|
||||||
|
if (count($xpath) == 1 && $xpath[0] == "") {
|
||||||
|
# Root level request - send information file only
|
||||||
|
$response["@context"] = "http://iiif.io/api/presentation/2/context.json";
|
||||||
|
$response["@id"] = $rooturl;
|
||||||
|
$response["@type"] = "sc:Manifest";
|
||||||
|
$response["@label"] = "";
|
||||||
|
$response["width"] = 6000;
|
||||||
|
$response["height"] = 4000;
|
||||||
|
|
||||||
|
$response["tiles"] = array();
|
||||||
|
$response["tiles"][] = array("width" => $preview_tile_size, "height" => $preview_tile_size, "scaleFactors" => $preview_tile_scale_factors);
|
||||||
|
$response["profile"] = array("http://iiif.io/api/image/2/level0.json");
|
||||||
|
|
||||||
|
$validrequest = true;
|
||||||
|
} else {
|
||||||
|
if (strtolower($xpath[0]) == "image") {
|
||||||
|
// IMAGE REQUEST (http://iiif.io/api/image/2.1/)
|
||||||
|
// The IIIF Image API URI for requesting an image must conform to the following URI Template:
|
||||||
|
// {scheme}://{server}{/prefix}/{identifier}/{region}/{size}/{rotation}/{quality}.{format}
|
||||||
|
$identifier = trim($xpath[1] ?? '');
|
||||||
|
if ($identifier === '') {
|
||||||
|
iiif_error(400, ['Missing identifier']);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!isset($xpath[2]) || $xpath[2] == "") {
|
||||||
|
// Redirect to image information document
|
||||||
|
$redirurl = $rootimageurl . $identifier . '/info.json';
|
||||||
|
if (function_exists("http_response_code")) {
|
||||||
|
http_response_code(303);
|
||||||
|
}
|
||||||
|
header("Location: " . $redirurl);
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
|
||||||
|
$resourceid = $xpath[1];
|
||||||
|
if (is_numeric($resourceid)) {
|
||||||
|
$resource = get_resource_data($resourceid);
|
||||||
|
$resource_access = get_resource_access($resourceid);
|
||||||
|
} else {
|
||||||
|
$resource_access = 2;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($resource_access == 0 && !in_array($resource["file_extension"], config_merge_non_image_types())) {
|
||||||
|
// Check resource actually exists and is active
|
||||||
|
$fulljpgsize = is_jpeg_extension($resource["file_extension"] ?? "") ? "" : "hpr";
|
||||||
|
$useextension = strtolower($resource["file_extension"]) == "jpeg" ? $resource["file_extension"] : "jpg";
|
||||||
|
$img_path = get_resource_path($resourceid, true, $fulljpgsize, false, $useextension);
|
||||||
|
$image_size = get_original_imagesize($resourceid, $img_path, $useextension);
|
||||||
|
if ($image_size === false) {
|
||||||
|
$errors[] = "No image available for this identifier";
|
||||||
|
iiif_error(404, $errors);
|
||||||
|
}
|
||||||
|
$imageWidth = (int) $image_size[1];
|
||||||
|
$imageHeight = (int) $image_size[2];
|
||||||
|
|
||||||
|
// Get all available sizes
|
||||||
|
$sizes = get_image_sizes($resourceid, true, "jpg", false);
|
||||||
|
$availsizes = array();
|
||||||
|
if ($imageWidth > 0 && $imageHeight > 0) {
|
||||||
|
foreach ($sizes as $size) {
|
||||||
|
if (
|
||||||
|
$size['width'] > 0
|
||||||
|
&& $size['height'] > 0
|
||||||
|
&& $size['width'] <= $iiif_max_width
|
||||||
|
&& $size['height'] <= $iiif_max_height
|
||||||
|
&& (
|
||||||
|
!$iiif_only_power_of_two_sizes
|
||||||
|
|| (is_power_of_two($size['width']) && is_power_of_two($size['height']))
|
||||||
|
|| $size['id'] == 'pre'
|
||||||
|
)
|
||||||
|
) {
|
||||||
|
$availsizes[] = [
|
||||||
|
'id' => $size['id'],
|
||||||
|
'width' => $size['width'],
|
||||||
|
'height' => $size['height'],
|
||||||
|
];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($xpath[2] == "info.json") {
|
||||||
|
// Image information request. Only fullsize available in this initial version
|
||||||
|
$response["@context"] = "http://iiif.io/api/image/2/context.json";
|
||||||
|
$response["@id"] = $rootimageurl . $resourceid;
|
||||||
|
|
||||||
|
$response["height"] = $imageHeight;
|
||||||
|
$response["width"] = $imageWidth;
|
||||||
|
|
||||||
|
$response["profile"] = array();
|
||||||
|
$response["profile"][] = "http://iiif.io/api/image/2/level0.json";
|
||||||
|
if ($iiif_custom_sizes) {
|
||||||
|
$response["profile"][] = array(
|
||||||
|
"formats" => array("jpg"),
|
||||||
|
"qualities" => array("default"),
|
||||||
|
"maxWidth" => $iiif_max_width,
|
||||||
|
"maxHeight" => $iiif_max_height,
|
||||||
|
"supports" => array("sizeByH","sizeByW")
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
$response["profile"][] = array(
|
||||||
|
"formats" => array("jpg"),
|
||||||
|
"qualities" => array("default"),
|
||||||
|
"maxWidth" => $iiif_max_width,
|
||||||
|
"maxHeight" => $iiif_max_height
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
$response["protocol"] = "http://iiif.io/api/image";
|
||||||
|
$response["sizes"] = $availsizes;
|
||||||
|
if ($preview_tiles) {
|
||||||
|
$response["tiles"] = array();
|
||||||
|
$response["tiles"][] = array("height" => $preview_tile_size, "width" => $preview_tile_size, "scaleFactors" => $preview_tile_scale_factors);
|
||||||
|
}
|
||||||
|
$iiif_headers[] = 'Link: <http://iiif.io/api/image/2/level0.json>;rel="profile"';
|
||||||
|
$validrequest = true;
|
||||||
|
} elseif (!isset($xpath[3]) || !isset($xpath[4]) || !isset($xpath[5]) || !isset($xpath[5]) || $xpath[5] != "default.jpg") {
|
||||||
|
// Not request for image information document and no sizes specified
|
||||||
|
$errors[] = "Invalid image request format.";
|
||||||
|
iiif_error(400, $errors);
|
||||||
|
} else {
|
||||||
|
// Check the request parameters
|
||||||
|
$region = $xpath[2];
|
||||||
|
$size = $xpath[3];
|
||||||
|
$rotation = $xpath[4];
|
||||||
|
$formatparts = explode(".", $xpath[5]);
|
||||||
|
if (count($formatparts) != 2) {
|
||||||
|
// Format. As we only support IIIF Image level 0 a value of 'jpg' is required
|
||||||
|
$errors[] = "Invalid quality or format requested. Try using 'default.jpg'";
|
||||||
|
iiif_error(400, $errors);
|
||||||
|
} else {
|
||||||
|
$quality = $formatparts[0];
|
||||||
|
$format = $formatparts[1];
|
||||||
|
}
|
||||||
|
|
||||||
|
// Process requested region
|
||||||
|
if (!isset($errorcode) && $region != "full" && $region != "max" && $preview_tiles) {
|
||||||
|
// If the request specifies a region which extends beyond the dimensions reported in the image information document,
|
||||||
|
// then the service should return an image cropped at the image’s edge, rather than adding empty space.
|
||||||
|
// If the requested region’s height or width is zero, or if the region is entirely outside the bounds
|
||||||
|
// of the reported dimensions, then the server should return a 400 status code.
|
||||||
|
|
||||||
|
$regioninfo = explode(",", $region);
|
||||||
|
$region_filtered = array_filter($regioninfo, 'is_numeric');
|
||||||
|
if (count($region_filtered) != 4) {
|
||||||
|
// Invalid region
|
||||||
|
$errors[] = "Invalid region requested. Use 'full' or 'x,y,w,h'";
|
||||||
|
iiif_error(400, $errors);
|
||||||
|
} else {
|
||||||
|
$regionx = (int)$region_filtered[0];
|
||||||
|
$regiony = (int)$region_filtered[1];
|
||||||
|
$regionw = (int)$region_filtered[2];
|
||||||
|
$regionh = (int)$region_filtered[3];
|
||||||
|
debug("IIIF region requested: x:" . $regionx . ", y:" . $regiony . ", w:" . $regionw . ", h:" . $regionh);
|
||||||
|
if (fmod($regionx, $preview_tile_size) != 0 || fmod($regiony, $preview_tile_size) != 0) {
|
||||||
|
// Invalid region
|
||||||
|
$errors[] = "Invalid region requested. Supported tiles are " . $preview_tile_size . "x" . $preview_tile_size . " at scale factors " . implode(",", $preview_tile_scale_factors) . ".";
|
||||||
|
iiif_error(400, $errors);
|
||||||
|
} else {
|
||||||
|
$tile_request = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
// Full image requested
|
||||||
|
$tile_request = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Process size
|
||||||
|
if (strpos($size, ",") !== false) {
|
||||||
|
// Currently support 'w,' and ',h' syntax requests
|
||||||
|
$getdims = explode(",", $size);
|
||||||
|
$getwidth = (int)$getdims[0];
|
||||||
|
$getheight = (int)$getdims[1];
|
||||||
|
if ($tile_request) {
|
||||||
|
if (($regionx + $regionw) >= $imageWidth || ($regiony + $regionh) >= $imageHeight) {
|
||||||
|
// Size specified is not the standard tile width, may be right or bottom edge of image
|
||||||
|
$validtileh = false;
|
||||||
|
$validtilew = false;
|
||||||
|
|
||||||
|
if ($getwidth > 0 && $getheight == 0) {
|
||||||
|
$scale = ceil($regionw / $getwidth);
|
||||||
|
} elseif ($getheight > 0 && $getwidth == 0) {
|
||||||
|
$scale = ceil($regionh / $getheight);
|
||||||
|
} else {
|
||||||
|
$errors[] = "Invalid tile size requested";
|
||||||
|
iiif_error(501, $errors);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!in_array($scale, $preview_tile_scale_factors)) {
|
||||||
|
$errors[] = "Invalid tile size requested";
|
||||||
|
iiif_error(501, $errors);
|
||||||
|
}
|
||||||
|
} elseif (
|
||||||
|
($getwidth == $preview_tile_size && $getheight == 0) ||
|
||||||
|
($getheight == $preview_tile_size && $getwidth == 0) ||
|
||||||
|
($getheight == $preview_tile_size && $getwidth == $preview_tile_size)
|
||||||
|
) {
|
||||||
|
$valid_tile = true;
|
||||||
|
if ($getheight === 0) {
|
||||||
|
$scale = ceil($regionw / $getwidth);
|
||||||
|
} else {
|
||||||
|
$scale = ceil($regionh / $getheight);
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
$errors[] = "Invalid tile size requested";
|
||||||
|
iiif_error(400, $errors);
|
||||||
|
}
|
||||||
|
|
||||||
|
$getsize = "tile_" . $scale . "_" . $regionx . "_" . $regiony . "_" . $regionw . "_" . $regionh;
|
||||||
|
$getext = "jpg";
|
||||||
|
|
||||||
|
debug("IIIF" . $regionx . "_" . $regiony . "_" . $regionw . "_" . $regionh);
|
||||||
|
} else {
|
||||||
|
if ($getheight == 0) {
|
||||||
|
$getheight = floor($getwidth * ($imageHeight / $imageWidth));
|
||||||
|
} elseif ($getwidth == 0) {
|
||||||
|
$getwidth = floor($getheight * ($imageWidth / $imageHeight));
|
||||||
|
}
|
||||||
|
// Establish which preview size this request relates to
|
||||||
|
foreach ($availsizes as $availsize) {
|
||||||
|
debug("IIIF - checking available size for resource " . $resource["ref"] . ". Size '" . $availsize["id"] . "': " . $availsize["width"] . "x" . $availsize["height"] . ". Requested size: " . $getwidth . "x" . $getheight);
|
||||||
|
if ($availsize["width"] == $getwidth && $availsize["height"] == $getheight) {
|
||||||
|
$getsize = $availsize["id"];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!isset($getsize)) {
|
||||||
|
if (!$iiif_custom_sizes || $getwidth > $iiif_max_width || $getheight > $iiif_max_height) {
|
||||||
|
// Invalid size requested
|
||||||
|
$errors[] = "Invalid size requested";
|
||||||
|
iiif_error(400, $errors);
|
||||||
|
} else {
|
||||||
|
$getsize = "resized_" . $getwidth . "_" . $getheight;
|
||||||
|
$getext = "jpg";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} elseif ($size == "full" || $size == "max" || $size == "thm") {
|
||||||
|
if ($tile_request) {
|
||||||
|
if ($size == "full" || $size == "max") {
|
||||||
|
$getsize = "tile_" . $regionx . "_" . $regiony . "_" . $regionw . "_" . $regionh;
|
||||||
|
$getext = "jpg";
|
||||||
|
} else {
|
||||||
|
$errors[] = "Invalid tile size requested";
|
||||||
|
iiif_error(501, $errors);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
// Full/max image region requested
|
||||||
|
if ($iiif_max_width >= $imageWidth && $iiif_max_height >= $imageHeight) {
|
||||||
|
$isjpeg = in_array(strtolower($resource["file_extension"]), array("jpg","jpeg"));
|
||||||
|
$getext = strtolower($resource["file_extension"]) == "jpeg" ? "jpeg" : "jpg";
|
||||||
|
$getsize = $isjpeg ? "" : "hpr";
|
||||||
|
} else {
|
||||||
|
$getext = "jpg";
|
||||||
|
$getsize = count($availsizes) > 0 ? $availsizes[0]["id"] : "thm";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$errors[] = "Invalid size requested";
|
||||||
|
iiif_error(400, $errors);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($rotation != 0) {
|
||||||
|
// Rotation. As we only support IIIF Image level 0 only a rotation value of 0 is accepted
|
||||||
|
$errors[] = "Invalid rotation requested. Only '0' is permitted.";
|
||||||
|
iiif_error(404, $errors);
|
||||||
|
}
|
||||||
|
if (isset($quality) && $quality != "default" && $quality != "color") {
|
||||||
|
// Quality. As we only support IIIF Image level 0 only a quality value of 'default' or 'color' is accepted
|
||||||
|
$errors[] = "Invalid quality requested. Only 'default' is permitted";
|
||||||
|
iiif_error(404, $errors);
|
||||||
|
}
|
||||||
|
if (isset($format) && strtolower($format) != "jpg") {
|
||||||
|
// Format. As we only support IIIF Image level 0 only a value of 'jpg' is accepted
|
||||||
|
$errors[] = "Invalid format requested. Only 'jpg' is permitted.";
|
||||||
|
iiif_error(404, $errors);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!isset($errorcode)) {
|
||||||
|
// Request is supported, send the image
|
||||||
|
$imgpath = get_resource_path($resourceid, true, $getsize, false, $getext);
|
||||||
|
if ($tile_request && !file_exists($imgpath)) {
|
||||||
|
// Support older tiles without scale factor in ID that may not have been recreated
|
||||||
|
$imgpath = preg_replace("/(tile_\\d+_)/", "tile_", $imgpath);
|
||||||
|
}
|
||||||
|
debug("IIIF: image path: " . $imgpath);
|
||||||
|
if (file_exists($imgpath)) {
|
||||||
|
$imgfound = true;
|
||||||
|
} else {
|
||||||
|
if ($region != "full" && $region != "max") {
|
||||||
|
// Tiles have not yet been created
|
||||||
|
if (is_process_lock('create_previews_' . $resource["ref"] . "_tiles")) {
|
||||||
|
$errors[] = "Requested image is not currently available";
|
||||||
|
iiif_error(503, $errors);
|
||||||
|
}
|
||||||
|
set_process_lock('create_previews_' . $resource["ref"] . "_tiles");
|
||||||
|
$imgfound = @create_previews($resourceid, false, "jpg", false, true, -1, true, false, false, array("tiles"));
|
||||||
|
clear_process_lock('create_previews_' . $resource["ref"] . "_tiles");
|
||||||
|
} else {
|
||||||
|
if (is_process_lock('create_previews_' . $resource["ref"] . "_" . $getsize)) {
|
||||||
|
$errors[] = "Requested image is not currently available";
|
||||||
|
iiif_error(503, $errors);
|
||||||
|
}
|
||||||
|
$imgfound = @create_previews($resourceid, false, "jpg", false, true, -1, true, false, false, array($getsize));
|
||||||
|
clear_process_lock('create_previews_' . $resource["ref"] . "_" . $getsize);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ($imgfound) {
|
||||||
|
$validrequest = true;
|
||||||
|
$response_image = $imgpath;
|
||||||
|
} else {
|
||||||
|
$errors[] = "No image available for this identifier";
|
||||||
|
iiif_error(404, $errors);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/* IMAGE REQUEST END */
|
||||||
|
} else {
|
||||||
|
$errors[] = "Missing or invalid identifier";
|
||||||
|
iiif_error(404, $errors);
|
||||||
|
}
|
||||||
|
} // End of image API
|
||||||
|
else {
|
||||||
|
// Presentation API
|
||||||
|
$identifier = $xpath[0];
|
||||||
|
if ($identifier != "" && !isset($xpath[1])) {
|
||||||
|
// Redirect to image information document
|
||||||
|
$redirurl = $_SERVER["REQUEST_URI"] . (!isset($xpath[2]) ? "/" : "") . "manifest";
|
||||||
|
if (function_exists("http_response_code")) {
|
||||||
|
http_response_code(303); # Send error status
|
||||||
|
}
|
||||||
|
header("Location: " . $redirurl);
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
|
||||||
|
$iiif_field = get_resource_type_field($iiif_identifier_field);
|
||||||
|
$iiif_search = $iiif_field["name"] . ":" . $identifier;
|
||||||
|
$iiif_results = do_search($iiif_search);
|
||||||
|
|
||||||
|
if (is_array($iiif_results) && count($iiif_results) > 0) {
|
||||||
|
if (!isset($xpath[1])) {
|
||||||
|
$errors[] = "Bad request. Valid options are 'manifest', 'sequence' or 'canvas' e.g. ";
|
||||||
|
$errors[] = "For the manifest: " . $rooturl . $xpath[0] . "/manifest";
|
||||||
|
$errors[] = "For a sequence : " . $rooturl . $xpath[0] . "/sequence";
|
||||||
|
$errors[] = "For a canvas : " . $rooturl . $xpath[0] . "/canvas/<identifier>";
|
||||||
|
iiif_error(404, $errors);
|
||||||
|
} else {
|
||||||
|
if (!is_array($iiif_results) || count($iiif_results) == 0) {
|
||||||
|
$errors[] = "Invalid identifier: " . $identifier;
|
||||||
|
iiif_error(404, $errors);
|
||||||
|
} else {
|
||||||
|
// Add sequence position information
|
||||||
|
$resultcount = count($iiif_results);
|
||||||
|
$iiif_results_with_position = array();
|
||||||
|
$iiif_results_without_position = array();
|
||||||
|
for ($n = 0; $n < $resultcount; $n++) {
|
||||||
|
if (isset($iiif_sequence_field)) {
|
||||||
|
if (isset($iiif_results[$n]["field" . $iiif_sequence_field])) {
|
||||||
|
$sequenceid = $iiif_results[$n]["field" . $iiif_sequence_field];
|
||||||
|
} else {
|
||||||
|
$sequenceid = get_data_by_field($iiif_results[$n]["ref"], $iiif_sequence_field);
|
||||||
|
}
|
||||||
|
$sequence_field = get_resource_type_field($iiif_sequence_field);
|
||||||
|
$sequence_prefix = $sequence_field["name"] . " ";
|
||||||
|
|
||||||
|
if (!isset($sequenceid) || trim($sequenceid) == "") {
|
||||||
|
// Processing resources without a sequence position separately
|
||||||
|
debug("IIIF: position empty for resource ref " . $iiif_results[$n]["ref"]);
|
||||||
|
$iiif_results_without_position[] = $iiif_results[$n];
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
debug("IIIF: position $sequenceid found in resource ref " . $iiif_results[$n]["ref"]);
|
||||||
|
$iiif_results[$n]["iiif_position"] = $sequenceid;
|
||||||
|
$iiif_results_with_position[] = $iiif_results[$n];
|
||||||
|
} else {
|
||||||
|
$sequenceid = $n;
|
||||||
|
debug("IIIF: position $position assigned to resource ref " . $iiif_results[$n]["ref"]);
|
||||||
|
$iiif_results[$n]["iiif_position"] = $sequenceid;
|
||||||
|
$iiif_results_with_position[] = $iiif_results[$n];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Sort by user supplied position (handle blanks and duplicates)
|
||||||
|
if (isset($iiif_sequence_field)) {
|
||||||
|
# First sort by ref. Any duplicate positions will then be sorted oldest resource first.
|
||||||
|
usort($iiif_results_with_position, function ($a, $b) {
|
||||||
|
return $a['ref'] - $b['ref'];
|
||||||
|
});
|
||||||
|
# Sort resources with user supplied position.
|
||||||
|
usort($iiif_results_with_position, function ($a, $b) {
|
||||||
|
if (is_int_loose($a['iiif_position']) && is_int_loose($b['iiif_position'])) {
|
||||||
|
return $a['iiif_position'] - $b['iiif_position'];
|
||||||
|
} elseif (is_int_loose($a['iiif_position']) || is_int_loose($b['iiif_position'])) {
|
||||||
|
return is_int_loose($a['iiif_position']) ? 1 : -1; // Put strings before numbers
|
||||||
|
}
|
||||||
|
return strcmp($a['iiif_position'], $b['iiif_position']);
|
||||||
|
});
|
||||||
|
|
||||||
|
if (count($iiif_results_without_position) > 0 && count($iiif_results_with_position) > 0) {
|
||||||
|
# Sort resources without a user supplied position by resource reference.
|
||||||
|
# These will appear at the end of the sequence after those with a user supplied position.
|
||||||
|
# Only applies if some resources have a sequence position else return in search results order per earlier behaviour.
|
||||||
|
usort($iiif_results_without_position, function ($a, $b) {
|
||||||
|
return $a['ref'] - $b['ref'];
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
$iiif_results = array_merge($iiif_results_with_position, $iiif_results_without_position);
|
||||||
|
|
||||||
|
$sorted_final = [];
|
||||||
|
$maxid = 0;
|
||||||
|
foreach ($iiif_results as $index => $resource) {
|
||||||
|
# Update iiif_position after sorting using unique array key, removing potential user entered duplicates in sequence field.
|
||||||
|
# iiif_get_canvases() requires unique iiif_position values.
|
||||||
|
$resourcepos = $resource['iiif_position'] ?? ($maxid + 1);
|
||||||
|
while (isset($sorted_final[$resourcepos])) {
|
||||||
|
$resourcepos++;
|
||||||
|
}
|
||||||
|
|
||||||
|
debug("IIIF: final position $index given for resource ref " . $resource["ref"] . " sequence id: " . $resourcepos);
|
||||||
|
$sorted_final[$index] = $resource;
|
||||||
|
$sorted_final[$index]["iiif_position"] = $resourcepos;
|
||||||
|
$maxid = max((int) $resourcepos, $maxid);
|
||||||
|
}
|
||||||
|
$iiif_results = $sorted_final;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($xpath[1] == "manifest" || $xpath[1] == "") {
|
||||||
|
/* MANIFEST REQUEST - see http://iiif.io/api/presentation/2.1/#manifest */
|
||||||
|
$response["@context"] = "http://iiif.io/api/presentation/2/context.json";
|
||||||
|
$response["@id"] = $rooturl . $identifier . "/manifest";
|
||||||
|
$response["@type"] = "sc:Manifest";
|
||||||
|
|
||||||
|
// Descriptive metadata about the object/work
|
||||||
|
// The manifest data should be the same for all resources that are returned.
|
||||||
|
// This is the default when using the tms_link plugin for TMS integration.
|
||||||
|
// Therefore we use the data from the first returned result.
|
||||||
|
$iiif_data = get_resource_field_data($iiif_results[0]["ref"]);
|
||||||
|
|
||||||
|
// Label property
|
||||||
|
foreach ($iiif_results as $iiif_result) {
|
||||||
|
// Keep on until we find a label
|
||||||
|
$iiif_label = get_data_by_field($iiif_results[0]["ref"], $view_title_field);
|
||||||
|
if (trim($iiif_label) != "") {
|
||||||
|
$response["label"] = $iiif_label;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!$iiif_label) {
|
||||||
|
$response["label"] = $lang["notavailableshort"];
|
||||||
|
}
|
||||||
|
|
||||||
|
$response["description"] = get_data_by_field($iiif_results[0]["ref"], $iiif_description_field);
|
||||||
|
|
||||||
|
// Construct metadata array from resource field data
|
||||||
|
$response["metadata"] = array();
|
||||||
|
$n = 0;
|
||||||
|
foreach ($iiif_data as $iiif_data_row) {
|
||||||
|
if (in_array($iiif_data_row["type"], $FIXED_LIST_FIELD_TYPES)) {
|
||||||
|
// Don't use the data as this has already concatentated the translations, add an entry for each node translation by building up a new array
|
||||||
|
$resnodes = get_resource_nodes($iiif_results[0]["ref"], $iiif_data_row["resource_type_field"], true);
|
||||||
|
if (count($resnodes) == 0) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
$langentries = array();
|
||||||
|
$nodecount = 0;
|
||||||
|
unset($def_lang);
|
||||||
|
foreach ($resnodes as $resnode) {
|
||||||
|
debug("IIIF: translating " . $resnode["name"] . " from field '" . $iiif_data_row["title"] . "'");
|
||||||
|
$node_langs = i18n_get_translations($resnode["name"]);
|
||||||
|
$transcount = 0;
|
||||||
|
$defaulttrans = "";
|
||||||
|
foreach ($node_langs as $nlang => $nltext) {
|
||||||
|
if (!isset($langentries[$nlang])) {
|
||||||
|
// This is the first translated node entry for this language. If we already have translations copy the default language array to make sure no nodes with missing translations are lost
|
||||||
|
debug("IIIF: Adding a new translation entry for language '" . $nlang . "', field '" . $iiif_data_row["title"] . "'");
|
||||||
|
$langentries[$nlang] = isset($def_lang) ? $def_lang : array();
|
||||||
|
}
|
||||||
|
// Add the node text to the array for this language;
|
||||||
|
debug("IIIF: Adding node translation for language '" . $nlang . "', field '" . $iiif_data_row["title"] . "': " . $nltext);
|
||||||
|
$langentries[$nlang][] = $nltext;
|
||||||
|
|
||||||
|
// Set default text for any translations
|
||||||
|
if ($nlang == $defaultlanguage || $defaulttrans == "") {
|
||||||
|
$defaulttrans = $nltext;
|
||||||
|
}
|
||||||
|
$transcount++;
|
||||||
|
}
|
||||||
|
$nodecount++;
|
||||||
|
|
||||||
|
// There may not be translations for all nodes, fill any arrays that don't have an entry with the untranslated versions
|
||||||
|
foreach ($langentries as $mdlang => $mdtrans) {
|
||||||
|
debug("IIIF: entry count for " . $mdlang . ":" . count($mdtrans));
|
||||||
|
debug("IIIF: node count: " . $nodecount);
|
||||||
|
if (count($mdtrans) != $nodecount) {
|
||||||
|
debug("IIIF: No translation found for " . $mdlang . ". Adding default translation to language array for field '" . $iiif_data_row["title"] . "': " . $mdlang . ": " . $defaulttrans);
|
||||||
|
$langentries[$mdlang][] = $defaulttrans;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// To ensure that no nodes are lost due to missing translations,
|
||||||
|
// Save the default language array to make sure we include any untranslated nodes that may be missing when/if we find new languages for the next node
|
||||||
|
|
||||||
|
debug("IIIF: Saving default language array for field '" . $iiif_data_row["title"] . "': " . implode(",", $langentries[$defaultlanguage]));
|
||||||
|
// Default language is the ideal, but if no default language entries for this node have been found copy the first language we have
|
||||||
|
reset($langentries);
|
||||||
|
$def_lang = isset($langentries[$defaultlanguage]) ? $langentries[$defaultlanguage] : $langentries[key($langentries)];
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
$response["metadata"][$n] = array();
|
||||||
|
$response["metadata"][$n]["label"] = $iiif_data_row["title"];
|
||||||
|
$response["metadata"][$n]["value"] = array();
|
||||||
|
|
||||||
|
// Add each tag
|
||||||
|
$o = 0;
|
||||||
|
foreach ($langentries as $mdlang => $mdtrans) {
|
||||||
|
debug("IIIF: adding to metadata language array: " . $mdlang . ": " . implode(",", $mdtrans));
|
||||||
|
$response["metadata"][$n]["value"][$o]["@value"] = implode(",", array_values($mdtrans));
|
||||||
|
$response["metadata"][$n]["value"][$o]["@language"] = $mdlang;
|
||||||
|
$o++;
|
||||||
|
}
|
||||||
|
$n++;
|
||||||
|
} elseif (trim((string) $iiif_data_row["value"]) != "") {
|
||||||
|
$response["metadata"][$n] = array();
|
||||||
|
$response["metadata"][$n]["label"] = $iiif_data_row["title"];
|
||||||
|
$response["metadata"][$n]["value"] = $iiif_data_row["value"];
|
||||||
|
$n++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$response["description"] = get_data_by_field($iiif_results[0]["ref"], $iiif_description_field);
|
||||||
|
if (isset($iiif_license_field)) {
|
||||||
|
$response["license"] = get_data_by_field($iiif_results[0]["ref"], $iiif_license_field);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Thumbnail property
|
||||||
|
foreach ($iiif_results as $iiif_result) {
|
||||||
|
// Keep on until we find an image
|
||||||
|
$iiif_thumb = iiif_get_thumbnail($iiif_results[0]["ref"]);
|
||||||
|
if ($iiif_thumb) {
|
||||||
|
$response["thumbnail"] = $iiif_thumb;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!$iiif_thumb) {
|
||||||
|
$response["thumbnail"] = $baseurl . "/gfx/no_preview/default.png";
|
||||||
|
}
|
||||||
|
|
||||||
|
// Sequences
|
||||||
|
$response["sequences"] = array();
|
||||||
|
$response["sequences"][0]["@id"] = $rooturl . $identifier . "/sequence/normal";
|
||||||
|
$response["sequences"][0]["@type"] = "sc:Sequence";
|
||||||
|
$response["sequences"][0]["label"] = "Default order";
|
||||||
|
|
||||||
|
$response["sequences"][0]["canvases"] = iiif_get_canvases($identifier, $iiif_results, false);
|
||||||
|
$validrequest = true;
|
||||||
|
/* MANIFEST REQUEST END */
|
||||||
|
} elseif ($xpath[1] == "canvas") {
|
||||||
|
// This is essentially a resource
|
||||||
|
// {scheme}://{host}/{prefix}/{identifier}/canvas/{name}
|
||||||
|
$canvasid = $xpath[2];
|
||||||
|
$allcanvases = iiif_get_canvases($identifier, $iiif_results, true);
|
||||||
|
$response["@context"] = "http://iiif.io/api/presentation/2/context.json";
|
||||||
|
$response = array_merge($response, $allcanvases[$canvasid]);
|
||||||
|
$validrequest = true;
|
||||||
|
} elseif ($xpath[1] == "sequence") {
|
||||||
|
if (isset($xpath[2]) && $xpath[2] == "normal") {
|
||||||
|
$response["@context"] = "http://iiif.io/api/presentation/2/context.json";
|
||||||
|
$response["@id"] = $rooturl . $identifier . "/sequence/normal";
|
||||||
|
$response["@type"] = "sc:Sequence";
|
||||||
|
$response["label"] = "Default order";
|
||||||
|
$response["canvases"] = iiif_get_canvases($identifier, $iiif_results);
|
||||||
|
$validrequest = true;
|
||||||
|
}
|
||||||
|
} elseif ($xpath[1] == "annotation") {
|
||||||
|
// See http://iiif.io/api/presentation/2.1/#image-resources
|
||||||
|
$annotationid = $xpath[2];
|
||||||
|
|
||||||
|
// Need to find the resourceid the annotation is linked to
|
||||||
|
if (isset($iiif_results[$annotationid])) {
|
||||||
|
$resourceid = $iiif_results[$annotationid]["ref"];
|
||||||
|
$size_info = array(
|
||||||
|
'identifier' => (strtolower($iiif_results[$annotationid]['file_extension']) != 'jpg') ? 'hpr' : '',
|
||||||
|
'return_height_width' => false,
|
||||||
|
);
|
||||||
|
$validrequest = true;
|
||||||
|
}
|
||||||
|
if ($validrequest) {
|
||||||
|
$response["@context"] = "http://iiif.io/api/presentation/2/context.json";
|
||||||
|
$response["@id"] = $rooturl . $identifier . "/annotation/" . $annotationid;
|
||||||
|
$response["@type"] = "oa:Annotation";
|
||||||
|
$response["motivation"] = "sc:painting";
|
||||||
|
$response["resource"] = iiif_get_image($identifier, $resourceid, $annotationid, $size_info);
|
||||||
|
$response["on"] = $rooturl . $identifier . "/canvas/" . $annotationid;
|
||||||
|
} else {
|
||||||
|
$errors[] = "Invalid annotation identifier: " . $annotationid;
|
||||||
|
iiif_error(404, $errors);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} // End of valid $identifier check based on search results
|
||||||
|
else {
|
||||||
|
$errors[] = "Invalid identifier: " . $identifier;
|
||||||
|
iiif_error(404, $errors);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// Send the data
|
||||||
|
if ($validrequest) {
|
||||||
|
if (function_exists("http_response_code")) {
|
||||||
|
http_response_code(200); # Send OK
|
||||||
|
}
|
||||||
|
header("Access-Control-Allow-Origin: *");
|
||||||
|
header("Access-Control-Allow-Headers: Accept");
|
||||||
|
if (isset($response_image) && file_exists($response_image)) {
|
||||||
|
// Send the image
|
||||||
|
$file_size = filesize_unlimited($response_image);
|
||||||
|
$file_handle = fopen($response_image, 'rb');
|
||||||
|
header("Access-Control-Allow-Origin: *");
|
||||||
|
header("Access-Control-Allow-Headers: Accept");
|
||||||
|
header('Content-Disposition: inline;');
|
||||||
|
header('Content-Transfer-Encoding: binary');
|
||||||
|
$mime = get_mime_type($response_image)[0];
|
||||||
|
header("Content-Type: {$mime}");
|
||||||
|
$sent = 0;
|
||||||
|
while ($sent < $file_size) {
|
||||||
|
echo fread($file_handle, $download_chunk_size);
|
||||||
|
ob_flush();
|
||||||
|
flush();
|
||||||
|
$sent += $download_chunk_size;
|
||||||
|
if (0 != connection_status()) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fclose($file_handle);
|
||||||
|
} else {
|
||||||
|
header("Content-Type: application/ld+json");
|
||||||
|
foreach ($iiif_headers as $iiif_header) {
|
||||||
|
header($iiif_header);
|
||||||
|
}
|
||||||
|
if (defined('JSON_PRETTY_PRINT')) {
|
||||||
|
echo json_encode($response, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);
|
||||||
|
} else {
|
||||||
|
echo json_encode($response);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
exit();
|
||||||
|
}
|
91
api/index.php
Normal file
@@ -0,0 +1,91 @@
|
|||||||
|
<?php
|
||||||
|
$disable_browser_check = true;
|
||||||
|
|
||||||
|
include "../include/boot.php";
|
||||||
|
header('Content-Type: application/json');
|
||||||
|
include_once "../include/image_processing.php";
|
||||||
|
include_once "../include/api_functions.php";
|
||||||
|
include_once "../include/ajax_functions.php";
|
||||||
|
include_once "../include/api_bindings.php";
|
||||||
|
include_once "../include/login_functions.php";
|
||||||
|
include_once "../include/dash_functions.php";
|
||||||
|
|
||||||
|
# Get authentication mode (userkey, sessionkey or native)
|
||||||
|
$authmode = getval("authmode", "userkey");
|
||||||
|
|
||||||
|
# Native authmode always required
|
||||||
|
if (!$enable_remote_apis && $authmode !== "native") {
|
||||||
|
http_response_code(403);
|
||||||
|
exit("API not enabled.");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
define("API_CALL", true);
|
||||||
|
|
||||||
|
# Get parameters
|
||||||
|
$user = getval("user", "");
|
||||||
|
$sign = getval("sign", "");
|
||||||
|
$query = $_SERVER["QUERY_STRING"];
|
||||||
|
$pretty = filter_var(getval('pretty', ''), FILTER_VALIDATE_BOOLEAN); # Should response be prettyfied?
|
||||||
|
|
||||||
|
# Support POST request where 'query' is POSTed and is the full query string.
|
||||||
|
if (getval("query", "") != "") {
|
||||||
|
$query = getval("query", "");
|
||||||
|
}
|
||||||
|
|
||||||
|
debug("API:". $query);
|
||||||
|
|
||||||
|
|
||||||
|
# Remove the pretty, sign and authmode parameters if passed as these would not have been present when signed on the client.
|
||||||
|
# For example, pretty JSON is just how the client wants the response back, doesn't need to to be part of the signing key process.
|
||||||
|
parse_str($query, $query_params);
|
||||||
|
if (isset($query_params['sign'])) {
|
||||||
|
$query = str_ireplace("sign=" . $query_params['sign'], "!|!|", $query);
|
||||||
|
}
|
||||||
|
if (isset($query_params['authmode'])) {
|
||||||
|
$query = str_ireplace("authmode=" . $query_params['authmode'], "!|!|", $query);
|
||||||
|
}
|
||||||
|
if (isset($query_params['pretty'])) {
|
||||||
|
$query = str_ireplace("pretty=" . $query_params['pretty'], "!|!|", $query);
|
||||||
|
}
|
||||||
|
$query = str_replace("&!|!|", "", ltrim($query, "!|!|&")); # remove joining &
|
||||||
|
|
||||||
|
$validauthmodes = array("userkey", "native", "sessionkey");
|
||||||
|
$function = getval("function", "");
|
||||||
|
if (!in_array($authmode, $validauthmodes)) {
|
||||||
|
$authmode = "userkey";
|
||||||
|
}
|
||||||
|
if ($function != "login") {
|
||||||
|
if ($authmode == "native") {
|
||||||
|
debug("API: Native authmode, authenticating");
|
||||||
|
define('API_AUTHMODE_NATIVE', true);
|
||||||
|
include __DIR__ . "/../include/authenticate.php";
|
||||||
|
debug("API: Native authmode, authenticated OK");
|
||||||
|
} else {
|
||||||
|
# Authenticate based on the provided signature.
|
||||||
|
if (!check_api_key($user, $query, $sign, $authmode)) {
|
||||||
|
debug("API: Invalid signature");
|
||||||
|
http_response_code(401);
|
||||||
|
exit("Invalid signature");
|
||||||
|
}
|
||||||
|
|
||||||
|
# Log user in (if permitted)
|
||||||
|
$validuser = setup_user(get_user(get_user_by_username($user)));
|
||||||
|
if (!$validuser) {
|
||||||
|
ajax_send_response(
|
||||||
|
401,
|
||||||
|
['error' => [
|
||||||
|
'status' => 401,
|
||||||
|
'title' => $GLOBALS['lang']['unauthorized'],
|
||||||
|
'detail' => $GLOBALS['lang']['error-permissiondenied']
|
||||||
|
]]
|
||||||
|
);
|
||||||
|
}
|
||||||
|
update_user_access(0, ["last_browser" => isset($_SERVER["HTTP_USER_AGENT"]) ? substr($_SERVER["HTTP_USER_AGENT"], 0, 250) : "API"]);
|
||||||
|
set_sysvar("last_api_access",date("Y-m-d H:i"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
debug("API: Executing API call");
|
||||||
|
echo execute_api_call($query, $pretty);
|
||||||
|
debug("API: finished execute_api_call({$query});");
|
243
batch/create_previews.php
Normal file
@@ -0,0 +1,243 @@
|
|||||||
|
#!/usr/bin/php
|
||||||
|
<?php
|
||||||
|
|
||||||
|
if (PHP_SAPI != 'cli') {
|
||||||
|
exit("Command line execution only.");
|
||||||
|
}
|
||||||
|
|
||||||
|
include __DIR__ . "/../include/boot.php";
|
||||||
|
include_once __DIR__ . "/../include/image_processing.php";
|
||||||
|
|
||||||
|
# Prevent this script from creating offline jobs for tasks such as extracting text.
|
||||||
|
# Offline jobs shouldn't be created here as they require a valid user ref to be processed.
|
||||||
|
# This is running offline anyway so no need to create more jobs.
|
||||||
|
$offline_job_queue = false;
|
||||||
|
|
||||||
|
$ignoremaxsize = false;
|
||||||
|
$noimage = false;
|
||||||
|
if ($argc >= 2) {
|
||||||
|
$validargs = false;
|
||||||
|
if (in_array($argv[1], array('--help', '-help', '-h', '-?'))) {
|
||||||
|
echo "To clear the lock after a failed run, ";
|
||||||
|
echo "pass in '-clearlock'\n";
|
||||||
|
echo "To ignore the maximum preview size configured ($preview_generate_max_file_size), ";
|
||||||
|
echo "pass in '-ignoremaxsize'.\n";
|
||||||
|
exit("Bye!");
|
||||||
|
}
|
||||||
|
if (in_array('-ignoremaxsize', $argv)) {
|
||||||
|
$ignoremaxsize = true;
|
||||||
|
$validargs = true;
|
||||||
|
}
|
||||||
|
if (in_array('-noimage', $argv)) {
|
||||||
|
$noimage = true; #
|
||||||
|
$validargs = true;
|
||||||
|
}
|
||||||
|
if (in_array('-clearlock', $argv)) {
|
||||||
|
if (is_process_lock("create_previews")) {
|
||||||
|
clear_process_lock("create_previews");
|
||||||
|
}
|
||||||
|
$validargs = true;
|
||||||
|
}
|
||||||
|
if (!$validargs) {
|
||||||
|
exit("Unknown argv: " . $argv[1]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# Check for a process lock
|
||||||
|
if (is_process_lock("create_previews")) {
|
||||||
|
exit("Process lock is in place. Deferring.");
|
||||||
|
}
|
||||||
|
set_process_lock("create_previews");
|
||||||
|
|
||||||
|
if (function_exists("pcntl_signal")) {
|
||||||
|
$multiprocess = true;
|
||||||
|
} else {
|
||||||
|
$multiprocess = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// We store the start date.
|
||||||
|
$global_start_time = microtime(true);
|
||||||
|
|
||||||
|
// We define the number of threads.
|
||||||
|
$max_forks = 3;
|
||||||
|
|
||||||
|
$lock_directory = '.';
|
||||||
|
|
||||||
|
// We create an array to store children pids.
|
||||||
|
$children = array();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This function clean up the list of children pids.
|
||||||
|
* This allow to detect the freeing of a thread slot.
|
||||||
|
*/
|
||||||
|
function reap_children()
|
||||||
|
{
|
||||||
|
global $children;
|
||||||
|
|
||||||
|
$tmp = array();
|
||||||
|
|
||||||
|
foreach ($children as $pid) {
|
||||||
|
if (pcntl_waitpid($pid, $status, WNOHANG) != $pid) {
|
||||||
|
array_push($tmp, $pid);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$children = $tmp;
|
||||||
|
|
||||||
|
return count($tmp);
|
||||||
|
} // reap_children()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This function is used to process SIGALRM signal.
|
||||||
|
* This is usefull when the parent process is killed.
|
||||||
|
*/
|
||||||
|
function sigalrm_handler()
|
||||||
|
{
|
||||||
|
die("[SIGALRM] hang in thumbnails creation ?\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This function is used to process SIGCHLD signal.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
function sigchld_handler($signal)
|
||||||
|
{
|
||||||
|
reap_children();
|
||||||
|
|
||||||
|
pcntl_waitpid(-1, $status, WNOHANG);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This function is used to process SIGINT signal.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
function sigint_handler()
|
||||||
|
{
|
||||||
|
die("[SIGINT] exiting.\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// We define the functions to use for signal handling.
|
||||||
|
if ($multiprocess) {
|
||||||
|
pcntl_signal(SIGALRM, 'sigalrm_handler');
|
||||||
|
pcntl_signal(SIGCHLD, 'sigchld_handler');
|
||||||
|
}
|
||||||
|
$sql = "SELECT ref,
|
||||||
|
file_extension,
|
||||||
|
IFNULL(preview_attempts, 1) preview_attempts,
|
||||||
|
creation_date
|
||||||
|
FROM resource
|
||||||
|
WHERE ref > 0
|
||||||
|
AND no_file <> 1
|
||||||
|
AND (preview_attempts < ? OR preview_attempts IS NULL)
|
||||||
|
AND file_extension IS NOT NULL
|
||||||
|
AND LENGTH(file_extension) > 0
|
||||||
|
AND LOWER(file_extension) NOT IN (" . ps_param_insert(count($no_preview_extensions)) . ")";
|
||||||
|
$params = array_merge(["i", SYSTEM_MAX_PREVIEW_ATTEMPTS], ps_param_fill($no_preview_extensions, "s"));
|
||||||
|
|
||||||
|
$extraconditions = "";
|
||||||
|
if (!$noimage) {
|
||||||
|
$extraconditions .= " AND has_image != ? ";
|
||||||
|
$params[] = "i";
|
||||||
|
$params[] = RESOURCE_PREVIEWS_ALL;
|
||||||
|
}
|
||||||
|
|
||||||
|
$resources = ps_query($sql . $extraconditions, $params);
|
||||||
|
|
||||||
|
foreach ($resources as $resource) { // For each resources
|
||||||
|
// We wait for a fork emplacement to be freed.
|
||||||
|
if ($multiprocess) {
|
||||||
|
while (count($children) >= $max_forks) {
|
||||||
|
// We clean children list.
|
||||||
|
reap_children();
|
||||||
|
sleep(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!$multiprocess || count($children) < $max_forks) { // Test if we can create a new fork.
|
||||||
|
// fork
|
||||||
|
if (!$multiprocess) {
|
||||||
|
$pid = false;
|
||||||
|
} else {
|
||||||
|
$pid = pcntl_fork();
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($pid == -1) {
|
||||||
|
die("fork failed!\n");
|
||||||
|
} elseif ($pid) {
|
||||||
|
array_push($children, $pid);
|
||||||
|
} else {
|
||||||
|
if ($multiprocess) {
|
||||||
|
pcntl_signal(SIGCHLD, SIG_IGN);
|
||||||
|
pcntl_signal(SIGINT, SIG_DFL);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Processing resource.
|
||||||
|
echo sprintf("Processing resource id " . $resource['ref'] . " - preview attempt #" . $resource['preview_attempts'] . "\n");
|
||||||
|
|
||||||
|
$start_time = microtime(true);
|
||||||
|
|
||||||
|
// For each fork, we need a new connection to database.
|
||||||
|
sql_connect();
|
||||||
|
|
||||||
|
# Below added to catch an issue with previews failing when large video files were taking a long time to copy to StaticSync location
|
||||||
|
echo "Created at: " . $resource['creation_date'] . "\nTime now: " . date("Y-m-d H:i:s") . "\n";
|
||||||
|
$resourceage = time() - strtotime($resource['creation_date']);
|
||||||
|
if ($resource['preview_attempts'] > 3 && $resourceage < 1000) {
|
||||||
|
echo "Just added so may not have finished copying, resetting attempts \n";
|
||||||
|
ps_query("UPDATE resource SET preview_attempts = 0 WHERE ref = ?", array("i", $resource['ref']));
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
#check whether resource already has mp3 preview in which case we set preview_attempts to 5
|
||||||
|
if (
|
||||||
|
$resource['file_extension'] != "mp3"
|
||||||
|
&& in_array($resource['file_extension'], $ffmpeg_audio_extensions)
|
||||||
|
&& file_exists(get_resource_path($resource['ref'], true, "", false, "mp3"))
|
||||||
|
) {
|
||||||
|
$ref = $resource['ref'];
|
||||||
|
echo "Resource already has mp3 preview\n";
|
||||||
|
ps_query("UPDATE resource SET preview_attempts = 5 WHERE ref = ?", array("i", $ref));
|
||||||
|
} elseif ($resource['preview_attempts'] < 5 && $resource['file_extension'] != "") {
|
||||||
|
if (!empty($resource['file_path'])) {
|
||||||
|
$ingested = false;
|
||||||
|
} else {
|
||||||
|
$ingested = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
# Increment the preview count.
|
||||||
|
ps_query("UPDATE resource SET preview_attempts = IFNULL(preview_attempts, 1) + 1 WHERE ref = ?", array("i", $resource['ref']));
|
||||||
|
|
||||||
|
$success = create_previews($resource['ref'], false, $resource['file_extension'], false, false, -1, $ignoremaxsize, $ingested);
|
||||||
|
hook('after_batch_create_preview');
|
||||||
|
$success_string = ($success ? "successfully" : "with error" );
|
||||||
|
echo sprintf("Processed resource %d %s in %01.2f seconds.\n", $resource['ref'], $success_string, microtime(true) - $start_time);
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($multiprocess) {
|
||||||
|
// We exit in order to avoid fork bombing.
|
||||||
|
exit(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} // Test if we can create a new fork
|
||||||
|
} // For each resources
|
||||||
|
|
||||||
|
// We wait for all forks to exit.
|
||||||
|
if ($multiprocess) {
|
||||||
|
while (count($children)) {
|
||||||
|
// We clean children list.
|
||||||
|
reap_children();
|
||||||
|
sleep(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
echo sprintf("Completed in %01.2f seconds.\n", microtime(true) - $global_start_time);
|
||||||
|
|
||||||
|
clear_process_lock("create_previews");
|
53
batch/cron.php
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
include_once __DIR__ . "/../include/boot.php";
|
||||||
|
command_line_only();
|
||||||
|
|
||||||
|
include_once __DIR__ . "/../include/reporting_functions.php";
|
||||||
|
include_once __DIR__ . "/../include/action_functions.php";
|
||||||
|
include_once __DIR__ . "/../include/request_functions.php";
|
||||||
|
|
||||||
|
if (is_process_lock("cron")) {
|
||||||
|
exit($lang["error-processlock-aborting"] . PHP_EOL);
|
||||||
|
}
|
||||||
|
set_process_lock("cron");
|
||||||
|
|
||||||
|
$LINE_END = ('cli' == PHP_SAPI) ? PHP_EOL : "<br>";
|
||||||
|
set_time_limit($cron_job_time_limit);
|
||||||
|
ob_end_flush();
|
||||||
|
ob_implicit_flush();
|
||||||
|
ob_start();
|
||||||
|
|
||||||
|
$this_run_start = date("Y-m-d H:i:s");
|
||||||
|
echo "{$this_run_start} {$baseurl} Starting cron process..." . $LINE_END;
|
||||||
|
|
||||||
|
# Get last cron date
|
||||||
|
$lastcron = get_sysvar('last_cron', '1970-01-01');
|
||||||
|
$lastcrontime = strtotime($lastcron);
|
||||||
|
$sincelast = time() - $lastcrontime;
|
||||||
|
|
||||||
|
// grab a list of files to run as part of the upgrade process
|
||||||
|
$new_system_version_files = array();
|
||||||
|
$files = scandir(__DIR__ . '/cron_jobs');
|
||||||
|
$total_upgrade_files = 0;
|
||||||
|
for ($i = 0; $i <= 999; $i++) {
|
||||||
|
foreach ($files as $file) {
|
||||||
|
if (preg_match('/^' . str_pad($i, 3, '0', STR_PAD_LEFT) . '_.*\.php/', $file)) {
|
||||||
|
$this_job_start = date("Y-m-d H:i:s");
|
||||||
|
echo "{$this_job_start} {$baseurl} Executing job: " . $file . $LINE_END;
|
||||||
|
flush();
|
||||||
|
ob_flush();
|
||||||
|
include __DIR__ . '/cron_jobs/' . $file;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
# Allow plugins to add their own cron jobs.
|
||||||
|
hook("cron");
|
||||||
|
|
||||||
|
$this_run_end = date("Y-m-d H:i:s");
|
||||||
|
echo PHP_EOL . "{$this_run_end} {$baseurl} All tasks complete" . $LINE_END;
|
||||||
|
|
||||||
|
# Update last cron date
|
||||||
|
set_sysvar("last_cron", date("Y-m-d H:i:s"));
|
||||||
|
clear_process_lock("cron");
|
18
batch/cron_jobs/002_copy_hitcount.php
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
// Don't do this more than once a day
|
||||||
|
$last_copy_hitcount = get_sysvar('last_copy_hitcount', '1970-01-01');
|
||||||
|
|
||||||
|
if (time() - strtotime($last_copy_hitcount) > 24 * 60 * 60) {
|
||||||
|
if (is_process_lock("copy_hitcount")) {
|
||||||
|
echo " - copy_hitcount process lock is in place. Skipping.\n";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
set_process_lock("copy_hitcount");
|
||||||
|
copy_hitcount_to_live();
|
||||||
|
clear_process_lock("copy_hitcount");
|
||||||
|
set_sysvar("last_copy_hitcount", date("Y-m-d H:i:s"));
|
||||||
|
} else {
|
||||||
|
echo " - Skipping copy_hitcount_to_live - last run: " . $last_copy_hitcount . $LINE_END;
|
||||||
|
}
|
3
batch/cron_jobs/004_send_periodic_reports.php
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
send_periodic_report_emails(false, true);
|
12
batch/cron_jobs/005_geo_set_coords_from_country.php
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
$last_geo_setcoords_from_country = get_sysvar('last_geo_setcoords_from_country', '1970-01-01');
|
||||||
|
|
||||||
|
// Only run if more than 24 hours since last run
|
||||||
|
if (time() - strtotime($last_geo_setcoords_from_country) < 24 * 60 * 60) {
|
||||||
|
echo " - Skipping geo_setcoords_from_country - last run: " . $last_geo_setcoords_from_country . "<br />\n";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
include __DIR__ . "/../../pages/tools/geo_setcoords_from_country.php";
|
||||||
|
set_sysvar("last_geo_setcoords_from_country", date("Y-m-d H:i:s"));
|
4
batch/cron_jobs/006_update_disk_usage.php
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
# Update disk quota column on resource table.
|
||||||
|
update_disk_usage_cron();
|
4
batch/cron_jobs/007_message_send_unread_emails.php
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
# Send daily digest of notifications
|
||||||
|
message_send_unread_emails();
|
27
batch/cron_jobs/009_flush_unused_keywords.php
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
include_once __DIR__ . "/../../include/boot.php";
|
||||||
|
if ($sysvars["upgrade_system_level"] < 2) {
|
||||||
|
// After migrating to nodes it is preferable to delete resource_keyword rows for fixed list data
|
||||||
|
// as this is now stored in normalised form in resource_node and node_keyword
|
||||||
|
|
||||||
|
// Updated to only delete data if the resource_keyword table still exists - this table will be unused from v10 and likley to be deleted later
|
||||||
|
$alltables = ps_query("SHOW TABLES");
|
||||||
|
$resource_keyword_table = in_array("resource_keyword", array_column($alltables, "Tables_in_" . $mysql_db));
|
||||||
|
if ($resource_keyword_table) {
|
||||||
|
$fixed_fields = ps_array("SELECT ref value FROM resource_type_field WHERE type IN (" . ps_param_insert(count($FIXED_LIST_FIELD_TYPES)) . ")", ps_param_fill($FIXED_LIST_FIELD_TYPES, "i"));
|
||||||
|
|
||||||
|
foreach ($fixed_fields as $fixed_field) {
|
||||||
|
echo " - Deleting resource_keyword data for field ref#" . $fixed_field . $LINE_END;
|
||||||
|
$count_query = "SELECT COUNT(*) value FROM resource_keyword WHERE resource_type_field = ?";
|
||||||
|
$c = ps_value($count_query, array("i", $fixed_field), 0);
|
||||||
|
while ($c > 0) {
|
||||||
|
ps_query("DELETE FROM resource_keyword WHERE resource_type_field = ? LIMIT 1000", array("i", $fixed_field));
|
||||||
|
$c = $c - 1000;
|
||||||
|
echo " -- " . $c . " rows remaining to delete" . $LINE_END;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
echo " - Skipping flush_unused_keywords - already complete" . $LINE_END;
|
||||||
|
}
|
30
batch/cron_jobs/010_remove_anonymous_collections.php
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
include_once __DIR__ . "/../../include/boot.php";
|
||||||
|
|
||||||
|
|
||||||
|
if (isset($anonymous_login)) {
|
||||||
|
$lastrun = get_sysvar('last_remove_anonymous_collections', '1970-01-01');
|
||||||
|
# Don't run if already run in last 24 hours.
|
||||||
|
if (time() - strtotime($lastrun) < 24 * 60 * 60) {
|
||||||
|
echo " - Skipping remove_anonymous_collections - last run: " . $lastrun . "<br />\n";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (is_array($anonymous_login)) {
|
||||||
|
foreach ($anonymous_login as $user) {
|
||||||
|
$anonref = ps_value("SELECT ref value FROM user WHERE username=?", array("s",$user), 0);
|
||||||
|
echo "Deleting old anonymous collections for user " . $user . "(ref: " . $anonref . ")\r\n";
|
||||||
|
$dcols = delete_old_collections($anonref, 7);
|
||||||
|
echo "Deleted " . $dcols . " collections for user " . $user . "\r\n";
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$anonref = ps_value("SELECT ref value FROM user WHERE username=?", array("s",$anonymous_login), 0);
|
||||||
|
echo "Deleting old anonymous collections for user " . $anonymous_login . "(ref: " . $anonref . ")\r\n";
|
||||||
|
$dcols = delete_old_collections($anonref, 7);
|
||||||
|
echo "Deleted " . $dcols . " collections for user " . $anonymous_login . "\r\n";
|
||||||
|
}
|
||||||
|
|
||||||
|
# Update last sent date/time.
|
||||||
|
set_sysvar("last_remove_anonymous_collections", date("Y-m-d H:i:s"));
|
||||||
|
}
|
25
batch/cron_jobs/011_delete_tmp_files.php
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
// Clean up old temp files. These can be left on the system as a result of cancelled or failed downloads/uploads
|
||||||
|
if ($purge_temp_folder_age == 0) {
|
||||||
|
if ('cli' == PHP_SAPI) {
|
||||||
|
echo " - Config purge_temp_folder_age is set to 0 and is considered deactivated. Skipping delete temp files - FAILED" . $LINE_END;
|
||||||
|
}
|
||||||
|
debug("Config purge_temp_folder_age is set to 0 and is considered deactivated. Skipping delete temp files - FAILED");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
$last_delete_tmp_files = get_sysvar('last_delete_tmp_files', '1970-01-01');
|
||||||
|
|
||||||
|
# No need to run if already run in last 24 hours.
|
||||||
|
if (time() - strtotime($last_delete_tmp_files) < 24 * 60 * 60) {
|
||||||
|
if ('cli' == PHP_SAPI) {
|
||||||
|
echo " - Skipping delete_tmp_files job - last run: " . $last_delete_tmp_files . $LINE_END;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
delete_temp_files();
|
||||||
|
|
||||||
|
# Update last sent date/time.
|
||||||
|
set_sysvar("last_delete_tmp_files", date("Y-m-d H:i:s"));
|
20
batch/cron_jobs/012_disable_inactive_users.php
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
$last_disable_inactive_users = get_sysvar('last_disable_inactive_users', '1970-01-01');
|
||||||
|
|
||||||
|
# Skip if run within last 24 hours
|
||||||
|
if (time() - strtotime($last_disable_inactive_users) < 24 * 60 * 60) {
|
||||||
|
echo " - Skipping disable_inactive_users job" . $LINE_END;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
# Disable inactive users
|
||||||
|
if (is_numeric($inactive_user_disable_days) && $inactive_user_disable_days > 0) {
|
||||||
|
ps_query("UPDATE user SET approved = 2 WHERE (created is null OR created < date_sub(now(), interval ? day))
|
||||||
|
AND(last_active is null OR last_active < date_sub(now(), interval ? day))
|
||||||
|
AND approved = 1", array("i", $inactive_user_disable_days, "i", $inactive_user_disable_days));
|
||||||
|
echo " - " . sql_affected_rows() . " users disabled" . $LINE_END;
|
||||||
|
}
|
||||||
|
|
||||||
|
# Update last sent date/time.
|
||||||
|
set_sysvar("last_disable_inactive_users", date("Y-m-d H:i:s"));
|
17
batch/cron_jobs/013_delete_anonymous_collections.php
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
// Clean up old anonymous collections
|
||||||
|
$last_delete_anonymous_cols = get_sysvar('last_delete_anonymous_collections', '1970-01-01');
|
||||||
|
|
||||||
|
# No need to run if already run in last 24 hours.
|
||||||
|
if (time() - strtotime($last_delete_anonymous_cols) < 24 * 60 * 60) {
|
||||||
|
if ('cli' == PHP_SAPI) {
|
||||||
|
echo " - Skipping delete_anonymous_collections job - last run: " . $last_delete_anonymous_cols . $LINE_END;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
cleanup_anonymous_collections(0);
|
||||||
|
|
||||||
|
# Update last run date/time.
|
||||||
|
set_sysvar("last_delete_anonymous_collections", date("Y-m-d H:i:s"));
|
21
batch/cron_jobs/014_update_heatmap.php
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
// Update cached geographic points for use as heatmap on geographic search
|
||||||
|
if ($geo_search_heatmap) {
|
||||||
|
$defaultarchive = get_default_search_states();
|
||||||
|
$defaultarchive = array_filter($defaultarchive, "is_int_loose");
|
||||||
|
|
||||||
|
$allgeopoints = ps_query("SELECT ROUND(geo_lat, 1) AS lat, ROUND(geo_long, 1) AS lng, count(*) AS count FROM resource WHERE ref > 0
|
||||||
|
AND archive IN (" . ps_param_insert(count($defaultarchive)) . ") AND geo_lat IS NOT NULL GROUP BY lat, lng", ps_param_fill($defaultarchive, "i"));
|
||||||
|
|
||||||
|
if (count($allgeopoints) > 0) {
|
||||||
|
$heatdata = array(
|
||||||
|
"max" => max(array_column($allgeopoints, "count")),
|
||||||
|
"data" => $allgeopoints
|
||||||
|
);
|
||||||
|
|
||||||
|
$heatmap_cache = get_temp_dir() . "/heatmap_" . md5("heatmap" . $scramble_key);
|
||||||
|
$heatmapjson = "var heatpoints = " . json_encode($heatdata) . ";";
|
||||||
|
file_put_contents($heatmap_cache, $heatmapjson);
|
||||||
|
}
|
||||||
|
}
|
153
batch/cron_jobs/015_action_notifications.php
Normal file
@@ -0,0 +1,153 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
// Send email notification of new actions
|
||||||
|
|
||||||
|
// Record the time at the start so as not to miss actions that may be created during processing
|
||||||
|
$this_run_start = date("Y-m-d H:i:s");
|
||||||
|
|
||||||
|
if ((int)$new_action_email_interval == 0) {
|
||||||
|
if ('cli' == PHP_SAPI) {
|
||||||
|
echo "{$baseurl} - {$this_run_start} - Action notifications - \$new_action_email_interval not set. Skipping" . PHP_EOL;
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
$new_action_email_interval = ceil(min($new_action_email_interval, ACTIONS_EMAIL_MAX_AGE));
|
||||||
|
|
||||||
|
$last_action_notifications = get_sysvar('last_action_notification_emails', '1970-01-01');
|
||||||
|
$action_notifications_elapsed_sec = time() - strtotime($last_action_notifications);
|
||||||
|
|
||||||
|
// Don't run if the elapsed time since last run is shorter than the configured value in hours
|
||||||
|
if ($action_notifications_elapsed_sec < $new_action_email_interval * 60 * 60) {
|
||||||
|
logScript(" - Skipping action email notifications - last run: " . $last_action_notifications);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
$action_notify_users = get_users_by_preference("user_pref_new_action_emails", "1");
|
||||||
|
|
||||||
|
// If cron hasn't been run for a long time only go back a maximum of 7 days
|
||||||
|
$action_notifications_check_minutes = floor(min($action_notifications_elapsed_sec, 7 * 24 * 60 * 60) / 60);
|
||||||
|
|
||||||
|
logScript(" - Finding actions created in the last $action_notifications_check_minutes minutes");
|
||||||
|
$recentactions = get_user_actions_recent(ceil($action_notifications_check_minutes) + 1, true);
|
||||||
|
foreach ($recentactions as $notifyuser => $user_actions) {
|
||||||
|
if (!in_array($notifyuser, $action_notify_users)) {
|
||||||
|
// User not set to receive action emails
|
||||||
|
logScript(" - Skipping action notification email for user ref " . $notifyuser . " as not configured");
|
||||||
|
}
|
||||||
|
$actionuser = get_user($notifyuser);
|
||||||
|
$usermail = $actionuser["email"];
|
||||||
|
|
||||||
|
// Set timezone if required
|
||||||
|
$default_user_local_timezone = $user_local_timezone;
|
||||||
|
get_config_option(['user' => $notifyuser, 'usergroup' => $actionuser['usergroup']], 'user_local_timezone', $user_local_timezone, $default_user_local_timezone);
|
||||||
|
|
||||||
|
if (!filter_var($usermail, FILTER_VALIDATE_EMAIL)) {
|
||||||
|
logScript(" - Skipping action notification email for user ref " . $notifyuser . " due to invalid email: " . $usermail);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Construct email notification
|
||||||
|
logScript(" - Checking action email notification for user " . $usermail);
|
||||||
|
|
||||||
|
$usernotification = new ResourceSpaceUserNotification();
|
||||||
|
$usernotification->set_subject($applicationname . ": ");
|
||||||
|
$usernotification->append_subject('lang_actions_email_new_actions_title');
|
||||||
|
|
||||||
|
$usernotification->set_text('<div id="CentralSpaceContainer"><div id="CentralSpace"><div class="BasicsBox">');
|
||||||
|
$usernotification->append_text('lang_actions_email_new_actions_intro');
|
||||||
|
$usernotification->append_text('<br /><br />');
|
||||||
|
$usernotification->append_text('<div class="Listview"><table class="ListviewStyle" style="min-width: 70%">');
|
||||||
|
$usernotification->append_text('<tr class="ListviewTitleStyle"><td>');
|
||||||
|
$usernotification->append_text('lang_date');
|
||||||
|
$usernotification->append_text('</td><td>');
|
||||||
|
$usernotification->append_text('lang_property-reference');
|
||||||
|
$usernotification->append_text('</td><td>');
|
||||||
|
$usernotification->append_text('lang_user');
|
||||||
|
$usernotification->append_text('</td><td>');
|
||||||
|
$usernotification->append_text('lang_description');
|
||||||
|
$usernotification->append_text('</td><td>');
|
||||||
|
$usernotification->append_text('lang_type');
|
||||||
|
$usernotification->append_text('</td><td>');
|
||||||
|
$usernotification->append_text('lang_tools');
|
||||||
|
$usernotification->append_text('</td></tr>');
|
||||||
|
foreach ($user_actions as $actiontype => $type_actions) {
|
||||||
|
foreach ($type_actions as $user_action) {
|
||||||
|
$actionlinks = hook("actioneditlink", '', array($user_action));
|
||||||
|
if ($actionlinks) {
|
||||||
|
$actioneditlink = $actionlinks["editlink"];
|
||||||
|
$actionviewlink = $actionlinks["viewlink"];
|
||||||
|
} else {
|
||||||
|
$actioneditlink = '';
|
||||||
|
$actionviewlink = '';
|
||||||
|
}
|
||||||
|
|
||||||
|
switch ($user_action["type"]) {
|
||||||
|
case "resourcereview":
|
||||||
|
$actioneditlink = $baseurl . "/pages/edit.php";
|
||||||
|
$actionviewlink = $baseurl . "/pages/view.php";
|
||||||
|
break;
|
||||||
|
case "resourcerequest":
|
||||||
|
$actioneditlink = $baseurl . "/pages/team/team_request_edit.php";
|
||||||
|
break;
|
||||||
|
case "userrequest":
|
||||||
|
$actioneditlink = $baseurl . "/pages/team/team_user_edit.php";
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
$linkparams["ref"] = $user_action["ref"];
|
||||||
|
$editlink = ($actioneditlink == '') ? '' : generateURL($actioneditlink, $linkparams);
|
||||||
|
$viewlink = ($actionviewlink == '') ? '' : generateURL($actionviewlink, $linkparams);
|
||||||
|
|
||||||
|
$usernotification->append_text('<tr><td>' . nicedate($user_action["date"], true, true, true) . '</td>');
|
||||||
|
$usernotification->append_text('<td><a href="' . $editlink . '" >' . $user_action["ref"] . '</a></td>');
|
||||||
|
|
||||||
|
$actionfromuser = get_user($user_action["user"]);
|
||||||
|
if ($actionfromuser === false) {
|
||||||
|
// User may have been deleted
|
||||||
|
$actionusername = $user_action["user"];
|
||||||
|
} else {
|
||||||
|
$actionusername = isset($actionfromuser["fullname"]) ? $actionfromuser["fullname"] : $actionfromuser["username"];
|
||||||
|
}
|
||||||
|
$usernotification->append_text('<td>' . escape($actionusername) . '</td>');
|
||||||
|
$usernotification->append_text('<td>' . escape(tidy_trim((string) $user_action["description"], 200)) . '</td>');
|
||||||
|
$usernotification->append_text('<td>');
|
||||||
|
$langtype = 'actions_type_' . $user_action['type'];
|
||||||
|
$usernotification->append_text('lang_' . $langtype);
|
||||||
|
$usernotification->append_text('</td>');
|
||||||
|
$usernotification->append_text('<td><div class="ListTools">');
|
||||||
|
|
||||||
|
if ($editlink != "") {
|
||||||
|
$usernotification->append_text('<a href="' . $editlink . '">');
|
||||||
|
$usernotification->append_text('lang_action-edit');
|
||||||
|
$usernotification->append_text('</a> ');
|
||||||
|
}
|
||||||
|
if ($viewlink != "") {
|
||||||
|
$usernotification->append_text('<a href="' . $viewlink . '">');
|
||||||
|
$usernotification->append_text('lang_view');
|
||||||
|
$usernotification->append_text('</a>');
|
||||||
|
}
|
||||||
|
$usernotification->append_text('</div></td></tr>');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$usernotification->append_text('</table></div><!-- End of Listview -->');
|
||||||
|
$userprefurl = $baseurl . "/pages/user/user_preferences.php#UserPreferenceEmailSection";
|
||||||
|
$usernotification->append_text('<br /><br />');
|
||||||
|
$usernotification->append_text('lang_actions_introtext');
|
||||||
|
$usernotification->append_text('<br /><a href="' . $userprefurl . '">' . $userprefurl . '</a>');
|
||||||
|
$usernotification->append_text('</div><!-- End of Listview -->');
|
||||||
|
$usernotification->append_text('</div><!-- End of BasicsBox -->');
|
||||||
|
$usernotification->append_text('</div><!-- End of CentralSpace -->');
|
||||||
|
$usernotification->append_text('</div><!-- End of CentralSpaceContainer -->');
|
||||||
|
if (count($user_actions) > 0) {
|
||||||
|
// Send the email
|
||||||
|
logScript(" - Sending summary to user ref " . $notifyuser . ", email " . $usermail);
|
||||||
|
send_user_notification([$notifyuser], $usernotification, true);
|
||||||
|
}
|
||||||
|
// End of each user's actions
|
||||||
|
}
|
||||||
|
|
||||||
|
# Update last run date/time.
|
||||||
|
set_sysvar("last_action_notification_emails", $this_run_start);
|
58
batch/cron_jobs/999_file_integrity_check.php
Normal file
@@ -0,0 +1,58 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
include_once __DIR__ . "/../../include/boot.php";
|
||||||
|
|
||||||
|
if (!$file_integrity_checks) {
|
||||||
|
echo "Skipping file integrity checks.\n";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
function check_valid_cron_time()
|
||||||
|
{
|
||||||
|
// Check if in a valid time period
|
||||||
|
$validtime = true;
|
||||||
|
$curhour = date('H');
|
||||||
|
if ($GLOBALS["file_integrity_verify_window"][0] <= $GLOBALS["file_integrity_verify_window"][1]) {
|
||||||
|
// Second time is later than first or times are the same (off). Ensure time is not before the first or later than the second
|
||||||
|
if ($curhour < $GLOBALS["file_integrity_verify_window"][0] || $curhour >= $GLOBALS["file_integrity_verify_window"][1]) {
|
||||||
|
$validtime = false;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
// First time is later than second (running through midnight). Ensure time is not before the first and after the second
|
||||||
|
if ($curhour < $GLOBALS["file_integrity_verify_window"][0] && $curhour >= $GLOBALS["file_integrity_verify_window"][1]) {
|
||||||
|
$validtime = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return $validtime;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (is_process_lock("file_integrity_check")) {
|
||||||
|
echo " - File integrity process lock is in place.Skipping.\n";
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!check_valid_cron_time()) {
|
||||||
|
if ('cli' == PHP_SAPI) {
|
||||||
|
echo " - Outside of valid time period. Set times are between " . $file_integrity_verify_window[0] . ":00 and " . $file_integrity_verify_window[1] . ":00 hours. Current hour: " . date('H') . ":00" . $LINE_END;
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
set_process_lock("file_integrity_check");
|
||||||
|
|
||||||
|
$resources = get_resources_to_validate(1);
|
||||||
|
|
||||||
|
$allfailures = [];
|
||||||
|
foreach (array_chunk($resources, 1000) as $resources_chunk) {
|
||||||
|
$failures = check_resources($resources_chunk, true);
|
||||||
|
$allfailures = array_merge($allfailures, $failures);
|
||||||
|
if (check_valid_cron_time() === false) {
|
||||||
|
// Reached end of window, quit
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (count($allfailures) > 0) {
|
||||||
|
send_integrity_failure_notices($allfailures);
|
||||||
|
}
|
||||||
|
|
||||||
|
clear_process_lock("file_integrity_check");
|
119
batch/expiry_notification.php
Normal file
@@ -0,0 +1,119 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
include __DIR__ . "/../include/boot.php";
|
||||||
|
command_line_only();
|
||||||
|
include_once __DIR__ . "/../include/image_processing.php";
|
||||||
|
|
||||||
|
$expired_resources = ps_query(
|
||||||
|
'SELECT r.ref, r.field8 AS title
|
||||||
|
FROM resource r
|
||||||
|
JOIN resource_node AS rn ON r.ref = rn.resource
|
||||||
|
JOIN node n ON n.ref=rn.node
|
||||||
|
JOIN resource_type_field AS rtf ON n.resource_type_field = rtf.ref AND rtf.type = ?
|
||||||
|
WHERE r.expiry_notification_sent<>1 AND n.name <> "" AND n.name <= NOW()',
|
||||||
|
array("i", FIELD_TYPE_EXPIRY_DATE)
|
||||||
|
);
|
||||||
|
|
||||||
|
if (count($expired_resources) > 0) {
|
||||||
|
# Send notifications
|
||||||
|
$refs = array();
|
||||||
|
$body = $lang["resourceexpirymail"] . "\n";
|
||||||
|
foreach ($expired_resources as $resource) {
|
||||||
|
$refs[] = $resource["ref"];
|
||||||
|
echo "<br>Sending expiry notification for: " . $resource["ref"] . " - " . $resource["title"];
|
||||||
|
|
||||||
|
$body .= "\n" . $resource["ref"] . " - " . $resource["title"];
|
||||||
|
$body .= "\n" . $baseurl . "/?r=" . $resource["ref"] . "\n";
|
||||||
|
}
|
||||||
|
|
||||||
|
$url = build_specialsearch_list_urls($refs);
|
||||||
|
|
||||||
|
$admin_notify_emails = array();
|
||||||
|
$admin_notify_users = array();
|
||||||
|
if (isset($expiry_notification_mail)) {
|
||||||
|
$admin_notify_emails[] = $expiry_notification_mail;
|
||||||
|
} else {
|
||||||
|
$notify_users = get_notification_users("RESOURCE_ADMIN");
|
||||||
|
foreach ($notify_users as $notify_user) {
|
||||||
|
get_config_option(['user' => $notify_user['ref'], 'usergroup' => $notify_user['usergroup']], 'user_pref_resource_notifications', $send_message);
|
||||||
|
if (!$send_message) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
get_config_option(['user' => $notify_user['ref'], 'usergroup' => $notify_user['usergroup']], 'email_user_notifications', $send_email);
|
||||||
|
if ($send_email && $notify_user["email"] != "") {
|
||||||
|
echo "Sending email to " . $notify_user["email"] . "\r\n";
|
||||||
|
$admin_notify_emails[] = $notify_user['email'];
|
||||||
|
} else {
|
||||||
|
$admin_notify_users[] = $notify_user["ref"];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
foreach ($admin_notify_emails as $admin_notify_email) {
|
||||||
|
# Send mail
|
||||||
|
send_mail($admin_notify_email, $lang["resourceexpiry"], $body);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (count($admin_notify_users) > 0) {
|
||||||
|
echo "Sending notification to user refs: " . implode(",", $admin_notify_users) . "\r\n";
|
||||||
|
message_add($admin_notify_users, $lang["resourceexpirymail"] . $url['multiple'], $url['single'], 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
# Update notification flag so an expiry is not sent again until the expiry field(s) is edited.
|
||||||
|
$chunks = db_chunk_id_list($refs);
|
||||||
|
foreach ($chunks as $chunk) {
|
||||||
|
ps_query("UPDATE resource SET expiry_notification_sent = 1 WHERE ref IN (" . ps_param_insert(count($chunk)) . ")", ps_param_fill($chunk, "i"));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Send a notification X days prior to expiry to all users who have ever downloaded the resources
|
||||||
|
if (isset($notify_on_resource_expiry_days)) {
|
||||||
|
echo "<br>Sending a notification {$notify_on_resource_expiry_days} day(s) prior to expiry to all users who have ever downloaded these resources.\n";
|
||||||
|
$data = ps_query(
|
||||||
|
'SELECT rl.`user`,
|
||||||
|
rte.ref AS `resource`,
|
||||||
|
u.email,
|
||||||
|
u.usergroup
|
||||||
|
FROM resource_log AS rl
|
||||||
|
JOIN (
|
||||||
|
SELECT r.ref
|
||||||
|
FROM resource AS r
|
||||||
|
LEFT JOIN resource_node AS rn ON r.ref = rn.resource
|
||||||
|
LEFT JOIN node n ON n.ref=rn.node
|
||||||
|
LEFT JOIN resource_type_field AS rtf ON n.resource_type_field = rtf.ref
|
||||||
|
WHERE rtf.type = ?
|
||||||
|
AND n.`name` <> ""
|
||||||
|
AND DATE(n.`name`) = DATE(DATE_ADD(NOW(), INTERVAL ? DAY))
|
||||||
|
) AS rte ON rte.ref = rl.resource
|
||||||
|
JOIN user AS u ON u.ref = rl.user
|
||||||
|
WHERE rl.`type` = ?
|
||||||
|
GROUP BY resource, rl.user
|
||||||
|
ORDER BY rte.ref ASC',
|
||||||
|
array("i", FIELD_TYPE_EXPIRY_DATE, "i", (int)$notify_on_resource_expiry_days, "s", LOG_CODE_DOWNLOADED)
|
||||||
|
);
|
||||||
|
|
||||||
|
$msg = str_replace('%X', $notify_on_resource_expiry_days, $lang['resource_expiry_x_days']);
|
||||||
|
|
||||||
|
$matched_resources = array_unique(array_column($data, 'resource'));
|
||||||
|
foreach ($matched_resources as $resource_ref) {
|
||||||
|
$url = "{$baseurl}/?r={$resource_ref}";
|
||||||
|
$email_body = "{$msg}<br><br><a href=\"{$url}\">{$url}</a>";
|
||||||
|
$admin_notify_users = [];
|
||||||
|
|
||||||
|
$users_who_dld = array_filter($data, function ($v) use ($resource_ref) {
|
||||||
|
return $v['resource'] === $resource_ref;
|
||||||
|
});
|
||||||
|
foreach ($users_who_dld as $dld_record) {
|
||||||
|
get_config_option(['user' => $dld_record['user'], 'usergroup' => $dld_record['usergroup']], 'email_user_notifications', $send_email);
|
||||||
|
if ($send_email && $dld_record['email'] !== '') {
|
||||||
|
send_mail($dld_record['email'], "{$applicationname}: {$lang['resourceexpiry']}", $email_body);
|
||||||
|
} else {
|
||||||
|
$admin_notify_users[] = $dld_record['user'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
message_add($admin_notify_users, $msg, $url);
|
||||||
|
}
|
||||||
|
}
|
136
batch/recreate_previews.php
Normal file
@@ -0,0 +1,136 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
# This is based on pages/tools/update_previews.php but for use on the server backend to avoid browser timeouts etc.
|
||||||
|
# previewbased is an option that can help preserve alternative previews,
|
||||||
|
# Recreating previews would normally use the original file and overwrite alternative previews that have been uploaded,
|
||||||
|
# but with previewbased=true, it will try to find a suitable large preview image to generate the smaller versions from.
|
||||||
|
# If you want to recreate preview for a single resource, you can pass ref=[ref]&only=true
|
||||||
|
# also includes optional -videoupdate to cater for systems moving from old flv videos to HTML5 compatible video
|
||||||
|
|
||||||
|
include_once __DIR__ . "/../include/boot.php";
|
||||||
|
|
||||||
|
include_once __DIR__ . "/../include/image_processing.php";
|
||||||
|
|
||||||
|
$sapi_type = php_sapi_name();
|
||||||
|
if (substr($sapi_type, 0, 3) != 'cli') {
|
||||||
|
exit("Command line execution only.");
|
||||||
|
}
|
||||||
|
if (isset($argv[1]) && strtolower($argv[1]) == "collection" && isset($argv[2]) && is_numeric($argv[2])) {
|
||||||
|
$collectionid = $argv[2];
|
||||||
|
} elseif (isset($argv[1]) && strtolower($argv[1]) == "resource" && isset($argv[2]) && is_numeric($argv[2])) {
|
||||||
|
$ref = $argv[2];
|
||||||
|
if (isset($argv[3]) && is_numeric($argv[3])) {
|
||||||
|
$max = $argv[3];
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
echo "recreate_previews.php - update previews for all/selected resources\n\n";
|
||||||
|
echo "- extra options to use existing uploaded previews or to force recreation of video previews e.g. when changing to mp4 previews\n";
|
||||||
|
echo "USAGE:\n";
|
||||||
|
echo "php recreate_previews.php [collection|resource] [id] [maxref] [sizes] [comma separated size ids] [types] [comma separated type ids] [-previewbased] [-videoupdate]\n\n";
|
||||||
|
echo "examples\n";
|
||||||
|
echo "php recreate_previews.php collection 247\n";
|
||||||
|
echo "- this will update previews for all resources in collection #247\n\n";
|
||||||
|
echo "php recreate_previews.php collection 380 -previewbased\n";
|
||||||
|
echo "- this will update previews for all resources in collection #380, utilising any existing uploaded previews\n\n";
|
||||||
|
echo "php recreate_previews.php resource 19564\n";
|
||||||
|
echo "- this will update previews for all resources starting with resource ID #19564\n\n";
|
||||||
|
echo "php recreate_previews.php resource 19564 19800\n";
|
||||||
|
echo "- this will update previews for resources starting with resource ID #19564 and ending with resource 19800\n\n";
|
||||||
|
echo "php recreate_previews.php resource 1 -videoupdate\n";
|
||||||
|
echo "- this will update previews for all video resources that do not have the required '\$ffmpeg_preview_extension' extension\n\n";
|
||||||
|
echo "php recreate_previews.php collection 247 sizes scr,col\n";
|
||||||
|
echo "- this will update only the col and scr preview sizes for all resources in collection #247\n\n";
|
||||||
|
echo "php recreate_previews.php resource 110 types 1,2\n";
|
||||||
|
echo "- this will start at resource 110 and recreate previews for resource types 1 and 2\n\n";
|
||||||
|
echo "php recreate_previews.php collection 247 -delete\n";
|
||||||
|
echo "- this will remove all existing previews before recreating all preview sizes for all resources in collection #247\n";
|
||||||
|
echo "- the -delete option cannot be used with options -videoupdate, -previewbased, sizes, or types\n\n";
|
||||||
|
exit();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (in_array("sizes", $argv)) {
|
||||||
|
$sizes = explode(",", $argv[array_search("sizes", $argv) + 1]);
|
||||||
|
} else {
|
||||||
|
$sizes = array();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (in_array("types", $argv)) {
|
||||||
|
$resource_types = explode(",", $argv[array_search("types", $argv) + 1]);
|
||||||
|
} else {
|
||||||
|
$resource_types = array();
|
||||||
|
}
|
||||||
|
|
||||||
|
$previewbased = in_array("-previewbased", $argv);
|
||||||
|
$videoupdate = in_array("-videoupdate", $argv);
|
||||||
|
$delete_existing = in_array("-delete", $argv) && !$previewbased && !$videoupdate && count($sizes) == 0;
|
||||||
|
|
||||||
|
function update_preview($ref, $previewbased, $sizes, $delete_existing)
|
||||||
|
{
|
||||||
|
$resourceinfo = ps_query("select file_path, file_extension from resource where ref = ?", array("i", (int)$ref));
|
||||||
|
if (count($resourceinfo) > 0 && !hook("replaceupdatepreview", '', array($ref, $resourceinfo[0]))) {
|
||||||
|
if (!empty($resourceinfo[0]['file_path'])) {
|
||||||
|
$ingested = false;
|
||||||
|
} else {
|
||||||
|
$ingested = true;
|
||||||
|
}
|
||||||
|
if ($delete_existing) {
|
||||||
|
delete_previews($ref);
|
||||||
|
}
|
||||||
|
create_previews($ref, false, ($previewbased ? "jpg" : $resourceinfo[0]["file_extension"]), false, $previewbased, -1, true, $ingested, true, $sizes);
|
||||||
|
hook("afterupdatepreview", "", array($ref));
|
||||||
|
update_disk_usage($ref);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!isset($collectionid)) {
|
||||||
|
$conditions = array();
|
||||||
|
$conditions_params = array("i", (int)$ref);
|
||||||
|
if (isset($max)) {
|
||||||
|
$conditions[] = "ref <= ?";
|
||||||
|
$conditions_params = array_merge($conditions_params, array("i", $max));
|
||||||
|
}
|
||||||
|
if ($videoupdate) {
|
||||||
|
$conditions[] = "file_extension in (" . ps_param_insert(count($ffmpeg_supported_extensions)) . ")";
|
||||||
|
$conditions_params = array_merge($conditions_params, ps_param_fill($ffmpeg_supported_extensions, "s"));
|
||||||
|
}
|
||||||
|
if (isset($resource_deletion_state)) {
|
||||||
|
$conditions[] = "archive <> ?";
|
||||||
|
$conditions_params = array_merge($conditions_params, array("i", $resource_deletion_state));
|
||||||
|
}
|
||||||
|
if (!empty($resource_types)) {
|
||||||
|
$conditions[] = "resource_type in (" . ps_param_insert(count($resource_types)) . ")";
|
||||||
|
$conditions_params = array_merge($conditions_params, ps_param_fill($resource_types, "i"));
|
||||||
|
}
|
||||||
|
$resources = ps_array("SELECT ref value FROM resource WHERE ref >= ?" . ((count($conditions) > 0) ? " AND " . implode(" AND ", $conditions) : "") . " ORDER BY ref asc", $conditions_params, 0);
|
||||||
|
} else {
|
||||||
|
$resources = get_collection_resources($collectionid);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (is_array($resources) && count($resources) > 0) {
|
||||||
|
hook('beforescriptaction');
|
||||||
|
foreach ($resources as $resource) {
|
||||||
|
if ($videoupdate) {
|
||||||
|
$checkflvpreview = get_resource_path($resource, true, 'pre', false, 'flv', true, 1, false, '');
|
||||||
|
$correctvideo_preview = get_resource_path($resource, true, 'pre', false, $ffmpeg_preview_extension, true, 1, false);
|
||||||
|
echo "Checking for video preview of resource #" . $resource . ".....";
|
||||||
|
if (file_exists($correctvideo_preview)) {
|
||||||
|
echo "...already exists, skipping\n";
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
echo "Recreating previews for resource #" . $resource . "...";
|
||||||
|
ob_flush();
|
||||||
|
if (update_preview($resource, $previewbased, $sizes, $delete_existing)) {
|
||||||
|
echo "....completed\n";
|
||||||
|
} else {
|
||||||
|
echo "FAILED - skipping\n";
|
||||||
|
}
|
||||||
|
ob_flush();
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
echo "No resources found\n";
|
||||||
|
}
|
||||||
|
echo "\nFinished\n";
|
44
composer.json
Normal file
@@ -0,0 +1,44 @@
|
|||||||
|
{
|
||||||
|
"name": "montala/resourcespace",
|
||||||
|
"description": "ResourceSpace is the Digital Asset Management software offering a convenient, productive and easy to use solution for organising and sharing files.",
|
||||||
|
"homepage": "https://www.resourcespace.com",
|
||||||
|
"type": "project",
|
||||||
|
"license": "documentation/licenses/resourcespace.txt",
|
||||||
|
"require": {
|
||||||
|
"php": "8.1 - 8.3",
|
||||||
|
"ext-mbstring": "*",
|
||||||
|
"ext-intl": "*",
|
||||||
|
"ext-curl": "*",
|
||||||
|
"ext-dom": "*",
|
||||||
|
"ext-zip": "*",
|
||||||
|
"ext-gd": "*",
|
||||||
|
"ext-mysqli": "*",
|
||||||
|
"ext-json": "*"
|
||||||
|
},
|
||||||
|
"require-dev": {
|
||||||
|
"phpstan/phpstan": "^1.8",
|
||||||
|
"rector/rector": "^1.0",
|
||||||
|
"roave/security-advisories": "dev-latest"
|
||||||
|
},
|
||||||
|
"autoload-dev": {
|
||||||
|
"psr-4": {
|
||||||
|
"Montala\\ResourceSpace\\Utils\\Rector\\": "include"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"suggest": {
|
||||||
|
"ext-apcu": "Needed to improve upload performance."
|
||||||
|
},
|
||||||
|
"scripts": {
|
||||||
|
"dev:beforeCommit": [
|
||||||
|
"@dev:phpstan"
|
||||||
|
],
|
||||||
|
"dev:phpstan": "phpstan analyse"
|
||||||
|
},
|
||||||
|
"support": {
|
||||||
|
"source": "https://svn.resourcespace.com/svn/rs/trunk/",
|
||||||
|
"docs": "https://www.resourcespace.com/knowledge-base/",
|
||||||
|
"forum": "https://groups.google.com/g/resourcespace",
|
||||||
|
"issues": "https://www.resourcespace.com/bug_report",
|
||||||
|
"security": "https://www.resourcespace.com/bug_report"
|
||||||
|
}
|
||||||
|
}
|
1023
composer.lock
generated
Normal file
BIN
css/blank.gif
Executable file
After Width: | Height: | Size: 49 B |
711
css/css_override.php
Normal file
@@ -0,0 +1,711 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Add in CSS overrides for UI elements
|
||||||
|
*
|
||||||
|
* @package ResourceSpace
|
||||||
|
*/
|
||||||
|
|
||||||
|
include_once "../include/boot.php";
|
||||||
|
|
||||||
|
$k = getval('k', '');
|
||||||
|
if ((is_array($k) || trim($k) === '') && getval('noauth', '') != true) {
|
||||||
|
include '../include/authenticate.php';
|
||||||
|
}
|
||||||
|
|
||||||
|
header("Content-type: text/css");
|
||||||
|
|
||||||
|
global $header_colour_style_override, $header_link_style_override, $home_colour_style_override,
|
||||||
|
$collection_bar_background_override, $collection_bar_foreground_override, $button_colour_override;
|
||||||
|
|
||||||
|
// Dark mode styling
|
||||||
|
if (isset($user_pref_appearance) && !(isset($high_contrast_mode) && $high_contrast_mode)) {
|
||||||
|
if ($user_pref_appearance == "device") {
|
||||||
|
?>
|
||||||
|
@media (prefers-color-scheme: dark) {
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
if ($user_pref_appearance == "dark" || $user_pref_appearance == "device") {
|
||||||
|
?>
|
||||||
|
/* Core elements */
|
||||||
|
body, html {
|
||||||
|
color: white;
|
||||||
|
background: #262626;
|
||||||
|
}
|
||||||
|
h1, h2 {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
/* Tables */
|
||||||
|
.Listview {
|
||||||
|
background-color: #545454;
|
||||||
|
}
|
||||||
|
.ListviewStyle tr {
|
||||||
|
background-color: #545454;
|
||||||
|
}
|
||||||
|
.ListviewStyle thead, .ListviewTitleStyle, .ListviewStyle tr.ListviewTitleStyle {
|
||||||
|
background-color: #444;
|
||||||
|
}
|
||||||
|
.ListviewStyle tr:nth-child(even):not(.ListviewTitleStyle) {
|
||||||
|
background-color: #5e5e5e;
|
||||||
|
}
|
||||||
|
.ListviewStyle tr:hover {
|
||||||
|
background-color: #424242 !important;
|
||||||
|
}
|
||||||
|
.tableRowEven {
|
||||||
|
background-color: #545454 !important;
|
||||||
|
}
|
||||||
|
.tableRowOdd {
|
||||||
|
background-color: #5e5e5e !important;
|
||||||
|
}
|
||||||
|
a:visited {
|
||||||
|
color: #e9e9e9;
|
||||||
|
}
|
||||||
|
a:link {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
/* Header */
|
||||||
|
#Header {
|
||||||
|
background: #404040;
|
||||||
|
}
|
||||||
|
#Header li a {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.BasicsBox.SearchSticky {
|
||||||
|
background-color: #262626;
|
||||||
|
border-bottom: 1px solid #ffffff00;
|
||||||
|
box-shadow: 0 12px 10px -12px #000000;
|
||||||
|
}
|
||||||
|
.TopInpageNav select {
|
||||||
|
background-color: #545454;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.icondisplay {
|
||||||
|
background-color: #545454;
|
||||||
|
}
|
||||||
|
.update_result_order_button {
|
||||||
|
background-color: #545454;
|
||||||
|
}
|
||||||
|
.ResourcePanel {
|
||||||
|
background-color: #545454;
|
||||||
|
}
|
||||||
|
.ResourcePanel .nopreview {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.thumbs-file-extension,
|
||||||
|
.ResourceTypeIcon.fa-fw {
|
||||||
|
background: #383838;
|
||||||
|
}
|
||||||
|
#modal {
|
||||||
|
background-color: #262626;
|
||||||
|
}
|
||||||
|
.RecordPanel, .ResourcePanelSmall, .ResourcePanelLarge, div#Metadata div.Title {
|
||||||
|
background-color: #393939;
|
||||||
|
}
|
||||||
|
#modal .RecordHeader h1, #modal .BasicsBox h1 {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.TabBar {
|
||||||
|
background-color: #393939;
|
||||||
|
}
|
||||||
|
.Tab a {
|
||||||
|
font-weight: 600;
|
||||||
|
background-color: #484848;
|
||||||
|
}
|
||||||
|
.TabSelected a {
|
||||||
|
background: #545454;
|
||||||
|
border-bottom: 1px solid #545454;
|
||||||
|
}
|
||||||
|
.RecordDownloadSpace {
|
||||||
|
background: #545454;
|
||||||
|
}
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend, .toolbox {
|
||||||
|
background: #545454;
|
||||||
|
}
|
||||||
|
.RecordTools {
|
||||||
|
background: #545454;
|
||||||
|
}
|
||||||
|
.RecordPanel .RecordDownload .DownloadDBlend td {
|
||||||
|
color: white;
|
||||||
|
border-top: 1px solid #7c7c7c;
|
||||||
|
}
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend p {
|
||||||
|
color: #cbcbcb;
|
||||||
|
}
|
||||||
|
.RecordPanel .item h3, .RecordPanel .itemNarrow h3, th {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
#Metadata {
|
||||||
|
background-color: #545454;
|
||||||
|
}
|
||||||
|
.StyledTabbedPanel {
|
||||||
|
background: #545454;
|
||||||
|
}
|
||||||
|
.comment_form_container {
|
||||||
|
background: #545454;
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
.NavUnderline, .Question {
|
||||||
|
border-bottom: 1px solid #3f3f3f;
|
||||||
|
}
|
||||||
|
.HorizontalWhiteNav a:link, .HorizontalWhiteNav a:visited, .HorizontalWhiteNav a:active, .BasicsBox .VerticalNav a:link, .BasicsBox .VerticalNav a:visited, .BasicsBox .VerticalNav a:active, .ListTitle a:link, .ListTitle a:visited, .ListTitle a:active {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.BreadcrumbsBox a, .BreadcrumbsBox a:link, .BreadcrumbsBox a:visited {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.SearchBreadcrumbs > span {
|
||||||
|
color: #c5c5c5;
|
||||||
|
}
|
||||||
|
.HeaderLink a.current {
|
||||||
|
background: #c3c3c31a;
|
||||||
|
}
|
||||||
|
.PluginDisplay {
|
||||||
|
background-color: #545454;
|
||||||
|
}
|
||||||
|
select, .sp-replacer {
|
||||||
|
background-color: #545454;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.MultiRTypeSelect {
|
||||||
|
background-color: #545454;
|
||||||
|
}
|
||||||
|
input[type="text"], input[type="password"], input[type="number"], input[type="email"], textarea, select, .sp-replacer {
|
||||||
|
background-color: #545454;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.search-icon, .search-icon:hover, .search-icon:active {
|
||||||
|
background-color: #404040;
|
||||||
|
}
|
||||||
|
#ssearchbox::placeholder,
|
||||||
|
input[type="text"]::placeholder,
|
||||||
|
input[type="password"]::placeholder,
|
||||||
|
input[type="number"]::placeholder,
|
||||||
|
input[type="email"]::placeholder {
|
||||||
|
color: #b1b1b1;
|
||||||
|
}
|
||||||
|
/* Category trees */
|
||||||
|
.CategoryBox, .MiniCategoryBox {
|
||||||
|
background-color: #545454;
|
||||||
|
}
|
||||||
|
.CategoryBox span, .MiniCategoryBox span {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
/* Comments */
|
||||||
|
.CommentFormBody {
|
||||||
|
background-color: #626262;
|
||||||
|
}
|
||||||
|
.CommentFormBody::placeholder {
|
||||||
|
color: #b1b1b1;
|
||||||
|
}
|
||||||
|
.CommentEntry {
|
||||||
|
background-color: #545454;
|
||||||
|
border: 1px solid #6e6e6e;
|
||||||
|
}
|
||||||
|
.CommentBody {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.skip-to-main-content {
|
||||||
|
background-color: #545454;
|
||||||
|
}
|
||||||
|
.RecordPanel .item h3, .RecordPanel .itemNarrow h3, th {
|
||||||
|
font-weight: 600;
|
||||||
|
}
|
||||||
|
.Question.QuestionStickyRight,
|
||||||
|
.QuestionSubmit.QuestionSticky {
|
||||||
|
background-color: #262626;
|
||||||
|
}
|
||||||
|
.Question.QuestionStickyRight {
|
||||||
|
border-left: unset;
|
||||||
|
box-shadow: -12px 0px 15px -12px black;
|
||||||
|
}
|
||||||
|
.QuestionSubmit.QuestionSticky {
|
||||||
|
border-top: unset;
|
||||||
|
box-shadow: 0 -12px 15px -12px black;
|
||||||
|
}
|
||||||
|
.FormHelpInner {
|
||||||
|
background-color: #6c6c6c;
|
||||||
|
}
|
||||||
|
select, .sp-replacer {
|
||||||
|
box-shadow: 0 1px 3px 1px #00000026;
|
||||||
|
}
|
||||||
|
.RecordPanel .RecordDownload .DownloadDBlend td.Picker select {
|
||||||
|
background-color: #727272;
|
||||||
|
}
|
||||||
|
|
||||||
|
.smalllisticon{background: url(../gfx/interface/listicondark.svg) no-repeat 0; opacity: 0.65;}
|
||||||
|
.smalllisticonactive {background: url(../gfx/interface/listiconactivedark.svg) no-repeat 0;}
|
||||||
|
.xlthumbsicon{background: url(../gfx/interface/xlicondark.svg) no-repeat 0; opacity: 0.65;}
|
||||||
|
.xlthumbsiconactive {background: url(../gfx/interface/xliconactivedark.svg) no-repeat 0;}
|
||||||
|
.largethumbsicon{background: url(../gfx/interface/largeicondark.svg) no-repeat 0; opacity: 0.65;}
|
||||||
|
.largethumbsiconactive{background: url(../gfx/interface/largeiconactivedark.svg) no-repeat 0;}
|
||||||
|
.stripicon{background: url(../gfx/interface/stripicondark.svg) no-repeat 0; opacity: 0.65;}
|
||||||
|
.stripiconactive{background: url(../gfx/interface/stripiconactivedark.svg) no-repeat 0;}
|
||||||
|
|
||||||
|
.icondisplay .fa-map {
|
||||||
|
color: #cccccc;
|
||||||
|
}
|
||||||
|
.icondisplay .fas.fa-map {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.NoFind {
|
||||||
|
background: #404040;
|
||||||
|
}
|
||||||
|
[data-uppy-theme=dark] .uppy-Dashboard-browse {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
[data-uppy-theme=dark] .uppy-DashboardContent-back {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
[data-uppy-theme=dark] .uppy-DashboardContent-addMore {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
[data-uppy-theme=dark] .uppy-StatusBar.is-waiting .uppy-StatusBar-actionBtn--upload:hover,
|
||||||
|
[data-uppy-theme=dark] .uppy-StatusBar.is-waiting .uppy-StatusBar-actionBtn--upload {
|
||||||
|
background-color: #1988d7;
|
||||||
|
}
|
||||||
|
.lockedQuestion {
|
||||||
|
background-color: #404040;
|
||||||
|
}
|
||||||
|
.ResourcePanelInfo {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.PageInformal {
|
||||||
|
background: #404040;
|
||||||
|
}
|
||||||
|
#ProcessingBox{
|
||||||
|
background-color: #404040;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
/* Analytics */
|
||||||
|
.ReportSheet {
|
||||||
|
background-color: #262626;
|
||||||
|
border: none;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.ReportSheet h2,
|
||||||
|
.ReportMetric,
|
||||||
|
.ReportSummary td {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.ReportSummary {
|
||||||
|
background-color: #262626;
|
||||||
|
}
|
||||||
|
/* Reports / Installation check */
|
||||||
|
.InfoTable {
|
||||||
|
background: #404040;
|
||||||
|
}
|
||||||
|
/* Chosen library */
|
||||||
|
.chosen-container, .chosen-container-multi .chosen-choices {
|
||||||
|
background-color: #545454 !important;
|
||||||
|
background-image: none !important;
|
||||||
|
}
|
||||||
|
.chosen-container-active .chosen-choices li.search-field input[type=text] {
|
||||||
|
color: white !important;
|
||||||
|
}
|
||||||
|
/* Selection collection link */
|
||||||
|
.SelectionCollectionLink, .SelectionCollectionLink:link, .SelectionCollectionLink:visited, .MessageBox {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
/* Icon picker */
|
||||||
|
#iconpicker-button {
|
||||||
|
background-color: #404040;
|
||||||
|
}
|
||||||
|
#iconpicker-container {
|
||||||
|
background: #404040;
|
||||||
|
}
|
||||||
|
/* API Test tool */
|
||||||
|
.codeexample {
|
||||||
|
background-color: #404040;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
/* jQuery UI dialog */
|
||||||
|
.ui-widget-content,
|
||||||
|
.delete-dialog .ui-dialog-titlebar,
|
||||||
|
.ui-dialog-titlebar,
|
||||||
|
.ui-dialog .ui-dialog-title {
|
||||||
|
background: #545454;
|
||||||
|
}
|
||||||
|
.ui-dialog .ui-dialog-content, .ui-dialog .ui-dialog-title {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.ui-widget.ui-widget-content {
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
.ui-widget-content {
|
||||||
|
border: 1px solid #878787;
|
||||||
|
}
|
||||||
|
.ui-menu .ui-menu-item {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
/* Responsive mode */
|
||||||
|
@media (max-width: 1200px) {
|
||||||
|
#Header .HorizontalNav ul li a {
|
||||||
|
background: #545454 !important;
|
||||||
|
color: white !important;
|
||||||
|
border: none !important;
|
||||||
|
}
|
||||||
|
#Header .HorizontalNav ul li.UploadButton a {
|
||||||
|
background: #1378BF !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.ResponsiveButton {
|
||||||
|
box-shadow: none !important;
|
||||||
|
}
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($user_pref_appearance == "device") {
|
||||||
|
?>
|
||||||
|
}
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
# Override the header background colour
|
||||||
|
if (isset($header_colour_style_override) && $header_colour_style_override != '') { ?>
|
||||||
|
#Header, #OverFlowLinks, #LoginHeader {
|
||||||
|
background: <?php echo $header_colour_style_override; ?>;
|
||||||
|
} <?php
|
||||||
|
}
|
||||||
|
|
||||||
|
# Override the header link colour
|
||||||
|
if (isset($header_link_style_override) && $header_link_style_override != '') { ?>
|
||||||
|
#HeaderNav1, #HeaderNav1 li a, #HeaderNav2 li a, #HiddenLinks li.HeaderLink a {
|
||||||
|
color: <?php echo $header_link_style_override; ?>;
|
||||||
|
}
|
||||||
|
#HeaderNav2 li {
|
||||||
|
border-color: <?php echo $header_link_style_override; ?>;
|
||||||
|
}
|
||||||
|
#HeaderNav1 li.UploadButton a {
|
||||||
|
color: #FFFFFF;
|
||||||
|
} <?php
|
||||||
|
}
|
||||||
|
|
||||||
|
# Override home UI elements colour (intro text, dash tiles, simple search)
|
||||||
|
if (isset($home_colour_style_override) && $home_colour_style_override != '') { ?>
|
||||||
|
#SearchBox, #HomeSiteText.dashtext, .HomePanelIN, #BrowseBar, #NewsPanel.BasicsBox, #remote_assist #SearchBoxPanel,
|
||||||
|
.SearchBarTab.SearchBarTabSelected {
|
||||||
|
background: <?php echo $home_colour_style_override; ?>;
|
||||||
|
} <?php
|
||||||
|
}
|
||||||
|
|
||||||
|
# Override the collection bar background colour
|
||||||
|
if (isset($collection_bar_background_override) && $collection_bar_background_override != '') { ?>
|
||||||
|
.CollectBack {
|
||||||
|
background: <?php echo $collection_bar_background_override; ?>;
|
||||||
|
} <?php
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Override the collection bar foreground colour
|
||||||
|
*
|
||||||
|
* optgroup and option background-color set to #474747 for consistency across platforms as
|
||||||
|
* Firefox/Windows does not recognise rgb() colour properties for optgroup element
|
||||||
|
* */
|
||||||
|
|
||||||
|
if (isset($collection_bar_foreground_override) && $collection_bar_foreground_override != '') { ?>
|
||||||
|
.CollectionPanelShell, #CollectionDiv select {
|
||||||
|
background-color: <?php echo $collection_bar_foreground_override; ?>;
|
||||||
|
}
|
||||||
|
#CollectionDiv option, #CollectionDiv optgroup {
|
||||||
|
font-style:normal;
|
||||||
|
background-color: #474747;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
.ui-layout-resizer {
|
||||||
|
background: <?php echo $collection_bar_foreground_override; ?>;
|
||||||
|
} <?php
|
||||||
|
}
|
||||||
|
|
||||||
|
// Override the button colour
|
||||||
|
if (isset($button_colour_override) && $button_colour_override != '') { ?>
|
||||||
|
button,
|
||||||
|
input[type=submit],
|
||||||
|
input[type=button],
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend a,
|
||||||
|
.UploadButton a,
|
||||||
|
.uppy-StatusBar-actionBtn,
|
||||||
|
.uppy-Dashboard-browse,
|
||||||
|
.uppy-StatusBar.is-waiting .uppy-StatusBar-actionBtn--upload,
|
||||||
|
.uppy-StatusBar.is-waiting .uppy-StatusBar-actionBtn--upload:hover,
|
||||||
|
.uppy-DashboardContent-back, .uppy-DashboardContent-back:focus,
|
||||||
|
.uppy-DashboardContent-addMore, .uppy-DashboardContent-addMore:focus {
|
||||||
|
background-color: <?php echo $button_colour_override; ?>;
|
||||||
|
} <?php
|
||||||
|
}
|
||||||
|
|
||||||
|
// Apply user uploaded custom font
|
||||||
|
if (isset($custom_font) && $custom_font != '') {
|
||||||
|
$custom_font_url = str_replace('[storage_url]', $storageurl, $custom_font);
|
||||||
|
?>
|
||||||
|
@font-face {
|
||||||
|
font-family: "custom_font";
|
||||||
|
src: url("<?php echo $custom_font_url; ?>");
|
||||||
|
}
|
||||||
|
h1,h2,h3,h4,h5,h6,.Title {
|
||||||
|
font-family: custom_font, Arial, Helvetica, sans-serif;
|
||||||
|
}
|
||||||
|
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button,.ui-widget, body, input, textarea,
|
||||||
|
select, button {
|
||||||
|
font-family: custom_font, Arial, Helvetica, sans-serif;
|
||||||
|
} <?php
|
||||||
|
}
|
||||||
|
|
||||||
|
// Higher contrast mode changes
|
||||||
|
if (isset($high_contrast_mode) && $high_contrast_mode) { ?>
|
||||||
|
body, html {
|
||||||
|
background: white;
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
a:link, a:visited,
|
||||||
|
#modal .RecordHeader h1, #modal .BasicsBox h1,
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend p, .RecordPanel .RecordDownload .DownloadDBlend td,
|
||||||
|
.HorizontalWhiteNav a:link, .HorizontalWhiteNav a:visited, .HorizontalWhiteNav a:active,
|
||||||
|
.BasicsBox .VerticalNav a:link, .BasicsBox .VerticalNav a:visited, .BasicsBox .VerticalNav a:active,
|
||||||
|
.ListTitle a:link, .ListTitle a:visited, .ListTitle a:active,
|
||||||
|
.search-icon, .search-icon:hover, .search-icon:active, .jstree-default-dark .jstree-anchor {
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
a:hover, a:active {
|
||||||
|
text-decoration: underline !important;
|
||||||
|
text-underline-position: under;
|
||||||
|
}
|
||||||
|
input[type="checkbox"], input[type="radio"] {
|
||||||
|
transform: scale(1.5);
|
||||||
|
}
|
||||||
|
h1, h2, .Tab a, h2.CollapsibleSectionHead, h1.CollapsibleSectionHead {
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
table {
|
||||||
|
border-collapse: collapse;
|
||||||
|
}
|
||||||
|
.Listview tr, .NavUnderline, .Question {
|
||||||
|
border-bottom: 1px solid black;
|
||||||
|
}
|
||||||
|
.Listview tr:last-child {
|
||||||
|
border-bottom: 0;
|
||||||
|
}
|
||||||
|
#SearchBox, #HomeSiteText.dashtext, .HomePanelIN, .PopupCategoryTree, #BrowseBar {
|
||||||
|
background: black;
|
||||||
|
}
|
||||||
|
.SearchBarTab.SearchBarTabSelected {
|
||||||
|
background: white;
|
||||||
|
color: black;
|
||||||
|
border-radius: 8px;
|
||||||
|
}
|
||||||
|
.TopInpageNav select, .update_result_order_button, select, .sp-replacer {
|
||||||
|
box-shadow: none;
|
||||||
|
border: 1px solid black;
|
||||||
|
}
|
||||||
|
.TopInpageNavLeft select, .TopInpageNavLeft select:focus, .comment_form_container,
|
||||||
|
.Listview, .user_message_text, .CategoryBox {
|
||||||
|
border: 1px solid black;
|
||||||
|
}
|
||||||
|
#Header {
|
||||||
|
border-bottom: 1px solid black;
|
||||||
|
background: white;
|
||||||
|
}
|
||||||
|
#Header li a {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
#Header .current {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
#modal, .RecordPanel, .ResourcePanelSmall, .ResourcePanelLarge, div#Metadata div.Title, .TabBar {
|
||||||
|
background-color: white;
|
||||||
|
}
|
||||||
|
.BasicsBox.SearchSticky {
|
||||||
|
background: white;
|
||||||
|
border-bottom: 1px solid black;
|
||||||
|
}
|
||||||
|
.QuestionSubmit.QuestionSticky {
|
||||||
|
background: white;
|
||||||
|
border-top: 1px solid black;
|
||||||
|
}
|
||||||
|
.Question.QuestionStickyRight {
|
||||||
|
background: white;
|
||||||
|
border-left: 1px solid black;
|
||||||
|
}
|
||||||
|
.BreadcrumbsBoxTheme {
|
||||||
|
background-color: black;
|
||||||
|
}
|
||||||
|
.icondisplay {
|
||||||
|
box-shadow: none;
|
||||||
|
}
|
||||||
|
.ResourcePanel {
|
||||||
|
box-shadow: 0 0px 0px 1px black;
|
||||||
|
}
|
||||||
|
.ResourcePanel:hover {
|
||||||
|
box-shadow: 0 0px 0px 3px black;
|
||||||
|
}
|
||||||
|
.ResourcePanelIcons a:hover {
|
||||||
|
background: black;
|
||||||
|
border-radius: 3px;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.thumbs-file-extension,
|
||||||
|
.ResourceTypeIcon.fa-fw {
|
||||||
|
background: white;
|
||||||
|
}
|
||||||
|
.RecordDownloadSpace {
|
||||||
|
border: 1px solid black;
|
||||||
|
border-bottom-left-radius: 8px;
|
||||||
|
border-bottom-right-radius: 8px;
|
||||||
|
}
|
||||||
|
button, input[type=submit], input[type=button], .RecordPanel .RecordDownloadSpace .DownloadDBlend a,
|
||||||
|
.UploadButton a, .uppy-StatusBar-actionBtn, .uppy-Dashboard-browse,
|
||||||
|
.uppy-StatusBar.is-waiting .uppy-StatusBar-actionBtn--upload,
|
||||||
|
.uppy-StatusBar.is-waiting .uppy-StatusBar-actionBtn--upload:hover, .uppy-DashboardContent-back,
|
||||||
|
.uppy-DashboardContent-back:focus, .uppy-DashboardContent-addMore, .uppy-DashboardContent-addMore:focus,
|
||||||
|
input:checked + .customFieldLabel, .keywordselected {
|
||||||
|
background-color: #146cab;
|
||||||
|
}
|
||||||
|
button:hover, input[type=submit]:hover, input[type=button]:hover,
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend a:hover, .UploadButton a:hover {
|
||||||
|
text-decoration: underline;
|
||||||
|
text-underline-position: under;
|
||||||
|
}
|
||||||
|
.TabSelected a {
|
||||||
|
color: black;
|
||||||
|
border-left: 1px solid black;
|
||||||
|
border-right: 1px solid black;
|
||||||
|
border-top: 1px solid black;
|
||||||
|
}
|
||||||
|
.RecordPanel .item h3, .RecordPanel .itemNarrow h3, th {
|
||||||
|
color: black;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
.ListviewStyle thead, .ListviewTitleStyle {
|
||||||
|
background: rgb(75 75 75);
|
||||||
|
}
|
||||||
|
.ListviewTitleStyle a, .ListviewTitleStyle a:hover {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
input[type="text"], input[type="password"], input[type="number"], input[type="email"],
|
||||||
|
textarea, select, .sp-replacer {
|
||||||
|
border: 1px solid black;
|
||||||
|
box-shadow: none;
|
||||||
|
}
|
||||||
|
.FormHelpInner {
|
||||||
|
border: 1px solid #146cab;
|
||||||
|
}
|
||||||
|
.uppy-Dashboard-inner {
|
||||||
|
border: 1px solid black;
|
||||||
|
background-color: white;
|
||||||
|
}
|
||||||
|
#iconpicker-button {
|
||||||
|
border: 1px solid black;
|
||||||
|
box-shadow: unset;
|
||||||
|
}
|
||||||
|
select, .sp-replacer {
|
||||||
|
background-image: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPHN2ZyB3aWR0aD0iMjIiIGhlaWdodD0iMTMiIHZlcnNpb249IjEuMSIgdmlld0JveD0iMCAwIDIyIDEzIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjxnIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAgLTQpIiBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxyZWN0IHk9IjIiIHdpZHRoPSIyMiIgaGVpZ2h0PSIxMSIvPjxwb2x5bGluZSB0cmFuc2Zvcm09InJvdGF0ZSg0NSA2LjAzNiA1LjAzNikiIHBvaW50cz0iOS41OTYgMS40NzUgOS41OTYgOC41OTYgMi40NzUgOC41OTYiIHN0cm9rZT0iIzAwMDAwNCIgc3Ryb2tlLXdpZHRoPSIyIi8+PC9nPjwvc3ZnPgo=);
|
||||||
|
}
|
||||||
|
.CollectBack {
|
||||||
|
background: black;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.prevLink, .nextLink, .prevPageLink, .nextPageLink {
|
||||||
|
padding: 2px 5px;
|
||||||
|
border-radius: 3px;
|
||||||
|
}
|
||||||
|
.backtoresults .maxLink {
|
||||||
|
margin-left: 20px;
|
||||||
|
padding: 4px 4px 3px 4px;
|
||||||
|
border-radius: 3px;
|
||||||
|
}
|
||||||
|
.backtoresults .closeLink {
|
||||||
|
margin-left: 5px;
|
||||||
|
padding: 2px 6px;
|
||||||
|
border-radius: 3px;
|
||||||
|
}
|
||||||
|
.backtoresults .maxLink:hover, .backtoresults .closeLink:hover,
|
||||||
|
.prevLink:hover, .nextLink:hover, .prevPageLink:hover, .nextPageLink:hover {
|
||||||
|
background-color: black;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.NonMetadataProperties {
|
||||||
|
border: 1px solid black;
|
||||||
|
border-radius: 4px;
|
||||||
|
}
|
||||||
|
.StyledTabbedPanel {
|
||||||
|
border: 1px solid black;
|
||||||
|
padding-bottom: 8px;
|
||||||
|
}
|
||||||
|
.NonMetadataProperties + .TabbedPanel {
|
||||||
|
margin-top: 8px;
|
||||||
|
padding-bottom: 6px;
|
||||||
|
border-radius: 4px;
|
||||||
|
border: 1px solid black;
|
||||||
|
}
|
||||||
|
.lock_icon {
|
||||||
|
min-width: unset;
|
||||||
|
}
|
||||||
|
.InfoTable {
|
||||||
|
border: 1px solid black;
|
||||||
|
border-collapse: separate;
|
||||||
|
border-spacing: 0;
|
||||||
|
}
|
||||||
|
.InfoTable tr+tr>td {
|
||||||
|
border-top: 1px solid black;
|
||||||
|
}
|
||||||
|
.InfoTable td+td {
|
||||||
|
border-left: 1px solid black;
|
||||||
|
}
|
||||||
|
.CommentEntry {
|
||||||
|
border: 1px solid black;
|
||||||
|
}
|
||||||
|
div.MessageBox {
|
||||||
|
color: black;
|
||||||
|
border: 1px solid black;
|
||||||
|
background: white;
|
||||||
|
}
|
||||||
|
.jstree-default-dark .jstree-hovered {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
.jstree-default-dark .jstree-wholerow-hovered {
|
||||||
|
background: black;
|
||||||
|
}
|
||||||
|
.jstree-default-dark .jstree-anchor>.jstree-icon {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
|
.ui-widget.ui-widget-content {
|
||||||
|
border: 1px solid black;
|
||||||
|
}
|
||||||
|
.ui-dialog .ui-dialog-title, .ui-widget-content {
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
.delete-dialog .ui-dialog-titlebar, .ui-dialog-titlebar {
|
||||||
|
background: white;
|
||||||
|
border-top-left-radius: 10px;
|
||||||
|
border-top-right-radius: 10px;
|
||||||
|
}
|
||||||
|
#modal_dialog {
|
||||||
|
border-top: 1px solid black;
|
||||||
|
border-radius: 0;
|
||||||
|
}
|
||||||
|
.ui-dialog {
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
.ui-widget.ui-button {
|
||||||
|
background: white;
|
||||||
|
border: 1px solid black;
|
||||||
|
color: black;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
.ui-widget.ui-button:hover {
|
||||||
|
background: black;
|
||||||
|
color: white;
|
||||||
|
text-decoration: underline;
|
||||||
|
} <?php
|
||||||
|
}
|
||||||
|
|
||||||
|
// Simple Search pills using jQuery tag editor
|
||||||
|
if ($simple_search_pills_view) { ?>
|
||||||
|
.search-icon, .search-icon:hover, .search-icon:active {
|
||||||
|
background-color: #ffffff00;
|
||||||
|
margin-top: -36px;
|
||||||
|
margin-left: 221px;
|
||||||
|
} <?php
|
||||||
|
}
|
||||||
|
|
3
css/fonts/Arial.css
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
h1,h2,h3,h4,h5,h6,.Title {font-family: Arial, Helvetica, sans-serif;}
|
||||||
|
|
||||||
|
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button,.ui-widget, body, input, textarea, select, button {font-family: Arial, Helvetica, sans-serif;}
|
8
css/fonts/Inter.css
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
@font-face {
|
||||||
|
font-family: "Inter";
|
||||||
|
src: url("../../lib/fonts/Inter/Inter-VariableFont_opsz,wght.ttf");
|
||||||
|
}
|
||||||
|
|
||||||
|
h1,h2,h3,h4,h5,h6,.Title {font-family: Inter, Arial, Helvetica, sans-serif;}
|
||||||
|
|
||||||
|
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button,.ui-widget, body, input, textarea, select, button {font-family: Inter, Arial, Helvetica, sans-serif;}
|
9
css/fonts/Montserrat.css
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
@font-face
|
||||||
|
{
|
||||||
|
font-family: "Montserrat";
|
||||||
|
src: url("../../lib/fonts/Montserrat/Montserrat-VariableFont_wght.ttf");
|
||||||
|
}
|
||||||
|
|
||||||
|
h1,h2,h3,h4,h5,h6,.Title {font-family: Montserrat, Arial, Helvetica, sans-serif;}
|
||||||
|
|
||||||
|
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button,.ui-widget, body, input, textarea, select, button {font-family: Montserrat, Arial, Helvetica, sans-serif;}
|
9
css/fonts/OpenSans.css
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
@font-face
|
||||||
|
{
|
||||||
|
font-family: "Open Sans";
|
||||||
|
src: url("../../lib/fonts/Open_Sans/OpenSans-VariableFont_wdth\,wght.ttf");
|
||||||
|
}
|
||||||
|
|
||||||
|
h1,h2,h3,h4,h5,h6,.Title {font-family: Open Sans, Arial, Helvetica, sans-serif;}
|
||||||
|
|
||||||
|
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button,.ui-widget, body, input, textarea, select, button {font-family: Open Sans, Arial, Helvetica, sans-serif;}
|
9
css/fonts/Roboto.css
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
@font-face
|
||||||
|
{
|
||||||
|
font-family: "Roboto";
|
||||||
|
src: url("../../lib/fonts/Roboto/Roboto-Regular.ttf");
|
||||||
|
}
|
||||||
|
|
||||||
|
h1,h2,h3,h4,h5,h6,.Title {font-family: Roboto, Arial, Helvetica, sans-serif;}
|
||||||
|
|
||||||
|
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button,.ui-widget, body, input, textarea, select, button {font-family: Roboto, Arial, Helvetica, sans-serif;}
|
10
css/fonts/Space Grotesk.css
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
@font-face
|
||||||
|
{
|
||||||
|
font-family: "Space Grotesk";
|
||||||
|
src: url("../../lib/fonts/Space_Grotesk/SpaceGrotesk-VariableFont_wght.ttf");
|
||||||
|
}
|
||||||
|
|
||||||
|
h1,h2,h3,h4,h5,h6,.Title {font-family: Space Grotesk, Arial, Helvetica, sans-serif;}
|
||||||
|
|
||||||
|
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button,.ui-widget, body, input, textarea, select, button {font-family: Space Grotesk, Arial, Helvetica, sans-serif;font-size:16px;}
|
||||||
|
|
9
css/fonts/Ubuntu.css
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
@font-face
|
||||||
|
{
|
||||||
|
font-family: "Ubuntu";
|
||||||
|
src: url("../../lib/fonts/Ubuntu/Ubuntu-Regular.ttf");
|
||||||
|
}
|
||||||
|
|
||||||
|
h1,h2,h3,h4,h5,h6,.Title {font-family: Ubuntu, Arial, Helvetica, sans-serif;}
|
||||||
|
|
||||||
|
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button,.ui-widget, body, input, textarea, select, button {font-family: Ubuntu, Arial, Helvetica, sans-serif;}
|
9
css/fonts/WorkSans.css
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
@font-face
|
||||||
|
{
|
||||||
|
font-family: "Work Sans";
|
||||||
|
src: url("../../lib/fonts/Work_Sans/WorkSans-VariableFont_wght.ttf");
|
||||||
|
}
|
||||||
|
|
||||||
|
h1,h2,h3,h4,h5,h6,.Title {font-family: Work Sans, Arial, Helvetica, sans-serif;}
|
||||||
|
|
||||||
|
.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button,.ui-widget, body, input, textarea, select, button {font-family: Work Sans, Arial, Helvetica, sans-serif;}
|
2675
css/global.css
Executable file
788
css/light.css
Executable file
@@ -0,0 +1,788 @@
|
|||||||
|
/*
|
||||||
|
* Colour Style Document for ResourceSpace
|
||||||
|
*
|
||||||
|
* Standard colour and decorative css should be contained within this file
|
||||||
|
* Standard structural styling should be placed inside global.css
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
/* Default text and background colour */
|
||||||
|
body,html {color:#474747;background: #efefef;}
|
||||||
|
|
||||||
|
h1, h2 {color: #000000;}
|
||||||
|
a:link {color:#666666;}
|
||||||
|
a:visited {color:#666666;}
|
||||||
|
a:hover {color:#2E99E6;}
|
||||||
|
a:active {opacity:0.6;}
|
||||||
|
|
||||||
|
input[readonly] {
|
||||||
|
color: #000000;
|
||||||
|
box-shadow: none;
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Header styling */
|
||||||
|
#Header {background: #fff;transform: translate3d(0, 0, 0);border: none;}
|
||||||
|
#Header li a {color:#000; opacity:0.7;}
|
||||||
|
#Header .SearchResultsDisabled,
|
||||||
|
#Header .SearchResultsDisabled:hover,
|
||||||
|
.DisabledLink,
|
||||||
|
.DisabledLink:hover {opacity: 0.35; cursor: default;}
|
||||||
|
#Header a:hover,
|
||||||
|
#Header .current {opacity:1;text-decoration: none}
|
||||||
|
/* links in Header overflow dropdown menu */
|
||||||
|
#HiddenLinks li a {color:#fff; opacity:0.7;}
|
||||||
|
#Header .UploadButton a {color: #fff;}
|
||||||
|
|
||||||
|
/* Colours for $header_text_title */
|
||||||
|
#TextHeader, #TextHeader a, #TextDesc {color:#fff;}
|
||||||
|
|
||||||
|
.FormError {color: #FF0000;}
|
||||||
|
.FormIncorrect {color: #FF0000;border: 1px solid #BBBBBB;background: #FFFFFF;}
|
||||||
|
.PageInformal {border: 1px solid #c0c0c0;background: #FFFFFF;}
|
||||||
|
.HorizontalWhiteNav a:link,
|
||||||
|
.HorizontalWhiteNav a:visited,
|
||||||
|
.HorizontalWhiteNav a:active,
|
||||||
|
.BasicsBox .VerticalNav a:link,
|
||||||
|
.BasicsBox .VerticalNav a:visited,
|
||||||
|
.BasicsBox .VerticalNav a:active,
|
||||||
|
.ListTitle a:link,
|
||||||
|
.ListTitle a:visited,
|
||||||
|
.ListTitle a:active {color:#666666;}
|
||||||
|
.HorizontalWhiteNav a:hover, .BasicsBox .VerticalNav a:hover, .ListTitle a:hover {color:#2e99e6;}
|
||||||
|
|
||||||
|
/* Search Bar */
|
||||||
|
#SearchBoxPanel a:link, #SearchBoxPanel a:visited, #SearchBoxPanel a:hover,
|
||||||
|
#ResearchBoxPanel a:link, #ResearchBoxPanel a:visited, #ResearchBoxPanel a:hover, #ResearchBoxPanel a:active,
|
||||||
|
.SearchSpace a:link, .SearchSpace a:visited, .SearchSpace a:hover, .SearchSpace a:active,
|
||||||
|
.PoweredByPanel a:link, .PoweredByPanel a:visited, .PoweredByPanel a:hover {
|
||||||
|
color:#fff;text-decoration:none;
|
||||||
|
}
|
||||||
|
|
||||||
|
.RecordPanel, .ResourcePanelSmall, .ResourcePanelLarge, div#Metadata div.Title { background: #eee; }
|
||||||
|
#ResearchBoxPanel, .HomePanelIN, .RecordPanel .RecordDownload, .RecordPanel, .ResourcePanelLarge {
|
||||||
|
border-radius:8px;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
.ResourcePanel {
|
||||||
|
background-color: white;
|
||||||
|
border-radius: 6px;
|
||||||
|
transition: all 0.1s ease-in-out;
|
||||||
|
box-shadow: 0 1px 3px rgba(0,0,0,0.1);
|
||||||
|
border: 3px solid rgba(255, 255, 255, 0);
|
||||||
|
}
|
||||||
|
.ResourcePanel:hover {
|
||||||
|
box-shadow: 0 1px 10px 0 rgba(0,0,0,0.3);
|
||||||
|
z-index: 100;
|
||||||
|
}
|
||||||
|
.ResourcePanelInfo {
|
||||||
|
color: #727272;
|
||||||
|
}
|
||||||
|
.ResourcePanelInfo a {
|
||||||
|
color: #414141;
|
||||||
|
}
|
||||||
|
.ResourcePanel.Selected { border: 3px solid #2E99E6; }
|
||||||
|
tr[id^="ResourceShell"].Selected { background-color: #d5eafa; /* Used a tint of #2e99e6 which is used for .ResourcePanel.Selected */ }
|
||||||
|
|
||||||
|
.ResourcePanelIcons a.fa-minus-circle { color: #e91d1d }
|
||||||
|
|
||||||
|
#SearchBoxPanel h2, #ThemeBoxPanel h2, #ResearchBoxPanel h2, .SearchSpace h2{color: #fff;}
|
||||||
|
|
||||||
|
/* Collection Bar */
|
||||||
|
.ui-layout-resizer {background: #444444;}
|
||||||
|
.ui-layout-toggler-open-hover{border-radius:2px;}
|
||||||
|
.CollectBack {color:#E0E0E0;background: #2b2b2b;}
|
||||||
|
.CollectBack a:link, .CollectBack a:visited, .CollectBack a:active,.CollectBack h2,.BrowseBar a:link,.BrowseBar a:hover, .BrowseBar a:visited, .BrowseBar a:active,.BrowseBar h2 {color:#E0E0E0;}
|
||||||
|
.CollectBack a:hover{color:#FFF;}
|
||||||
|
.CollectBack h2 a:link, .CollectBack h2 a:visited, .CollectBack h2 a:active, .CollectBack h2 a:hover {color:white;}
|
||||||
|
#CollectionMinRightNav li {border-left:1px solid #E0E0E0;}
|
||||||
|
.CollectionPanelShell {background-color: #444;}
|
||||||
|
|
||||||
|
/* Related resources */
|
||||||
|
#RelatedResources .CollectionPanelShell {background-color: #fff;}
|
||||||
|
|
||||||
|
/* Home */
|
||||||
|
.HomePanel a:link,
|
||||||
|
.HomePanel a:visited,
|
||||||
|
.HomePanel a:active,
|
||||||
|
.HomePanel a:hover,
|
||||||
|
.HomePanel h2 {color:#FFF;}
|
||||||
|
#HomeSiteText {padding:10px;}
|
||||||
|
#HomeSiteText.dashtext h1 {color:#FFF;}
|
||||||
|
|
||||||
|
/* Default colours for search, dash tiles, browse bar etc */
|
||||||
|
#SearchBox, #HomeSiteText.dashtext, .HomePanelIN, .PopupCategoryTree {
|
||||||
|
background: rgba(0, 0, 0, 0.51);
|
||||||
|
color:#FFF;
|
||||||
|
}
|
||||||
|
|
||||||
|
.CollectImageBorder {border: 1px solid #000000;}
|
||||||
|
.ASC::before {content: " \25BC";font-size:80%;}
|
||||||
|
.DESC::before {content: " \25B2";font-size:80%;}
|
||||||
|
|
||||||
|
.NavUnderline,.Question {border-bottom: 1px solid #e2e2e2;}
|
||||||
|
|
||||||
|
/* Table header styling */
|
||||||
|
.ListviewStyle thead, .ListviewTitleStyle {
|
||||||
|
background: #444;
|
||||||
|
text-transform: uppercase;
|
||||||
|
}
|
||||||
|
.ListviewTitleStyle td, .ListviewTitleStyle th, .ListviewTitleStyle a, .ListviewTitleStyle a:visited {
|
||||||
|
color: #fff;
|
||||||
|
font-size: 0.875rem;
|
||||||
|
}
|
||||||
|
.ListviewTitleStyle a:hover {
|
||||||
|
color: #d4d4d4;
|
||||||
|
text-decoration:none;
|
||||||
|
}
|
||||||
|
.ListviewStyle
|
||||||
|
{
|
||||||
|
border-collapse: collapse;
|
||||||
|
}
|
||||||
|
.ListviewStyle tr:nth-child(even):not(.ListviewTitleStyle)
|
||||||
|
{
|
||||||
|
background-color: #f6f6f6;
|
||||||
|
}
|
||||||
|
.tableRowEven
|
||||||
|
{
|
||||||
|
background-color: #f6f6f6 !important;
|
||||||
|
}
|
||||||
|
.tableRowOdd
|
||||||
|
{
|
||||||
|
background-color: #ffffff !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ListviewStyle tr:hover {
|
||||||
|
background-color: #e5e5e5 !important;
|
||||||
|
}
|
||||||
|
tr.ListviewTitleStyle:hover {
|
||||||
|
background-color: black !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ListViewBulkActions span {color: #666666}
|
||||||
|
.ListViewBulkActions span:hover {color: #2E99E6;}
|
||||||
|
|
||||||
|
|
||||||
|
.Question select .optionWeekend { background-color: #ccc; }
|
||||||
|
.lockedQuestion {background-color: #ddd; }
|
||||||
|
.Question.FieldSaveError {background: #F1A9A0;}
|
||||||
|
div.autocomplete {background-color:white;border:1px solid #888;}
|
||||||
|
div.autocomplete ul li.selected { background-color: #ffb;}
|
||||||
|
div.autocomplete ul li {color: #000;}
|
||||||
|
#outerImageContainer{ background-color: #fff;}
|
||||||
|
#imageDataContainer{ background-color: #fff;}
|
||||||
|
#imageData{color: #666;}
|
||||||
|
#imageData #caption{ font-weight: bold; }
|
||||||
|
#overlay{ background-color: #000;}
|
||||||
|
.FormHelpInner{background-color:#ffffff;border:1px solid #2e99e6;border-radius:4px;}
|
||||||
|
.RecordDownloadSpace .HorizontalWhiteNav a:active, .RecordPanel .RecordDownloadSpace .HorizontalWhiteNav a:hover {color:#FFFFFF;}
|
||||||
|
.NoFind {border: none;background: #FFFFFF;}
|
||||||
|
.NoFind .highlight {color:#000000;font-weight: bold;}
|
||||||
|
.NoFind a:link, .NoFind a:visited, .NoFind a:hover, .NoFind a:active {color:#2e99e6;text-decoration:underline;}
|
||||||
|
.ViewPanelTitles .Title { border-bottom: 0; }
|
||||||
|
.RecordDownloadSpace { background: #fff;}
|
||||||
|
.RecordPanel .RecordDownload .DownloadDBlend td {border-top: 1px solid #ddd;color: #333;}
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend .DownloadButton {background-color: transparent;}
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend p {color: #757575;text-align: left;font-size: 0.80rem;}
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend, .toolbox {background: #fff; border-color: #6D6D6D;}
|
||||||
|
.ArchiveResourceTitle, .ResourcePendingSubmissionTitle, .ResourcePendingReviewTitle {color: #888;}
|
||||||
|
.DeletedResourceTitle {color: #FF0000;}
|
||||||
|
.RecordStory{color: #000000;background: #FFFFFF; .Rec border-top : 1px solid #ddd;}
|
||||||
|
.RecordStory h1{color: #000000;}
|
||||||
|
.RecordStory a:hover{color: #000000;}
|
||||||
|
.RecordStory .highlight {color:black;}
|
||||||
|
.BasicsBox .HorizontalNav li {border-right:1px solid #B5C3D4;border-top-style: none;border-bottom-style: none;border-left-style: none;}
|
||||||
|
.ThemeBox {border-bottom: 1px solid #BBBBBB;}
|
||||||
|
.CategoryBox {border:1px solid rgba(0,0,0,0.25);background-color:#ffffff;color: black;font-weight: normal; border-radius: 4px;}
|
||||||
|
.MiniCategoryBox {box-shadow: 0 1px 3px 1px rgba(0,0,0,0.1);background-color:#ffffff;color: black;font-weight: normal; border-radius: 5px;}
|
||||||
|
.CategoryTree {border-top:1px solid #737373;border-left:1px solid #999999;border-bottom:1px solid #999999;border-right:1px solid #999999;background-color:white;color: black;font-weight: normal;}
|
||||||
|
|
||||||
|
/* Star Ratings */
|
||||||
|
.StarSelect {background: transparent url('../gfx/interface/RatingStarYellow.gif') no-repeat;}
|
||||||
|
.StarWhite {background: transparent url('../gfx/interface/RatingStarWhite.gif') no-repeat;}
|
||||||
|
.StarGrey {background: transparent url('../gfx/interface/RatingStarGrey.gif') no-repeat;}
|
||||||
|
.StarEmpty {background: transparent url('../gfx/interface/RatingStarGrey.gif') no-repeat;}
|
||||||
|
.StarCurrent {background: transparent url('../gfx/interface/RatingStarRed.gif') no-repeat;}
|
||||||
|
.IconUserRatingStar {background: url(../gfx/interface/RatingStarRed.gif) no-repeat;}
|
||||||
|
.IconUserRatingSpace {background: url(../gfx/interface/RatingStarBlank.gif) no-repeat;}
|
||||||
|
.RatingStars a:hover {text-decoration:none;}
|
||||||
|
#RatingStarLink0 {color: #888;}
|
||||||
|
|
||||||
|
.Listview .ListViewSubTable,.Listview .ListViewSubTable td,.Listview .ListViewSubTable tr {background-image: none;}
|
||||||
|
.Listview {background-color: white;}
|
||||||
|
.highlight {color: #000;background-color: #ff0;}
|
||||||
|
.Tab a {padding: 8px 1rem;background: rgba(255, 255, 255, 0.4);}
|
||||||
|
.TabBar { background-color: #ededed; }
|
||||||
|
#BasicsBoxTabs > .TabBar { background-color: #f2f2f2;} /* On Edit page w/ $tabs_on_edit */
|
||||||
|
.StyledTabbedPanel {background: #fff;}
|
||||||
|
.TabSelected {border-left: #bbbbbb;}
|
||||||
|
.TabSelected a {background: #ffffff; color: #666666; border-bottom: 1px solid #ffffff; }
|
||||||
|
.InfoTable {border-collapse:collapse;border-radius: 4px;}
|
||||||
|
.InfoTable {background: #fff;}
|
||||||
|
.InfoTable tr+tr>td {border-top:1px solid #ddd;}
|
||||||
|
.InfoTable td+td {border-left:1px solid #BBBBBB;}
|
||||||
|
#InfoBoxInner {color:black;}
|
||||||
|
#InfoBoxInner h2 {color:black;font-weight:bold;}
|
||||||
|
#InfoBoxInner p {color:black;}
|
||||||
|
#InfoBoxCollectionInner {color:black;}
|
||||||
|
#InfoBoxCollectionInner h2 {color:black;}
|
||||||
|
#InfoBoxCollectionInner p {color:black;}
|
||||||
|
.NewFlag { background-color: #fff; color: #737373; text-shadow: none;}
|
||||||
|
|
||||||
|
/* Single file upload progress bar */
|
||||||
|
.meter-value {background-color: #BBBBBB;}
|
||||||
|
.meter-wrap{border:1px solid #BBBBBB;}
|
||||||
|
|
||||||
|
.Terms{color:#000;border: 1px solid #ccc;background: #fff;}
|
||||||
|
.ui-layout-toggler-open-hover{background-color:rgba(255,255,255,0.3);}
|
||||||
|
|
||||||
|
.proptitle{color: #FFFFFF;background: rgb(119,119,119);}
|
||||||
|
.propbox{color: #000000;background: #FFFFFF;}
|
||||||
|
.propbox a:link {color: rgb(115,115,115); background: none;}
|
||||||
|
.propbox a:visited {color: rgb(115,115,115); background: none;}
|
||||||
|
.propbox a:hover {color: #000000; background: none;}
|
||||||
|
.propbox a:active {color: #000000; background: none;}
|
||||||
|
.permissionstable tr td.permheader{color: #000000;background: rgb(221,221,221)}
|
||||||
|
.permissionstable tbody{color: #000000;}
|
||||||
|
.CodeMirror-wrapping{color: #000000;background: #FFFFFF;}
|
||||||
|
|
||||||
|
.CommentBody { color: #000000}
|
||||||
|
.TaggingHint {background-color: white; border-bottom: 1px solid rgba(0,0,0,0.25); border-left: 1px solid rgba(0,0,0,0.25); border-right: 1px solid rgba(0,0,0,0.25);}
|
||||||
|
.TaggingHint:hover {background-color:#EEE;text-decoration:none;color:black;}
|
||||||
|
|
||||||
|
/* Dash Tiles */
|
||||||
|
#dash_tile_bin.ui-state-hover {
|
||||||
|
background:#000;
|
||||||
|
background:rgba(0, 0, 0, 0.55);
|
||||||
|
border:#2f2f2f 1px solid;
|
||||||
|
color:#d7d7d7;
|
||||||
|
}
|
||||||
|
#dash_tile_bin.ui-state-active {
|
||||||
|
background: rgba(114, 22, 37, 0.51);
|
||||||
|
border: 1px solid #d0d0d0;
|
||||||
|
}
|
||||||
|
.dash_tile_bin_text {color: #fff;}
|
||||||
|
|
||||||
|
.HomePanel h2.title {background: transparent;color:#fff;}
|
||||||
|
.HomePanel .HomePanelDynamicDash h2{background: rgba(0,0,0,0.4); text-shadow: 0px 1px 5px #000000;}
|
||||||
|
.HomePanelDynamicDash p.tile_corner_box {background: rgba(0,0,0,0.4);border-top-left-radius: 5px;color:#fff;}
|
||||||
|
|
||||||
|
/* Delete Dialog */
|
||||||
|
.delete-dialog .ui-dialog-titlebar, .ui-dialog-titlebar{
|
||||||
|
background: white;
|
||||||
|
border: #878787;
|
||||||
|
color: #3A3A3A;
|
||||||
|
}
|
||||||
|
.delete-dialog .ui-state-default .ui-button-text, .ui-state-default .ui-button-text{color: #000000;background-color: #FFF;}
|
||||||
|
.delete-dialog .ui-state-default.ui-state-hover .ui-button-text, .ui-state-default.ui-state-hover .ui-button-text {color: #FFF;background-color: #3A3A3A;}
|
||||||
|
.delete-dialog .ui-state-default.ui-state-focus, .ui-state-default.ui-state-focus {border:solid 1px #878787;}
|
||||||
|
.delete-dialog .ui-state-default.ui-state-hover, .ui-state-default.ui-state-hover {border:solid 1px #878787;}
|
||||||
|
|
||||||
|
/* Trash Bin */
|
||||||
|
#trash_bin.ui-state-hover {
|
||||||
|
border: #2f2f2f 1px solid;
|
||||||
|
background: #000;
|
||||||
|
background: rgba(0, 0, 0, 0.8);
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
#trash_bin.ui-state-active, .ui-state-active {border: 1px solid #d0d0d0;background: rgba(114, 22, 37, 0.51);}
|
||||||
|
.trash_bin_text {color: #fff;}
|
||||||
|
.ui-draggable-dragging {border: 2px solid; transition: none;}
|
||||||
|
|
||||||
|
/* Modal */
|
||||||
|
#modal_overlay {
|
||||||
|
background: #000;
|
||||||
|
}
|
||||||
|
#modal {
|
||||||
|
background-color: #f3f3f3;
|
||||||
|
box-shadow: 0 0 40px rgba(0,0,0,0.5);
|
||||||
|
border-radius: 6px;
|
||||||
|
}
|
||||||
|
#modal .RecordHeader, #modal .BasicsBox h1, #modal .TopInpageNav {
|
||||||
|
background: none;
|
||||||
|
color: #999;
|
||||||
|
}
|
||||||
|
#modal .RecordHeader h1, #modal .BasicsBox h1 {
|
||||||
|
color: #333;
|
||||||
|
}
|
||||||
|
|
||||||
|
#CollectionDiv select {
|
||||||
|
background-color: #555;
|
||||||
|
color:#fff;
|
||||||
|
border:none;
|
||||||
|
height: 26px;
|
||||||
|
padding-left: 5px;
|
||||||
|
min-height: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Messaging */
|
||||||
|
span.Pill {
|
||||||
|
color: white;
|
||||||
|
background: #e41e3f;
|
||||||
|
}
|
||||||
|
div.MessageBox {
|
||||||
|
border: 1px solid darkgray;
|
||||||
|
background: rgba(220,220,220,0.9);
|
||||||
|
}
|
||||||
|
div.MessageBox a {
|
||||||
|
color: inherit !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Login box */
|
||||||
|
#login_box {background: rgba(0, 0, 0, 0.6)}
|
||||||
|
#login_box .Question {border-bottom: none; padding: 0.6em 0 0 0;}
|
||||||
|
#login_box .QuestionSubmit {background:none; border: none;}
|
||||||
|
#login_box .Question .stdwidth {width: 550px; border-radius: 6px; min-height: 32px;}
|
||||||
|
#login_box, #login_box h1, #login_box a {color: #FFF;}
|
||||||
|
#login_box .Question input[type=text], #login_box .Question input[type=password], #login_box textarea {
|
||||||
|
background-color: #9a9a9ad9;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Highlighting required fields in certain plugins */
|
||||||
|
.highlighted {border: 3px solid #F00 !important;}
|
||||||
|
|
||||||
|
#previewimage, #previewimagecopy, #contact-sheet--previewimage {box-shadow: 0 2px 6px rgba(0,0,0,0.2 );}
|
||||||
|
|
||||||
|
/* chosen collection div */
|
||||||
|
#CollectionDiv #MinColDrop .chosen-single:hover, #CollectionDiv #colselect .chosen-single:hover {color:#444;}
|
||||||
|
#CollectionDiv .ActionsContainer .chosen-single:hover {color:#999;}
|
||||||
|
|
||||||
|
.FeaturedSimpleTile {
|
||||||
|
background: rgba(30, 30, 30, 0.70);
|
||||||
|
color:#FFF;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Highlight selected keywords */
|
||||||
|
input:checked + .customFieldLabel, .keywordselected {
|
||||||
|
background-color: #2e99e6;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
#ProcessingBox{
|
||||||
|
background-color:white;
|
||||||
|
color:black;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ReportSheet {background-color:#fff;border:1px solid black;color:black;}
|
||||||
|
.ReportSheet h2 {color:black;}
|
||||||
|
.ReportSheet p {color:black;}
|
||||||
|
.ReportSummary {background-color:white;color:black;border-collapse:collapse;}
|
||||||
|
.ReportSummary td {border:1px solid #888;color:black;}
|
||||||
|
.ReportMetric {color:black;}
|
||||||
|
.SearchBreadcrumbs > span {color: #6a6a6a;}
|
||||||
|
.BreadcrumbsBox a, .BreadcrumbsBox a:link, .BreadcrumbsBox a:visited { color: #474747; }
|
||||||
|
.BreadcrumbsBoxTheme {background-color: rgba(0, 0, 0, 0.51);margin: 0 1em 1em 0; padding: 6px 8px; color: white;border-radius:6px;}
|
||||||
|
.BreadcrumbsBoxTheme.BreadcrumbsBox a,
|
||||||
|
.BreadcrumbsBoxTheme.BreadcrumbsBox a:link,
|
||||||
|
.BreadcrumbsBoxTheme.BreadcrumbsBox a:visited {color: white;}
|
||||||
|
.TopInpageNav select {
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.keywordselected a:visited, .keywordselected a:link {
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
#Header #ssearchbox:focus {
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Highlight number of returned search results */
|
||||||
|
#SearchResultFound .Selected {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Browse bar */
|
||||||
|
#BrowseBar a {color: #fff;}
|
||||||
|
.BrowseBarText {color: #fff;}
|
||||||
|
.BrowseBarItem.ui-droppable-hover a .BrowseBarLink{border: 2px solid #FFF;}
|
||||||
|
|
||||||
|
/* Firefox on macOS optgroup background styling fix */
|
||||||
|
@supports (-moz-osx-font-smoothing: auto) {
|
||||||
|
#CollectionDiv select optgroup {
|
||||||
|
color: initial;
|
||||||
|
}
|
||||||
|
#CollectionDiv select optgroup option {
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Scrollbar styling */
|
||||||
|
::-webkit-scrollbar:vertical {width:12px;}
|
||||||
|
::-webkit-scrollbar:horizontal {height:12px;}
|
||||||
|
::-webkit-scrollbar,::-webkit-scrollbar-corner {background:none;}
|
||||||
|
::-webkit-scrollbar-thumb {background:rgba(0,0,0,0.3);border-radius: 6px;}
|
||||||
|
::-webkit-scrollbar-thumb:hover{background:rgba(0,0,0,0.35);border-radius: 6px;}
|
||||||
|
::-webkit-scrollbar-thumb:active{background:rgba(0,0,0,0.4);border-radius: 6px;}
|
||||||
|
|
||||||
|
|
||||||
|
.FeaturedSimpleTile .FeaturedSimpleTileContents h2
|
||||||
|
{
|
||||||
|
background-color: rgba(0,0,0,0.4);
|
||||||
|
padding-bottom: 5px;
|
||||||
|
text-shadow: 0px 1px 5px #000000;
|
||||||
|
}
|
||||||
|
|
||||||
|
.FeaturedSimpleTile .FeaturedSimpleTileContents .FeaturedSimpleTileText h2 {
|
||||||
|
background-color: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.SelectionCollectionLink, .SelectionCollectionLink:link, .SelectionCollectionLink:visited, .MessageBox { color: #474747; }
|
||||||
|
.ClearSelectedButton { background-color: #ff2b2b; }
|
||||||
|
.ClearSelectedButton:hover { background-color: #b71c1c; }
|
||||||
|
|
||||||
|
.codecomment
|
||||||
|
{
|
||||||
|
color:#090;
|
||||||
|
}
|
||||||
|
.codeexample
|
||||||
|
{
|
||||||
|
background-color:white;
|
||||||
|
color:black;
|
||||||
|
}
|
||||||
|
.codeoutput
|
||||||
|
{
|
||||||
|
background-color:black;color:white;border-left:10px solid #666;
|
||||||
|
}
|
||||||
|
|
||||||
|
.currenteditmulti {background-color: #8a8d8f !important;}
|
||||||
|
|
||||||
|
.SearchBarTab.SearchBarTabSelected {
|
||||||
|
background: rgb(255 255 255 / 14%);
|
||||||
|
}
|
||||||
|
|
||||||
|
.SearchBarTab:hover {
|
||||||
|
background: rgba(255, 255, 255, 10%);
|
||||||
|
}
|
||||||
|
|
||||||
|
#HomeSiteText h1,#HomeSiteText p {color:#fff;}
|
||||||
|
|
||||||
|
button, input[type=submit], input[type=button], .RecordPanel .RecordDownloadSpace .DownloadDBlend a, .UploadButton a {
|
||||||
|
background-color: #1679c0;
|
||||||
|
box-shadow: 0 1px 3px rgba(0,0,0,0.25);
|
||||||
|
}
|
||||||
|
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend .MissingFile a {
|
||||||
|
border: 1px solid #000;
|
||||||
|
background-color: #fff;
|
||||||
|
color: #000;
|
||||||
|
box-shadow: 0 1px 3px rgba(0,0,0,0.25);
|
||||||
|
}
|
||||||
|
|
||||||
|
.emailinvalid {
|
||||||
|
background-color: red;
|
||||||
|
}
|
||||||
|
|
||||||
|
select, .sp-replacer {
|
||||||
|
background-color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
select:before {
|
||||||
|
color: #2e99e6;
|
||||||
|
}
|
||||||
|
|
||||||
|
input:focus, textarea:focus, select:focus, .RecordPanel .RecordDownloadSpace .DownloadDBlend a:focus {
|
||||||
|
box-shadow: 0 0 6px hsla(205, 79%, 54%, 0.5);
|
||||||
|
}
|
||||||
|
|
||||||
|
.ListViewBulkActions .DisabledLink:hover {color: #666666;}
|
||||||
|
|
||||||
|
.QuestionSubmit.QuestionSticky {
|
||||||
|
background-color: #f2f2f2;
|
||||||
|
border-top: 1px solid #c1c1c1;
|
||||||
|
box-shadow: 0 -12px 15px -12px #bbbbbb;
|
||||||
|
}
|
||||||
|
.Question #capswarning {color: red;}
|
||||||
|
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend .AltThumbLink,
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend .AltThumbLink:hover,
|
||||||
|
.RecordPanel .RecordDownloadSpace .DownloadDBlend .AltThumbLink:active {
|
||||||
|
background-color: white;
|
||||||
|
box-shadow: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.RecordPanel .item h3, .RecordPanel .itemNarrow h3, th {color: #767676;}
|
||||||
|
|
||||||
|
.uppy-StatusBar-actionBtn,
|
||||||
|
.uppy-Dashboard-browse,
|
||||||
|
.uppy-StatusBar.is-waiting .uppy-StatusBar-actionBtn--upload,
|
||||||
|
.uppy-StatusBar.is-waiting .uppy-StatusBar-actionBtn--upload:hover,
|
||||||
|
.uppy-DashboardContent-back, .uppy-DashboardContent-back:focus,
|
||||||
|
.uppy-DashboardContent-addMore, .uppy-DashboardContent-addMore:focus {
|
||||||
|
background-color: #1988d7;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
.uppy-Dashboard-browse:focus, .uppy-Dashboard-browse:hover {
|
||||||
|
border: 1px solid transparent;
|
||||||
|
}
|
||||||
|
.uppy-DashboardContent-back:hover,
|
||||||
|
.uppy-DashboardContent-addMore:hover {
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.uppy-Dashboard-Item-action--remove {
|
||||||
|
border: unset;
|
||||||
|
box-shadow: unset;
|
||||||
|
background-color: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.uppy-Dashboard-Item-previewInnerWrap {
|
||||||
|
background-color: #f2f2f2 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.uppy-ProviderBrowserItem-inner {
|
||||||
|
color: #000;
|
||||||
|
background-color: #F0F0F0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.CollapsibleSectionHead:hover
|
||||||
|
{
|
||||||
|
color: #757575;
|
||||||
|
}
|
||||||
|
|
||||||
|
.CommentFlagged i {color: #F44336;}
|
||||||
|
|
||||||
|
.comment_form_container{background-color: white; border: 1px solid lightgray;}
|
||||||
|
.icondisplay
|
||||||
|
{
|
||||||
|
background-color: white;
|
||||||
|
box-shadow: 0 1px 3px 1px rgb(0 0 0 / 10%);
|
||||||
|
}
|
||||||
|
|
||||||
|
.update_result_order_button {
|
||||||
|
background-color: white;
|
||||||
|
box-shadow: 0 1px 3px 1px rgb(0 0 0 / 10%);
|
||||||
|
}
|
||||||
|
|
||||||
|
.search-icon,
|
||||||
|
.search-icon:hover,
|
||||||
|
.search-icon:active {
|
||||||
|
color: #0299d8;
|
||||||
|
background-color: #e8edf1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.DashTileActions {
|
||||||
|
color: #fff;
|
||||||
|
background: #000;
|
||||||
|
}
|
||||||
|
|
||||||
|
#modal .BasicsBox .HelpHeader a { color: #999; }
|
||||||
|
.FeaturedSimpleTileActions {
|
||||||
|
color: #fff;
|
||||||
|
background: #000;
|
||||||
|
}
|
||||||
|
|
||||||
|
.FeaturedSimpleTile.FullWidth .FeaturedSimpleTileContents h2 span[data-tag="resources_count"] { background-color: #646B60; }
|
||||||
|
|
||||||
|
.FeaturedCallToActionTile.FullWidth .FeaturedSimpleTileContents { background-color: rgba(0,0,0,0.4); }
|
||||||
|
#login_box textarea {
|
||||||
|
background-color: #9a9a9ad9;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
#login_box .FormError {
|
||||||
|
color: white;
|
||||||
|
background-color: #ff000030;
|
||||||
|
border: 2px solid red;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ImageTools
|
||||||
|
{
|
||||||
|
background-color:black;
|
||||||
|
}
|
||||||
|
|
||||||
|
#PreviewToolsOptionsWrapper {
|
||||||
|
background: rgba(0, 0, 0, 0.65);
|
||||||
|
color: #FFF;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ToolsOptionLink:link, .ToolsOptionLink:visited {
|
||||||
|
color: #FFF;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ToolsOptionLink:hover {
|
||||||
|
color: #79BC41;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ToolsOptionLink.Enabled {
|
||||||
|
color: #79BC41;
|
||||||
|
}
|
||||||
|
|
||||||
|
a.Enabled, a:visited.Enabled {
|
||||||
|
color: #79BC41;
|
||||||
|
}
|
||||||
|
|
||||||
|
#Metadata {
|
||||||
|
background-color: #FFF;
|
||||||
|
}
|
||||||
|
|
||||||
|
#OverFlowLinks {
|
||||||
|
background-color: rgba(0, 0, 0, 0.6);
|
||||||
|
}
|
||||||
|
|
||||||
|
#Header #ssearchbox {
|
||||||
|
background-color: rgba(255, 255, 255, 0.9);
|
||||||
|
}
|
||||||
|
.MultiRTypeSelect {
|
||||||
|
background-color: #fff;
|
||||||
|
border: 1px solid rgba(0,0,0,0.25);
|
||||||
|
}
|
||||||
|
.Question.QuestionStickyRight {
|
||||||
|
background-color: #f2f2f2;
|
||||||
|
border-left: 1px solid #c1c1c1;
|
||||||
|
box-shadow: -12px 0px 15px -12px #bbbbbb;
|
||||||
|
}
|
||||||
|
|
||||||
|
.user_message_text {
|
||||||
|
background: #fff;
|
||||||
|
color: #000000;
|
||||||
|
border: 1px solid lightgray;
|
||||||
|
}
|
||||||
|
|
||||||
|
#iconpicker-button {
|
||||||
|
background-color: white;
|
||||||
|
border: 1px solid rgba(0,0,0,0.25);
|
||||||
|
box-shadow: inset -1px -1px 3px 0px rgb(0 0 0 / 10%);
|
||||||
|
}
|
||||||
|
|
||||||
|
.iconpicker-content-icon:hover {background-color: #0000001f;}
|
||||||
|
|
||||||
|
.BasicsBox.SearchSticky {
|
||||||
|
background-color: #efefef;
|
||||||
|
border-bottom: 1px solid #c1c1c1;
|
||||||
|
box-shadow: 0 12px 10px -12px #bbbbbb;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Skip to main content hidden button */
|
||||||
|
.skip-to-main-content {
|
||||||
|
background-color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.jstree-default-dark .jstree-anchor {
|
||||||
|
color: #666666;
|
||||||
|
}
|
||||||
|
|
||||||
|
.jstree-default-dark .jstree-hovered,
|
||||||
|
.jstree-default-dark>.jstree-wholerow-ul .jstree-clicked {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.SearchBarTab {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
button, input[type=submit], input[type=button], .RecordPanel .RecordDownloadSpace .DownloadDBlend a, .UploadButton a {
|
||||||
|
border: 1px solid transparent;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
input[type="submit"]:disabled {
|
||||||
|
color: #666666;
|
||||||
|
background: white;
|
||||||
|
box-shadow: unset;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ToolsOptionLink:link, .ToolsOptionLink:visited {
|
||||||
|
color: #FFF;
|
||||||
|
}
|
||||||
|
|
||||||
|
input[type="text"], input[type="password"], input[type="number"], input[type="email"], textarea, select, .sp-replacer {
|
||||||
|
border: 1px solid rgba(0,0,0,0.25);
|
||||||
|
box-shadow: inset 0 1px 2px 0 rgba(0,0,0,0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
select, .sp-replacer {
|
||||||
|
box-shadow: 0 1px 3px 1px rgba(0,0,0,0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
a.HomePanel:hover {
|
||||||
|
box-shadow: 1px 1px 8px rgba(0, 0, 0, 0.3);
|
||||||
|
}
|
||||||
|
|
||||||
|
.FeaturedSimpleTileImage img.TileGroupImageBase {box-shadow: 0 0 25px #000; }
|
||||||
|
|
||||||
|
#login_box {
|
||||||
|
box-shadow: 0 1px 10px 1px rgba(0,0,0,0.25);
|
||||||
|
}
|
||||||
|
|
||||||
|
.ImageStrip:hover {
|
||||||
|
box-shadow: 0 1px 4px rgba(0,0,0,0.25);
|
||||||
|
}
|
||||||
|
|
||||||
|
#preview, #wmpreview {
|
||||||
|
box-shadow: 0 2px 6px rgba(0,0,0,0.2);
|
||||||
|
}
|
||||||
|
|
||||||
|
#iconpicker-container {
|
||||||
|
width: 418px;
|
||||||
|
height: 285px;
|
||||||
|
left: 318px;
|
||||||
|
background: white;
|
||||||
|
border-radius: 6px;
|
||||||
|
position: absolute;
|
||||||
|
display: none;
|
||||||
|
box-shadow: 0px 3px 5px 1px #0000004a;
|
||||||
|
margin-top: 5px;
|
||||||
|
}
|
||||||
|
.jstree-default-dark .jstree-wholerow-hovered {
|
||||||
|
background: gray;
|
||||||
|
}
|
||||||
|
.jstree-default-dark .jstree-wholerow-clicked {
|
||||||
|
background: #737373;
|
||||||
|
}
|
||||||
|
.CommentEntry { border: 1px solid lightgray; background: white;}
|
||||||
|
|
||||||
|
.BrowseBarRoot {
|
||||||
|
background: rgba(255, 255, 255, 0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
#iconpicker-container {
|
||||||
|
background: white;
|
||||||
|
border: 1px solid rgba(0,0,0,0.25);
|
||||||
|
}
|
||||||
|
|
||||||
|
#SearchBarTabsContainer {
|
||||||
|
background: rgb(0 0 0 / 20%);
|
||||||
|
}
|
||||||
|
|
||||||
|
.MiniCategoryBox {border: 1px solid rgba(0,0,0,0.25);}
|
||||||
|
|
||||||
|
/* Custom styling for jQuery UI dialogs */
|
||||||
|
|
||||||
|
.ui-widget-content {
|
||||||
|
border: 1px solid #e7e7e7;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ui-dialog .ui-dialog-title {
|
||||||
|
background: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ui-dialog {
|
||||||
|
box-shadow: 0 1px 10px 5px rgba(0, 0, 0, 0.1);
|
||||||
|
}
|
||||||
|
|
||||||
|
.ui-dialog .ui-dialog-buttonpane button {
|
||||||
|
background-color: #1679c0;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ui-button, .ui-button:active {
|
||||||
|
border: 1px solid #c5c5c5;
|
||||||
|
}
|
||||||
|
|
||||||
|
.PluginDisplay
|
||||||
|
{
|
||||||
|
background-color: white;
|
||||||
|
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
|
||||||
|
border: 3px solid rgba(255, 255, 255, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
.PluginDisplay .Pill
|
||||||
|
{
|
||||||
|
background-color: #1679c0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tickbox:not(:checked) + label {
|
||||||
|
opacity: 0.5; /* Makes it look disabled */
|
||||||
|
}
|
44
css/responsive/non-touch.css
Executable file
@@ -0,0 +1,44 @@
|
|||||||
|
.ResponsiveButton {
|
||||||
|
height:auto;
|
||||||
|
line-height: 2.5em;
|
||||||
|
}
|
||||||
|
input[type=checkbox] {
|
||||||
|
-ms-transform: scale(1); /* IE */
|
||||||
|
-moz-transform: scale(1); /* FF */
|
||||||
|
-webkit-transform: scale(1); /* Safari and Chrome */
|
||||||
|
-o-transform: scale(1); /* Opera */
|
||||||
|
height:auto;
|
||||||
|
}
|
||||||
|
input[type="submit"], input[type="button"], button {
|
||||||
|
height:auto;
|
||||||
|
padding: 5px;
|
||||||
|
box-shadow: 1px 1px 8px -2px;
|
||||||
|
border:0;
|
||||||
|
margin:5px;
|
||||||
|
}
|
||||||
|
input {
|
||||||
|
display: inline-block;
|
||||||
|
height: auto;
|
||||||
|
}
|
||||||
|
.InpageNavLeftBlock a, .InpageNavLeftBlock span {
|
||||||
|
font-size:1em;
|
||||||
|
}
|
||||||
|
#Header {
|
||||||
|
margin-bottom:5px;
|
||||||
|
}
|
||||||
|
#Header .HorizontalNav ul li a {
|
||||||
|
padding:9px 0;
|
||||||
|
}
|
||||||
|
#SearchBarContainer a {
|
||||||
|
font-size:1em;
|
||||||
|
}
|
||||||
|
#searchspace p {
|
||||||
|
margin: 3px 0;
|
||||||
|
}
|
||||||
|
#FooterThemes img {
|
||||||
|
width:11px;
|
||||||
|
height:11px;
|
||||||
|
}
|
||||||
|
.ResponsiveSimpleSearch .searchbutton {
|
||||||
|
height:auto;
|
||||||
|
}
|
109
css/responsive/slim-non-touch.css
Executable file
@@ -0,0 +1,109 @@
|
|||||||
|
input[type="checkbox"] {
|
||||||
|
-ms-transform: scale(1);
|
||||||
|
-moz-transform: scale(1);
|
||||||
|
-webkit-transform: scale(1);
|
||||||
|
-o-transform: scale(1);
|
||||||
|
height:auto;
|
||||||
|
}
|
||||||
|
input {
|
||||||
|
display: inline-block;
|
||||||
|
height: auto;
|
||||||
|
}
|
||||||
|
.InpageNavLeftBlock a, .InpageNavLeftBlock span {
|
||||||
|
font-size:1em;
|
||||||
|
}
|
||||||
|
#SearchBarContainer a {
|
||||||
|
font-size:1em;
|
||||||
|
}
|
||||||
|
#searchspace p {
|
||||||
|
margin: 3px 0;
|
||||||
|
}
|
||||||
|
#FooterThemes img {
|
||||||
|
width:11px;
|
||||||
|
height:11px;
|
||||||
|
}
|
||||||
|
.ResponsiveSimpleSearch .searchbutton {
|
||||||
|
height:auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width:1200px) {
|
||||||
|
#Header {
|
||||||
|
height:auto;
|
||||||
|
}
|
||||||
|
#HeaderButtons {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
#HeaderNav1 {
|
||||||
|
display:block;
|
||||||
|
clear:none;
|
||||||
|
}
|
||||||
|
#HeaderNav2 {
|
||||||
|
display:block;
|
||||||
|
margin-top:-5px;
|
||||||
|
}
|
||||||
|
#HeaderImg {
|
||||||
|
height:47px;
|
||||||
|
}
|
||||||
|
#Header .HorizontalNav ul li a {
|
||||||
|
display: inline-block;
|
||||||
|
text-align: center;
|
||||||
|
background: none;
|
||||||
|
border: 0;
|
||||||
|
height:auto;
|
||||||
|
line-height: 1em;
|
||||||
|
min-width: initial;
|
||||||
|
padding: 0 5px;
|
||||||
|
margin-bottom: 0;
|
||||||
|
color: #fff;
|
||||||
|
opacity: 0.7;
|
||||||
|
}
|
||||||
|
.HorizontalNav ul {
|
||||||
|
padding: 0 0;
|
||||||
|
}
|
||||||
|
#Header.slimheader_darken a:link, #Header.slimheader_darken a:visited, #Header.slimheader_darken a:active {
|
||||||
|
color: #E1E8F0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media(max-width:1100px) {
|
||||||
|
#Header {
|
||||||
|
min-height: 47px;
|
||||||
|
}
|
||||||
|
#HeaderButtons {
|
||||||
|
display: block!important;
|
||||||
|
}
|
||||||
|
#HeaderNav1 {
|
||||||
|
display:none;
|
||||||
|
clear:both;
|
||||||
|
}
|
||||||
|
#HeaderNav2 {
|
||||||
|
display:none;
|
||||||
|
}
|
||||||
|
#Header .HorizontalNav ul li a {
|
||||||
|
color: #4E4646;
|
||||||
|
display:inline-block;
|
||||||
|
text-align: center;
|
||||||
|
background: #d2d2d2;
|
||||||
|
border: 1px solid white;
|
||||||
|
height: 45px;
|
||||||
|
line-height: 45px;
|
||||||
|
min-width:95px;
|
||||||
|
padding:0 5px;
|
||||||
|
border-radius:6px;
|
||||||
|
margin-bottom:5px;
|
||||||
|
}
|
||||||
|
#Header.slimheader_darken a:link, #Header.slimheader_darken a:visited, #Header.slimheader_darken a:active {
|
||||||
|
color: #565656;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@media(max-width:575px) {
|
||||||
|
#HeaderImg {
|
||||||
|
height:auto;
|
||||||
|
max-height:47px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@media(min-width:1101px) {
|
||||||
|
#HeaderNav1, #HeaderNav2 {
|
||||||
|
display:block !important;
|
||||||
|
}
|
||||||
|
}
|
1202
css/responsive/slim-style.css
Executable file
BIN
css/smoothness/images/ui-bg_flat_0_aaaaaa_40x100.png
Executable file
After Width: | Height: | Size: 251 B |
BIN
css/smoothness/images/ui-bg_flat_75_ffffff_40x100.png
Executable file
After Width: | Height: | Size: 247 B |
BIN
css/smoothness/images/ui-bg_glass_55_fbf9ee_1x400.png
Executable file
After Width: | Height: | Size: 374 B |
BIN
css/smoothness/images/ui-bg_glass_65_ffffff_1x400.png
Executable file
After Width: | Height: | Size: 246 B |
BIN
css/smoothness/images/ui-bg_glass_75_dadada_1x400.png
Executable file
After Width: | Height: | Size: 301 B |
BIN
css/smoothness/images/ui-bg_glass_75_e6e6e6_1x400.png
Executable file
After Width: | Height: | Size: 301 B |
BIN
css/smoothness/images/ui-bg_glass_95_fef1ec_1x400.png
Executable file
After Width: | Height: | Size: 371 B |
BIN
css/smoothness/images/ui-bg_highlight-soft_75_cccccc_1x100.png
Executable file
After Width: | Height: | Size: 319 B |
BIN
css/smoothness/images/ui-icons_222222_256x240.png
Executable file
After Width: | Height: | Size: 6.8 KiB |
BIN
css/smoothness/images/ui-icons_2e83ff_256x240.png
Executable file
After Width: | Height: | Size: 4.5 KiB |
BIN
css/smoothness/images/ui-icons_444444_256x240.png
Normal file
After Width: | Height: | Size: 6.8 KiB |
BIN
css/smoothness/images/ui-icons_454545_256x240.png
Executable file
After Width: | Height: | Size: 6.9 KiB |
BIN
css/smoothness/images/ui-icons_555555_256x240.png
Normal file
After Width: | Height: | Size: 6.9 KiB |
BIN
css/smoothness/images/ui-icons_777620_256x240.png
Normal file
After Width: | Height: | Size: 4.6 KiB |
BIN
css/smoothness/images/ui-icons_777777_256x240.png
Normal file
After Width: | Height: | Size: 6.8 KiB |
BIN
css/smoothness/images/ui-icons_888888_256x240.png
Executable file
After Width: | Height: | Size: 6.9 KiB |
BIN
css/smoothness/images/ui-icons_cc0000_256x240.png
Normal file
After Width: | Height: | Size: 4.5 KiB |
BIN
css/smoothness/images/ui-icons_cd0a0a_256x240.png
Executable file
After Width: | Height: | Size: 4.5 KiB |
BIN
css/smoothness/images/ui-icons_ffffff_256x240.png
Normal file
After Width: | Height: | Size: 6.2 KiB |
1312
css/smoothness/jquery-ui.css
vendored
Executable file
7
css/smoothness/jquery-ui.min.css
vendored
Executable file
4
css/uppy.min.css
vendored
Normal file
1
dbstruct/data_collection.txt
Normal file
@@ -0,0 +1 @@
|
|||||||
|
1,"Default Collection",1,"2008-01-01 10:00:00",0,0,1,,,,,,,,0,,,,0
|
433
dbstruct/data_keyword.txt
Normal file
@@ -0,0 +1,433 @@
|
|||||||
|
1,2,0000,0
|
||||||
|
2,"my collection",M242,0
|
||||||
|
3,"joe smith",J253,0
|
||||||
|
4,my,M000,0
|
||||||
|
5,collection,C423,0
|
||||||
|
6,joe,J000,1
|
||||||
|
7,smith,S530,1
|
||||||
|
8,woman,W550,1
|
||||||
|
9,man,M500,15
|
||||||
|
10,child,C430,1
|
||||||
|
11,building,B435,1
|
||||||
|
12,vehicle,V240,1
|
||||||
|
13,animal,A554,3
|
||||||
|
14,elderly,E436,1
|
||||||
|
15,baby,B100,1
|
||||||
|
16,boy,B000,1
|
||||||
|
17,girl,G640,1
|
||||||
|
18,exhibition,E213,1
|
||||||
|
19,meeting,M352,1
|
||||||
|
20,concert,C526,3
|
||||||
|
21,festival,F231,1
|
||||||
|
22,party,P630,1
|
||||||
|
23,conference,C516,1
|
||||||
|
24,photo,P300,8
|
||||||
|
25,shoot,S300,1
|
||||||
|
26,happy,H100,1
|
||||||
|
27,sad,S300,1
|
||||||
|
28,inspirational,I521,1
|
||||||
|
29,eye,E000,3
|
||||||
|
30,contact,C532,3
|
||||||
|
31,thoughtful,T231,1
|
||||||
|
32,family,F540,1
|
||||||
|
33,group,G610,1
|
||||||
|
34,product,P632,1
|
||||||
|
35,employee,E514,1
|
||||||
|
36,customer,C235,1
|
||||||
|
37,test,T230,2
|
||||||
|
38,"eye contact",E253,2
|
||||||
|
39,2016,0000,2
|
||||||
|
40,2016-06,0000,2
|
||||||
|
41,"2016-06-16 10:56",0000,2
|
||||||
|
42,17,0000,0
|
||||||
|
43,3,0000,0
|
||||||
|
44,"upload 20160616105637",U143,0
|
||||||
|
45,upload,U143,0
|
||||||
|
46,20160616105637,0000,0
|
||||||
|
47,montala,M534,1
|
||||||
|
48,support,S163,1
|
||||||
|
49,1,0000,1
|
||||||
|
50,poster,P236,1
|
||||||
|
51,png,P520,1
|
||||||
|
52,,,0
|
||||||
|
53,fundraising,F536,1
|
||||||
|
54,!last1000,L230,0
|
||||||
|
55,afghanistan,A125,14
|
||||||
|
56,aland,A453,14
|
||||||
|
57,island,I245,386
|
||||||
|
58,albania,A415,14
|
||||||
|
59,algeria,A426,14
|
||||||
|
60,american,A562,14
|
||||||
|
61,samoa,S500,28
|
||||||
|
62,andorra,A536,14
|
||||||
|
63,angola,A524,14
|
||||||
|
64,anguilla,A524,14
|
||||||
|
65,antarctica,A536,14
|
||||||
|
66,antigua,A532,14
|
||||||
|
67,barbuda,B613,14
|
||||||
|
68,argentina,A625,14
|
||||||
|
69,armenia,A655,14
|
||||||
|
70,aruba,A610,14
|
||||||
|
71,australia,A236,14
|
||||||
|
72,austria,A236,14
|
||||||
|
73,azerbaijan,A261,14
|
||||||
|
74,bahama,B500,22
|
||||||
|
75,bahrain,B650,14
|
||||||
|
76,bangladesh,B524,14
|
||||||
|
77,barbado,B613,22
|
||||||
|
78,belaru,B460,22
|
||||||
|
79,belgium,B425,14
|
||||||
|
80,beliz,B420,22
|
||||||
|
81,benin,B550,14
|
||||||
|
82,bermuda,B653,14
|
||||||
|
83,bhutan,B350,14
|
||||||
|
84,bolivia,B410,14
|
||||||
|
85,bosnia,B250,14
|
||||||
|
86,herzegovina,H622,14
|
||||||
|
87,botswana,B325,14
|
||||||
|
88,bouvet,B130,14
|
||||||
|
89,brazil,B624,14
|
||||||
|
90,british,B632,28
|
||||||
|
91,indian,I535,14
|
||||||
|
92,ocean,O250,14
|
||||||
|
93,territori,T636,66
|
||||||
|
94,brunei,B650,14
|
||||||
|
95,darussalam,D624,14
|
||||||
|
96,bulgaria,B426,14
|
||||||
|
97,burkina,B625,14
|
||||||
|
98,faso,F200,14
|
||||||
|
99,burundi,B653,14
|
||||||
|
100,cambodia,C513,14
|
||||||
|
101,cameroon,C565,14
|
||||||
|
102,canada,C530,14
|
||||||
|
103,cape,C100,14
|
||||||
|
104,verd,V630,22
|
||||||
|
105,cayman,C550,14
|
||||||
|
106,central,C536,14
|
||||||
|
107,african,A162,14
|
||||||
|
108,republ,R114,286
|
||||||
|
109,chad,C300,14
|
||||||
|
110,chile,C400,14
|
||||||
|
111,china,C500,28
|
||||||
|
112,christma,C623,22
|
||||||
|
113,coco,C200,22
|
||||||
|
114,keel,K400,22
|
||||||
|
115,colombia,C451,14
|
||||||
|
116,comoro,C560,22
|
||||||
|
117,congo,C520,28
|
||||||
|
118,democrat,D526,66
|
||||||
|
119,cook,C200,14
|
||||||
|
120,costa,C230,14
|
||||||
|
121,rica,R200,14
|
||||||
|
122,côte,C300,14
|
||||||
|
123,d,D000,14
|
||||||
|
124,ivoir,I160,22
|
||||||
|
125,croatia,C630,14
|
||||||
|
126,cuba,C100,14
|
||||||
|
127,cypru,C160,22
|
||||||
|
128,czech,C200,14
|
||||||
|
129,denmark,D562,14
|
||||||
|
130,djibouti,D213,14
|
||||||
|
131,dominica,D552,14
|
||||||
|
132,dominican,D552,14
|
||||||
|
133,ecuador,E236,14
|
||||||
|
134,egypt,E213,14
|
||||||
|
135,el,E400,14
|
||||||
|
136,salvador,S413,14
|
||||||
|
137,equatori,E236,22
|
||||||
|
138,guinea,G500,56
|
||||||
|
139,eritrea,E636,14
|
||||||
|
140,estonia,E235,14
|
||||||
|
141,ethiopia,E310,14
|
||||||
|
142,falkland,F424,14
|
||||||
|
143,malvina,M415,22
|
||||||
|
144,faro,F600,22
|
||||||
|
145,fiji,F200,14
|
||||||
|
146,finland,F545,14
|
||||||
|
147,franc,F652,22
|
||||||
|
148,french,F652,42
|
||||||
|
149,guiana,G500,14
|
||||||
|
150,polynesia,P452,14
|
||||||
|
151,southern,S365,14
|
||||||
|
152,gabon,G150,14
|
||||||
|
153,gambia,G510,14
|
||||||
|
154,georgia,G620,28
|
||||||
|
155,germani,G655,22
|
||||||
|
156,ghana,G500,14
|
||||||
|
157,gibraltar,G164,14
|
||||||
|
158,greec,G620,22
|
||||||
|
159,greenland,G654,14
|
||||||
|
160,grenada,G653,14
|
||||||
|
161,guadeloup,G341,22
|
||||||
|
162,guam,G500,14
|
||||||
|
163,guatemala,G354,14
|
||||||
|
164,guernsei,G652,22
|
||||||
|
165,bissau,B200,14
|
||||||
|
166,guyana,G500,14
|
||||||
|
167,haiti,H300,14
|
||||||
|
168,heard,H630,14
|
||||||
|
169,mcdonald,M235,14
|
||||||
|
170,holi,H400,22
|
||||||
|
171,see,S000,14
|
||||||
|
172,vatican,V325,14
|
||||||
|
173,citi,C300,22
|
||||||
|
174,state,S330,80
|
||||||
|
175,hondura,H536,22
|
||||||
|
176,hong,H520,14
|
||||||
|
177,kong,K520,14
|
||||||
|
178,hungari,H526,22
|
||||||
|
179,iceland,I245,14
|
||||||
|
180,india,I530,14
|
||||||
|
181,indonesia,I535,14
|
||||||
|
182,iran,I650,14
|
||||||
|
183,islam,I245,22
|
||||||
|
184,iraq,I620,14
|
||||||
|
185,ireland,I645,14
|
||||||
|
186,isl,I240,22
|
||||||
|
187,israel,I264,14
|
||||||
|
188,itali,I340,22
|
||||||
|
189,jamaica,J520,14
|
||||||
|
190,japan,J150,14
|
||||||
|
191,jersei,J620,22
|
||||||
|
192,jordan,J635,14
|
||||||
|
193,kazakhstan,K222,14
|
||||||
|
194,kenya,K500,14
|
||||||
|
195,kiribati,K613,14
|
||||||
|
196,korea,K600,28
|
||||||
|
197,peopl,P140,44
|
||||||
|
198,s,S000,42
|
||||||
|
199,kuwait,K300,14
|
||||||
|
200,kyrgyzstan,K622,14
|
||||||
|
201,lao,L000,14
|
||||||
|
202,latvia,L310,14
|
||||||
|
203,lebanon,L155,14
|
||||||
|
204,lesotho,L230,14
|
||||||
|
205,liberia,L160,14
|
||||||
|
206,libyan,L150,14
|
||||||
|
207,arab,A610,42
|
||||||
|
208,jamahiriya,J560,14
|
||||||
|
209,liechtenstein,L235,14
|
||||||
|
210,lithuania,L350,14
|
||||||
|
211,luxembourg,L251,14
|
||||||
|
212,macao,M200,14
|
||||||
|
213,macedonia,M235,14
|
||||||
|
214,former,F656,14
|
||||||
|
215,yugoslav,Y224,14
|
||||||
|
216,madagascar,M322,14
|
||||||
|
217,malawi,M400,14
|
||||||
|
218,malaysia,M420,14
|
||||||
|
219,maldiv,M431,22
|
||||||
|
220,mali,M400,14
|
||||||
|
221,malta,M430,14
|
||||||
|
222,marshal,M624,22
|
||||||
|
223,martiniqu,M635,22
|
||||||
|
224,mauritania,M635,14
|
||||||
|
225,mauritiu,M630,22
|
||||||
|
226,mayott,M300,22
|
||||||
|
227,mexico,M220,14
|
||||||
|
228,micronesia,M265,14
|
||||||
|
229,feder,F360,44
|
||||||
|
230,moldova,M431,14
|
||||||
|
231,monaco,M520,14
|
||||||
|
232,mongolia,M524,14
|
||||||
|
233,montenegro,M535,14
|
||||||
|
234,montserrat,M532,14
|
||||||
|
235,morocco,M620,14
|
||||||
|
236,mozambiqu,M251,22
|
||||||
|
237,myanmar,M560,14
|
||||||
|
238,namibia,N510,14
|
||||||
|
239,nauru,N600,14
|
||||||
|
240,nepal,N140,14
|
||||||
|
241,netherland,N364,44
|
||||||
|
242,antil,A534,22
|
||||||
|
243,new,N000,42
|
||||||
|
244,caledonia,C435,14
|
||||||
|
245,zealand,Z453,14
|
||||||
|
246,nicaragua,N262,14
|
||||||
|
247,niger,N260,14
|
||||||
|
248,nigeria,N260,14
|
||||||
|
249,niue,N000,14
|
||||||
|
250,norfolk,N614,14
|
||||||
|
251,northern,N636,14
|
||||||
|
252,mariana,M650,14
|
||||||
|
253,norwai,N600,22
|
||||||
|
254,oman,O550,14
|
||||||
|
255,pakistan,P223,14
|
||||||
|
256,palau,P400,14
|
||||||
|
257,palestinian,P423,14
|
||||||
|
258,occupi,O210,22
|
||||||
|
259,panama,P550,14
|
||||||
|
260,papua,P100,14
|
||||||
|
261,paraguai,P620,22
|
||||||
|
262,peru,P600,14
|
||||||
|
263,philippin,P415,22
|
||||||
|
264,pitcairn,P326,14
|
||||||
|
265,poland,P453,14
|
||||||
|
266,portug,P632,22
|
||||||
|
267,puerto,P630,14
|
||||||
|
268,rico,R200,14
|
||||||
|
269,qatar,Q360,14
|
||||||
|
270,réunion,R550,14
|
||||||
|
271,romania,R550,14
|
||||||
|
272,russian,R250,14
|
||||||
|
273,rwanda,R530,14
|
||||||
|
274,saint,S530,98
|
||||||
|
275,barthélemi,B634,22
|
||||||
|
276,helena,H450,14
|
||||||
|
277,kitt,K300,22
|
||||||
|
278,nevi,N100,22
|
||||||
|
279,lucia,L200,14
|
||||||
|
280,martin,M635,14
|
||||||
|
281,pierr,P600,22
|
||||||
|
282,miquelon,M245,14
|
||||||
|
283,vincent,V525,14
|
||||||
|
284,grenadin,G653,22
|
||||||
|
285,san,S500,14
|
||||||
|
286,marino,M650,14
|
||||||
|
287,sao,S000,14
|
||||||
|
288,tome,T500,14
|
||||||
|
289,princip,P652,22
|
||||||
|
290,saudi,S300,14
|
||||||
|
291,arabia,A610,14
|
||||||
|
292,seneg,S520,22
|
||||||
|
293,serbia,S610,14
|
||||||
|
294,seychel,S240,22
|
||||||
|
295,sierra,S600,14
|
||||||
|
296,leon,L500,22
|
||||||
|
297,singapor,S521,22
|
||||||
|
298,slovakia,S412,14
|
||||||
|
299,slovenia,S415,14
|
||||||
|
300,solomon,S455,14
|
||||||
|
301,somalia,S540,14
|
||||||
|
302,south,S300,42
|
||||||
|
303,africa,A162,14
|
||||||
|
304,sandwich,S532,14
|
||||||
|
305,spain,S150,14
|
||||||
|
306,sri,S600,14
|
||||||
|
307,lanka,L520,14
|
||||||
|
308,sudan,S350,14
|
||||||
|
309,surinam,S655,22
|
||||||
|
310,svalbard,S141,14
|
||||||
|
311,jan,J500,14
|
||||||
|
312,mayen,M500,14
|
||||||
|
313,swaziland,S245,14
|
||||||
|
314,sweden,S350,14
|
||||||
|
315,switzerland,S326,14
|
||||||
|
316,syrian,S650,14
|
||||||
|
317,taiwan,T500,14
|
||||||
|
318,provinc,P615,22
|
||||||
|
319,tajikistan,T222,14
|
||||||
|
320,tanzania,T525,14
|
||||||
|
321,unit,U530,110
|
||||||
|
322,thailand,T453,14
|
||||||
|
323,timor,T560,14
|
||||||
|
324,lest,L230,22
|
||||||
|
325,togo,T200,14
|
||||||
|
326,tokelau,T240,14
|
||||||
|
327,tonga,T520,14
|
||||||
|
328,trinidad,T653,14
|
||||||
|
329,tobago,T120,14
|
||||||
|
330,tunisia,T520,14
|
||||||
|
331,turkei,T620,22
|
||||||
|
332,turkmenistan,T625,14
|
||||||
|
333,turk,T620,22
|
||||||
|
334,caico,C200,22
|
||||||
|
335,tuvalu,T140,14
|
||||||
|
336,uganda,U253,14
|
||||||
|
337,ukrain,U265,22
|
||||||
|
338,emir,E560,22
|
||||||
|
339,kingdom,K523,14
|
||||||
|
340,minor,M560,14
|
||||||
|
341,outli,O340,22
|
||||||
|
342,uruguai,U620,22
|
||||||
|
343,uzbekistan,U212,14
|
||||||
|
344,vanuatu,V530,14
|
||||||
|
345,venezuela,V524,14
|
||||||
|
346,bolivarian,B416,14
|
||||||
|
347,viet,V300,14
|
||||||
|
348,nam,N500,14
|
||||||
|
349,virgin,V625,28
|
||||||
|
350,u,U000,14
|
||||||
|
351,walli,W400,22
|
||||||
|
352,futuna,F350,14
|
||||||
|
353,western,W236,14
|
||||||
|
354,sahara,S600,14
|
||||||
|
355,yemen,Y550,14
|
||||||
|
356,zambia,Z510,14
|
||||||
|
357,zimbabw,Z511,22
|
||||||
|
358,digit,D230,2
|
||||||
|
359,camera,C560,2
|
||||||
|
360,scan,S500,4
|
||||||
|
361,neg,N200,2
|
||||||
|
362,islands,I245,15
|
||||||
|
363,bahamas,B520,1
|
||||||
|
364,barbados,B613,1
|
||||||
|
365,belarus,B462,1
|
||||||
|
366,belize,B420,1
|
||||||
|
367,territory,T636,2
|
||||||
|
368,verde,V630,1
|
||||||
|
369,republic,R114,13
|
||||||
|
370,christmas,C623,1
|
||||||
|
371,cocos,C220,1
|
||||||
|
372,keeling,K452,1
|
||||||
|
373,comoros,C562,1
|
||||||
|
374,democratic,D526,3
|
||||||
|
375,ivoire,I160,1
|
||||||
|
376,cyprus,C162,1
|
||||||
|
377,equatorial,E236,1
|
||||||
|
378,malvinas,M415,1
|
||||||
|
379,faroe,F600,1
|
||||||
|
380,france,F652,1
|
||||||
|
381,territories,T636,1
|
||||||
|
382,germany,G655,1
|
||||||
|
383,greece,G620,1
|
||||||
|
384,guadeloupe,G341,1
|
||||||
|
385,guernsey,G652,1
|
||||||
|
386,holy,H400,1
|
||||||
|
387,city,C300,1
|
||||||
|
388,honduras,H536,1
|
||||||
|
389,hungary,H526,1
|
||||||
|
390,islamic,I245,1
|
||||||
|
391,isle,I240,1
|
||||||
|
392,italy,I340,1
|
||||||
|
393,jersey,J620,1
|
||||||
|
394,people,P140,2
|
||||||
|
395,maldives,M431,1
|
||||||
|
396,marshall,M624,1
|
||||||
|
397,martinique,M635,1
|
||||||
|
398,mauritius,M632,1
|
||||||
|
399,mayotte,M300,1
|
||||||
|
400,federated,F363,1
|
||||||
|
401,states,S332,3
|
||||||
|
402,mozambique,M251,1
|
||||||
|
403,netherlands,N364,2
|
||||||
|
404,antilles,A534,1
|
||||||
|
405,norway,N600,1
|
||||||
|
406,occupied,O213,1
|
||||||
|
407,paraguay,P620,1
|
||||||
|
408,philippines,P415,1
|
||||||
|
409,portugal,P632,1
|
||||||
|
410,federation,F363,1
|
||||||
|
411,barthélemy,B634,1
|
||||||
|
412,kitts,K320,1
|
||||||
|
413,nevis,N120,1
|
||||||
|
414,pierre,P600,1
|
||||||
|
415,grenadines,G653,1
|
||||||
|
416,principe,P652,1
|
||||||
|
417,senegal,S524,1
|
||||||
|
418,seychelles,S242,1
|
||||||
|
419,leone,L500,1
|
||||||
|
420,singapore,S521,1
|
||||||
|
421,suriname,S655,1
|
||||||
|
422,province,P615,1
|
||||||
|
423,united,U533,5
|
||||||
|
424,leste,L230,1
|
||||||
|
425,turkey,T620,1
|
||||||
|
426,turks,T620,1
|
||||||
|
427,caicos,C220,1
|
||||||
|
428,ukraine,U265,1
|
||||||
|
429,emirates,E563,1
|
||||||
|
430,outlying,O345,1
|
||||||
|
431,uruguay,U620,1
|
||||||
|
432,wallis,W420,1
|
||||||
|
433,zimbabwe,Z511,1
|
277
dbstruct/data_node.txt
Normal file
@@ -0,0 +1,277 @@
|
|||||||
|
1,3,Afghanistan,,10,1
|
||||||
|
2,3,"Aland Islands",,20,1
|
||||||
|
3,3,Albania,,30,1
|
||||||
|
4,3,Algeria,,40,1
|
||||||
|
5,3,"American Samoa",,50,1
|
||||||
|
6,3,Andorra,,60,1
|
||||||
|
7,3,Angola,,70,1
|
||||||
|
8,3,Anguilla,,80,1
|
||||||
|
9,3,Antarctica,,90,1
|
||||||
|
10,3,"Antigua And Barbuda",,100,1
|
||||||
|
11,3,Argentina,,110,1
|
||||||
|
12,3,Armenia,,120,1
|
||||||
|
13,3,Aruba,,130,1
|
||||||
|
14,3,Australia,,140,1
|
||||||
|
15,3,Austria,,150,1
|
||||||
|
16,3,Azerbaijan,,160,1
|
||||||
|
17,3,Bahamas,,170,1
|
||||||
|
18,3,Bahrain,,180,1
|
||||||
|
19,3,Bangladesh,,190,1
|
||||||
|
20,3,Barbados,,200,1
|
||||||
|
21,3,Belarus,,210,1
|
||||||
|
22,3,Belgium,,220,1
|
||||||
|
23,3,Belize,,230,1
|
||||||
|
24,3,Benin,,240,1
|
||||||
|
25,3,Bermuda,,250,1
|
||||||
|
26,3,Bhutan,,260,1
|
||||||
|
27,3,Bolivia,,270,1
|
||||||
|
28,3,"Bosnia And Herzegovina",,280,1
|
||||||
|
29,3,Botswana,,290,1
|
||||||
|
30,3,"Bouvet Island",,300,1
|
||||||
|
31,3,Brazil,,310,1
|
||||||
|
32,3,"British Indian Ocean Territory",,320,1
|
||||||
|
33,3,"Brunei Darussalam",,330,1
|
||||||
|
34,3,Bulgaria,,340,1
|
||||||
|
35,3,"Burkina Faso",,350,1
|
||||||
|
36,3,Burundi,,360,1
|
||||||
|
37,3,Cambodia,,370,1
|
||||||
|
38,3,Cameroon,,380,1
|
||||||
|
39,3,Canada,,390,1
|
||||||
|
40,3,"Cape Verde",,400,1
|
||||||
|
41,3,"Cayman Islands",,410,1
|
||||||
|
42,3,"Central African Republic",,420,1
|
||||||
|
43,3,Chad,,430,1
|
||||||
|
44,3,Chile,,440,1
|
||||||
|
45,3,China,,450,1
|
||||||
|
46,3,"Christmas Island",,460,1
|
||||||
|
47,3,"Cocos (Keeling) Islands",,470,1
|
||||||
|
48,3,Colombia,,480,1
|
||||||
|
49,3,Comoros,,490,1
|
||||||
|
50,3,Congo,,500,1
|
||||||
|
51,3,"Congo - The Democratic Republic Of The",,510,1
|
||||||
|
52,3,"Cook Islands",,520,1
|
||||||
|
53,3,"Costa Rica",,530,1
|
||||||
|
54,3,"Côte D'ivoire",,540,1
|
||||||
|
55,3,Croatia,,550,1
|
||||||
|
56,3,Cuba,,560,1
|
||||||
|
57,3,Cyprus,,570,1
|
||||||
|
58,3,"Czech Republic",,580,1
|
||||||
|
59,3,Denmark,,590,1
|
||||||
|
60,3,Djibouti,,600,1
|
||||||
|
61,3,Dominica,,610,1
|
||||||
|
62,3,"Dominican Republic",,620,1
|
||||||
|
63,3,Ecuador,,630,1
|
||||||
|
64,3,Egypt,,640,1
|
||||||
|
65,3,"El Salvador",,650,1
|
||||||
|
66,3,"Equatorial Guinea",,660,1
|
||||||
|
67,3,Eritrea,,670,1
|
||||||
|
68,3,Estonia,,680,1
|
||||||
|
69,3,Ethiopia,,690,1
|
||||||
|
70,3,"Falkland Islands (Malvinas)",,700,1
|
||||||
|
71,3,"Faroe Islands",,710,1
|
||||||
|
72,3,Fiji,,720,1
|
||||||
|
73,3,Finland,,730,1
|
||||||
|
74,3,France,,740,1
|
||||||
|
75,3,"French Guiana",,750,1
|
||||||
|
76,3,"French Polynesia",,760,1
|
||||||
|
77,3,"French Southern Territories",,770,1
|
||||||
|
78,3,Gabon,,780,1
|
||||||
|
79,3,Gambia,,790,1
|
||||||
|
80,3,Georgia,,800,1
|
||||||
|
81,3,Germany,,810,1
|
||||||
|
82,3,Ghana,,820,1
|
||||||
|
83,3,Gibraltar,,830,1
|
||||||
|
84,3,Greece,,840,1
|
||||||
|
85,3,Greenland,,850,1
|
||||||
|
86,3,Grenada,,860,1
|
||||||
|
87,3,Guadeloupe,,870,1
|
||||||
|
88,3,Guam,,880,1
|
||||||
|
89,3,Guatemala,,890,1
|
||||||
|
90,3,Guernsey,,900,1
|
||||||
|
91,3,Guinea,,910,1
|
||||||
|
92,3,Guinea-Bissau,,920,1
|
||||||
|
93,3,Guyana,,930,1
|
||||||
|
94,3,Haiti,,940,1
|
||||||
|
95,3,"Heard Island And Mcdonald Islands",,950,1
|
||||||
|
96,3,"Holy See (Vatican City State)",,960,1
|
||||||
|
97,3,Honduras,,970,1
|
||||||
|
98,3,"Hong Kong",,980,1
|
||||||
|
99,3,Hungary,,990,1
|
||||||
|
100,3,Iceland,,1000,1
|
||||||
|
101,3,India,,1010,1
|
||||||
|
102,3,Indonesia,,1020,1
|
||||||
|
103,3,"Iran - Islamic Republic Of",,1030,1
|
||||||
|
104,3,Iraq,,1040,1
|
||||||
|
105,3,Ireland,,1050,1
|
||||||
|
106,3,"Isle Of Man",,1060,1
|
||||||
|
107,3,Israel,,1070,1
|
||||||
|
108,3,Italy,,1080,1
|
||||||
|
109,3,Jamaica,,1090,1
|
||||||
|
110,3,Japan,,1100,1
|
||||||
|
111,3,Jersey,,1110,1
|
||||||
|
112,3,Jordan,,1120,1
|
||||||
|
113,3,Kazakhstan,,1130,1
|
||||||
|
114,3,Kenya,,1140,1
|
||||||
|
115,3,Kiribati,,1150,1
|
||||||
|
116,3,"Korea - Democratic People's Republic Of",,1160,1
|
||||||
|
117,3,"Korea - Republic Of",,1170,1
|
||||||
|
118,3,Kuwait,,1180,1
|
||||||
|
119,3,Kyrgyzstan,,1190,1
|
||||||
|
120,3,"Lao People's Democratic Republic",,1200,1
|
||||||
|
121,3,Latvia,,1210,1
|
||||||
|
122,3,Lebanon,,1220,1
|
||||||
|
123,3,Lesotho,,1230,1
|
||||||
|
124,3,Liberia,,1240,1
|
||||||
|
125,3,"Libyan Arab Jamahiriya",,1250,1
|
||||||
|
126,3,Liechtenstein,,1260,1
|
||||||
|
127,3,Lithuania,,1270,1
|
||||||
|
128,3,Luxembourg,,1280,1
|
||||||
|
129,3,Macao,,1290,1
|
||||||
|
130,3,"Macedonia - The Former Yugoslav Republic Of",,1300,1
|
||||||
|
131,3,Madagascar,,1310,1
|
||||||
|
132,3,Malawi,,1320,1
|
||||||
|
133,3,Malaysia,,1330,1
|
||||||
|
134,3,Maldives,,1340,1
|
||||||
|
135,3,Mali,,1350,1
|
||||||
|
136,3,Malta,,1360,1
|
||||||
|
137,3,"Marshall Islands",,1370,1
|
||||||
|
138,3,Martinique,,1380,1
|
||||||
|
139,3,Mauritania,,1390,1
|
||||||
|
140,3,Mauritius,,1400,1
|
||||||
|
141,3,Mayotte,,1410,1
|
||||||
|
142,3,Mexico,,1420,1
|
||||||
|
143,3,"Micronesia - Federated States Of",,1430,1
|
||||||
|
144,3,"Moldova - Republic Of",,1440,1
|
||||||
|
145,3,Monaco,,1450,1
|
||||||
|
146,3,Mongolia,,1460,1
|
||||||
|
147,3,Montenegro,,1470,1
|
||||||
|
148,3,Montserrat,,1480,1
|
||||||
|
149,3,Morocco,,1490,1
|
||||||
|
150,3,Mozambique,,1500,1
|
||||||
|
151,3,Myanmar,,1510,1
|
||||||
|
152,3,Namibia,,1520,1
|
||||||
|
153,3,Nauru,,1530,1
|
||||||
|
154,3,Nepal,,1540,1
|
||||||
|
155,3,Netherlands,,1550,1
|
||||||
|
156,3,"Netherlands Antilles",,1560,1
|
||||||
|
157,3,"New Caledonia",,1570,1
|
||||||
|
158,3,"New Zealand",,1580,1
|
||||||
|
159,3,Nicaragua,,1590,1
|
||||||
|
160,3,Niger,,1600,1
|
||||||
|
161,3,Nigeria,,1610,1
|
||||||
|
162,3,Niue,,1620,1
|
||||||
|
163,3,"Norfolk Island",,1630,1
|
||||||
|
164,3,"Northern Mariana Islands",,1640,1
|
||||||
|
165,3,Norway,,1650,1
|
||||||
|
166,3,Oman,,1660,1
|
||||||
|
167,3,Pakistan,,1670,1
|
||||||
|
168,3,Palau,,1680,1
|
||||||
|
169,3,"Palestinian Territory - Occupied",,1690,1
|
||||||
|
170,3,Panama,,1700,1
|
||||||
|
171,3,"Papua New Guinea",,1710,1
|
||||||
|
172,3,Paraguay,,1720,1
|
||||||
|
173,3,Peru,,1730,1
|
||||||
|
174,3,Philippines,,1740,1
|
||||||
|
175,3,Pitcairn,,1750,1
|
||||||
|
176,3,Poland,,1760,1
|
||||||
|
177,3,Portugal,,1770,1
|
||||||
|
178,3,"Puerto Rico",,1780,1
|
||||||
|
179,3,Qatar,,1790,1
|
||||||
|
180,3,Réunion,,1800,1
|
||||||
|
181,3,Romania,,1810,1
|
||||||
|
182,3,"Russian Federation",,1820,1
|
||||||
|
183,3,Rwanda,,1830,1
|
||||||
|
184,3,"Saint Barthélemy",,1840,1
|
||||||
|
185,3,"Saint Helena",,1850,1
|
||||||
|
186,3,"Saint Kitts And Nevis",,1860,1
|
||||||
|
187,3,"Saint Lucia",,1870,1
|
||||||
|
188,3,"Saint Martin",,1880,1
|
||||||
|
189,3,"Saint Pierre And Miquelon",,1890,1
|
||||||
|
190,3,"Saint Vincent And The Grenadines",,1900,1
|
||||||
|
191,3,Samoa,,1910,1
|
||||||
|
192,3,"San Marino",,1920,1
|
||||||
|
193,3,"Sao Tome And Principe",,1930,1
|
||||||
|
194,3,"Saudi Arabia",,1940,1
|
||||||
|
195,3,Senegal,,1950,1
|
||||||
|
196,3,Serbia,,1960,1
|
||||||
|
197,3,Seychelles,,1970,1
|
||||||
|
198,3,"Sierra Leone",,1980,1
|
||||||
|
199,3,Singapore,,1990,1
|
||||||
|
200,3,Slovakia,,2000,1
|
||||||
|
201,3,Slovenia,,2010,1
|
||||||
|
202,3,"Solomon Islands",,2020,1
|
||||||
|
203,3,Somalia,,2030,1
|
||||||
|
204,3,"South Africa",,2040,1
|
||||||
|
205,3,"South Georgia And The South Sandwich Islands",,2050,1
|
||||||
|
206,3,Spain,,2060,1
|
||||||
|
207,3,"Sri Lanka",,2070,1
|
||||||
|
208,3,Sudan,,2080,1
|
||||||
|
209,3,Suriname,,2090,1
|
||||||
|
210,3,"Svalbard And Jan Mayen",,2100,1
|
||||||
|
211,3,Swaziland,,2110,1
|
||||||
|
212,3,Sweden,,2120,1
|
||||||
|
213,3,Switzerland,,2130,1
|
||||||
|
214,3,"Syrian Arab Republic",,2140,1
|
||||||
|
215,3,"Taiwan - Province Of China",,2150,1
|
||||||
|
216,3,Tajikistan,,2160,1
|
||||||
|
217,3,"Tanzania - United Republic Of",,2170,1
|
||||||
|
218,3,Thailand,,2180,1
|
||||||
|
219,3,Timor-Leste,,2190,1
|
||||||
|
220,3,Togo,,2200,1
|
||||||
|
221,3,Tokelau,,2210,1
|
||||||
|
222,3,Tonga,,2220,1
|
||||||
|
223,3,"Trinidad And Tobago",,2230,1
|
||||||
|
224,3,Tunisia,,2240,1
|
||||||
|
225,3,Turkey,,2250,1
|
||||||
|
226,3,Turkmenistan,,2260,1
|
||||||
|
227,3,"Turks And Caicos Islands",,2270,1
|
||||||
|
228,3,Tuvalu,,2280,1
|
||||||
|
229,3,Uganda,,2290,1
|
||||||
|
230,3,Ukraine,,2300,1
|
||||||
|
231,3,"United Arab Emirates",,2310,1
|
||||||
|
232,3,"United Kingdom",,2320,1
|
||||||
|
233,3,"United States",,2330,1
|
||||||
|
234,3,"United States Minor Outlying Islands",,2340,1
|
||||||
|
235,3,Uruguay,,2350,1
|
||||||
|
236,3,Uzbekistan,,2360,1
|
||||||
|
237,3,Vanuatu,,2370,1
|
||||||
|
238,3,"Venezuela - Bolivarian Republic Of",,2380,1
|
||||||
|
239,3,"Viet Nam",,2390,1
|
||||||
|
240,3,"Virgin Islands - British",,2400,1
|
||||||
|
241,3,"Virgin Islands - U.S.",,2410,1
|
||||||
|
242,3,"Wallis And Futuna",,2420,1
|
||||||
|
243,3,"Western Sahara",,2430,1
|
||||||
|
244,3,Yemen,,2440,1
|
||||||
|
245,3,Zambia,,2450,1
|
||||||
|
246,3,Zimbabwe,,2460,1
|
||||||
|
247,54,"Digital Camera",,20,1
|
||||||
|
248,54,"Scanned Negative",,30,1
|
||||||
|
249,54,"Scanned Photo",,40,1
|
||||||
|
250,73,Woman,,10,1
|
||||||
|
251,73,Man,,20,1
|
||||||
|
252,73,Child,,30,1
|
||||||
|
253,73,Building,,140,1
|
||||||
|
254,73,Vehicle,,130,1
|
||||||
|
255,73,Animal,,80,1
|
||||||
|
256,73,Elderly,,70,1
|
||||||
|
257,73,Baby,,60,1
|
||||||
|
258,73,Boy,,40,1
|
||||||
|
259,73,Girl,,50,1
|
||||||
|
260,74,Exhibition,,10,1
|
||||||
|
261,74,Meeting,,20,1
|
||||||
|
262,74,Concert,,30,1
|
||||||
|
263,74,Festival,,40,1
|
||||||
|
264,74,Party,,50,1
|
||||||
|
265,74,Conference,,60,1
|
||||||
|
266,74,"Photo shoot",,80,1
|
||||||
|
267,75,Happy,,10,1
|
||||||
|
268,75,Sad,,20,1
|
||||||
|
269,75,Inspirational,,30,1
|
||||||
|
270,75,"Eye contact",,40,1
|
||||||
|
271,75,Thoughtful,,50,1
|
||||||
|
272,73,Family,,90,1
|
||||||
|
273,73,Group,,100,1
|
||||||
|
274,73,Product,,150,1
|
||||||
|
275,73,Employee,,110,1
|
||||||
|
276,73,Customer,,120,1
|
||||||
|
277,74,Fundraising,,70,1
|
513
dbstruct/data_node_keyword.txt
Normal file
@@ -0,0 +1,513 @@
|
|||||||
|
250,8,0
|
||||||
|
251,9,0
|
||||||
|
252,10,0
|
||||||
|
253,11,0
|
||||||
|
254,12,0
|
||||||
|
255,13,0
|
||||||
|
256,14,0
|
||||||
|
257,15,0
|
||||||
|
258,16,0
|
||||||
|
259,17,0
|
||||||
|
260,18,0
|
||||||
|
261,19,0
|
||||||
|
262,20,0
|
||||||
|
263,21,0
|
||||||
|
264,22,0
|
||||||
|
265,23,0
|
||||||
|
266,24,0
|
||||||
|
266,25,1
|
||||||
|
267,26,0
|
||||||
|
268,27,0
|
||||||
|
269,28,0
|
||||||
|
270,29,0
|
||||||
|
270,30,1
|
||||||
|
271,31,0
|
||||||
|
272,32,0
|
||||||
|
273,33,0
|
||||||
|
274,34,0
|
||||||
|
275,35,0
|
||||||
|
276,36,0
|
||||||
|
277,53,0
|
||||||
|
1,55,0
|
||||||
|
2,56,0
|
||||||
|
2,362,1
|
||||||
|
2,57,1
|
||||||
|
3,58,0
|
||||||
|
4,59,0
|
||||||
|
5,60,0
|
||||||
|
5,61,1
|
||||||
|
6,62,0
|
||||||
|
7,63,0
|
||||||
|
8,64,0
|
||||||
|
9,65,0
|
||||||
|
10,66,0
|
||||||
|
10,67,2
|
||||||
|
11,68,0
|
||||||
|
12,69,0
|
||||||
|
13,70,0
|
||||||
|
14,71,0
|
||||||
|
15,72,0
|
||||||
|
16,73,0
|
||||||
|
17,363,0
|
||||||
|
17,74,0
|
||||||
|
18,75,0
|
||||||
|
19,76,0
|
||||||
|
20,364,0
|
||||||
|
20,77,0
|
||||||
|
21,365,0
|
||||||
|
21,78,0
|
||||||
|
22,79,0
|
||||||
|
23,366,0
|
||||||
|
23,80,0
|
||||||
|
24,81,0
|
||||||
|
25,82,0
|
||||||
|
26,83,0
|
||||||
|
27,84,0
|
||||||
|
28,85,0
|
||||||
|
28,86,2
|
||||||
|
29,87,0
|
||||||
|
30,88,0
|
||||||
|
30,57,1
|
||||||
|
31,89,0
|
||||||
|
32,90,0
|
||||||
|
32,91,1
|
||||||
|
32,92,2
|
||||||
|
32,367,3
|
||||||
|
32,93,3
|
||||||
|
33,94,0
|
||||||
|
33,95,1
|
||||||
|
34,96,0
|
||||||
|
35,97,0
|
||||||
|
35,98,1
|
||||||
|
36,99,0
|
||||||
|
37,100,0
|
||||||
|
38,101,0
|
||||||
|
39,102,0
|
||||||
|
40,103,0
|
||||||
|
40,368,1
|
||||||
|
40,104,1
|
||||||
|
41,105,0
|
||||||
|
41,362,1
|
||||||
|
41,57,1
|
||||||
|
42,106,0
|
||||||
|
42,107,1
|
||||||
|
42,369,2
|
||||||
|
42,108,2
|
||||||
|
43,109,0
|
||||||
|
44,110,0
|
||||||
|
45,111,0
|
||||||
|
46,370,0
|
||||||
|
46,112,0
|
||||||
|
46,57,1
|
||||||
|
47,371,0
|
||||||
|
47,113,0
|
||||||
|
47,372,1
|
||||||
|
47,114,1
|
||||||
|
47,362,2
|
||||||
|
47,57,2
|
||||||
|
48,115,0
|
||||||
|
49,373,0
|
||||||
|
49,116,0
|
||||||
|
50,117,0
|
||||||
|
51,117,0
|
||||||
|
51,374,2
|
||||||
|
51,118,2
|
||||||
|
51,369,3
|
||||||
|
51,108,3
|
||||||
|
52,119,0
|
||||||
|
52,362,1
|
||||||
|
52,57,1
|
||||||
|
53,120,0
|
||||||
|
53,121,1
|
||||||
|
54,122,0
|
||||||
|
54,123,1
|
||||||
|
54,375,2
|
||||||
|
54,124,2
|
||||||
|
55,125,0
|
||||||
|
56,126,0
|
||||||
|
57,376,0
|
||||||
|
57,127,0
|
||||||
|
58,128,0
|
||||||
|
58,369,1
|
||||||
|
58,108,1
|
||||||
|
59,129,0
|
||||||
|
60,130,0
|
||||||
|
61,131,0
|
||||||
|
62,132,0
|
||||||
|
62,369,1
|
||||||
|
62,108,1
|
||||||
|
63,133,0
|
||||||
|
64,134,0
|
||||||
|
65,135,0
|
||||||
|
65,136,1
|
||||||
|
66,377,0
|
||||||
|
66,137,0
|
||||||
|
66,138,1
|
||||||
|
67,139,0
|
||||||
|
68,140,0
|
||||||
|
69,141,0
|
||||||
|
70,142,0
|
||||||
|
70,362,1
|
||||||
|
70,57,1
|
||||||
|
70,378,2
|
||||||
|
70,143,2
|
||||||
|
71,379,0
|
||||||
|
71,144,0
|
||||||
|
71,362,1
|
||||||
|
71,57,1
|
||||||
|
72,145,0
|
||||||
|
73,146,0
|
||||||
|
74,380,0
|
||||||
|
74,147,0
|
||||||
|
75,148,0
|
||||||
|
75,149,1
|
||||||
|
76,148,0
|
||||||
|
76,150,1
|
||||||
|
77,148,0
|
||||||
|
77,151,1
|
||||||
|
77,381,2
|
||||||
|
77,93,2
|
||||||
|
78,152,0
|
||||||
|
79,153,0
|
||||||
|
80,154,0
|
||||||
|
81,382,0
|
||||||
|
81,155,0
|
||||||
|
82,156,0
|
||||||
|
83,157,0
|
||||||
|
84,383,0
|
||||||
|
84,158,0
|
||||||
|
85,159,0
|
||||||
|
86,160,0
|
||||||
|
87,384,0
|
||||||
|
87,161,0
|
||||||
|
88,162,0
|
||||||
|
89,163,0
|
||||||
|
90,385,0
|
||||||
|
90,164,0
|
||||||
|
91,138,0
|
||||||
|
92,138,0
|
||||||
|
92,165,1
|
||||||
|
93,166,0
|
||||||
|
94,167,0
|
||||||
|
95,168,0
|
||||||
|
95,57,1
|
||||||
|
95,169,3
|
||||||
|
95,362,4
|
||||||
|
95,57,4
|
||||||
|
96,386,0
|
||||||
|
96,170,0
|
||||||
|
96,171,1
|
||||||
|
96,172,2
|
||||||
|
96,387,3
|
||||||
|
96,173,3
|
||||||
|
96,174,4
|
||||||
|
97,388,0
|
||||||
|
97,175,0
|
||||||
|
98,176,0
|
||||||
|
98,177,1
|
||||||
|
99,389,0
|
||||||
|
99,178,0
|
||||||
|
100,179,0
|
||||||
|
101,180,0
|
||||||
|
102,181,0
|
||||||
|
103,182,0
|
||||||
|
103,390,1
|
||||||
|
103,183,1
|
||||||
|
103,369,2
|
||||||
|
103,108,2
|
||||||
|
104,184,0
|
||||||
|
105,185,0
|
||||||
|
106,391,0
|
||||||
|
106,186,0
|
||||||
|
106,9,2
|
||||||
|
107,187,0
|
||||||
|
108,392,0
|
||||||
|
108,188,0
|
||||||
|
109,189,0
|
||||||
|
110,190,0
|
||||||
|
111,393,0
|
||||||
|
111,191,0
|
||||||
|
112,192,0
|
||||||
|
113,193,0
|
||||||
|
114,194,0
|
||||||
|
115,195,0
|
||||||
|
116,196,0
|
||||||
|
116,374,1
|
||||||
|
116,118,1
|
||||||
|
116,394,2
|
||||||
|
116,197,2
|
||||||
|
116,198,3
|
||||||
|
116,369,4
|
||||||
|
116,108,4
|
||||||
|
117,196,0
|
||||||
|
117,369,1
|
||||||
|
117,108,1
|
||||||
|
118,199,0
|
||||||
|
119,200,0
|
||||||
|
120,201,0
|
||||||
|
120,394,1
|
||||||
|
120,197,1
|
||||||
|
120,198,2
|
||||||
|
120,374,3
|
||||||
|
120,118,3
|
||||||
|
120,369,4
|
||||||
|
120,108,4
|
||||||
|
121,202,0
|
||||||
|
122,203,0
|
||||||
|
123,204,0
|
||||||
|
124,205,0
|
||||||
|
125,206,0
|
||||||
|
125,207,1
|
||||||
|
125,208,2
|
||||||
|
126,209,0
|
||||||
|
127,210,0
|
||||||
|
128,211,0
|
||||||
|
129,212,0
|
||||||
|
130,213,0
|
||||||
|
130,214,2
|
||||||
|
130,215,3
|
||||||
|
130,369,4
|
||||||
|
130,108,4
|
||||||
|
131,216,0
|
||||||
|
132,217,0
|
||||||
|
133,218,0
|
||||||
|
134,395,0
|
||||||
|
134,219,0
|
||||||
|
135,220,0
|
||||||
|
136,221,0
|
||||||
|
137,396,0
|
||||||
|
137,222,0
|
||||||
|
137,362,1
|
||||||
|
137,57,1
|
||||||
|
138,397,0
|
||||||
|
138,223,0
|
||||||
|
139,224,0
|
||||||
|
140,398,0
|
||||||
|
140,225,0
|
||||||
|
141,399,0
|
||||||
|
141,226,0
|
||||||
|
142,227,0
|
||||||
|
143,228,0
|
||||||
|
143,400,1
|
||||||
|
143,229,1
|
||||||
|
143,401,2
|
||||||
|
143,174,2
|
||||||
|
144,230,0
|
||||||
|
144,369,1
|
||||||
|
144,108,1
|
||||||
|
145,231,0
|
||||||
|
146,232,0
|
||||||
|
147,233,0
|
||||||
|
148,234,0
|
||||||
|
149,235,0
|
||||||
|
150,402,0
|
||||||
|
150,236,0
|
||||||
|
151,237,0
|
||||||
|
152,238,0
|
||||||
|
153,239,0
|
||||||
|
154,240,0
|
||||||
|
155,403,0
|
||||||
|
155,241,0
|
||||||
|
156,403,0
|
||||||
|
156,241,0
|
||||||
|
156,404,1
|
||||||
|
156,242,1
|
||||||
|
157,243,0
|
||||||
|
157,244,1
|
||||||
|
158,243,0
|
||||||
|
158,245,1
|
||||||
|
159,246,0
|
||||||
|
160,247,0
|
||||||
|
161,248,0
|
||||||
|
162,249,0
|
||||||
|
163,250,0
|
||||||
|
163,57,1
|
||||||
|
164,251,0
|
||||||
|
164,252,1
|
||||||
|
164,362,2
|
||||||
|
164,57,2
|
||||||
|
165,405,0
|
||||||
|
165,253,0
|
||||||
|
166,254,0
|
||||||
|
167,255,0
|
||||||
|
168,256,0
|
||||||
|
169,257,0
|
||||||
|
169,367,1
|
||||||
|
169,93,1
|
||||||
|
169,406,2
|
||||||
|
169,258,2
|
||||||
|
170,259,0
|
||||||
|
171,260,0
|
||||||
|
171,243,1
|
||||||
|
171,138,2
|
||||||
|
172,407,0
|
||||||
|
172,261,0
|
||||||
|
173,262,0
|
||||||
|
174,408,0
|
||||||
|
174,263,0
|
||||||
|
175,264,0
|
||||||
|
176,265,0
|
||||||
|
177,409,0
|
||||||
|
177,266,0
|
||||||
|
178,267,0
|
||||||
|
178,268,1
|
||||||
|
179,269,0
|
||||||
|
180,270,0
|
||||||
|
181,271,0
|
||||||
|
182,272,0
|
||||||
|
182,410,1
|
||||||
|
182,229,1
|
||||||
|
183,273,0
|
||||||
|
184,274,0
|
||||||
|
184,411,1
|
||||||
|
184,275,1
|
||||||
|
185,274,0
|
||||||
|
185,276,1
|
||||||
|
186,274,0
|
||||||
|
186,412,1
|
||||||
|
186,277,1
|
||||||
|
186,413,3
|
||||||
|
186,278,3
|
||||||
|
187,274,0
|
||||||
|
187,279,1
|
||||||
|
188,274,0
|
||||||
|
188,280,1
|
||||||
|
189,274,0
|
||||||
|
189,414,1
|
||||||
|
189,281,1
|
||||||
|
189,282,3
|
||||||
|
190,274,0
|
||||||
|
190,283,1
|
||||||
|
190,415,4
|
||||||
|
190,284,4
|
||||||
|
191,61,0
|
||||||
|
192,285,0
|
||||||
|
192,286,1
|
||||||
|
193,287,0
|
||||||
|
193,288,1
|
||||||
|
193,416,3
|
||||||
|
193,289,3
|
||||||
|
194,290,0
|
||||||
|
194,291,1
|
||||||
|
195,417,0
|
||||||
|
195,292,0
|
||||||
|
196,293,0
|
||||||
|
197,418,0
|
||||||
|
197,294,0
|
||||||
|
198,295,0
|
||||||
|
198,419,1
|
||||||
|
198,296,1
|
||||||
|
199,420,0
|
||||||
|
199,297,0
|
||||||
|
200,298,0
|
||||||
|
201,299,0
|
||||||
|
202,300,0
|
||||||
|
202,362,1
|
||||||
|
202,57,1
|
||||||
|
203,301,0
|
||||||
|
204,302,0
|
||||||
|
204,303,1
|
||||||
|
205,302,0
|
||||||
|
205,154,1
|
||||||
|
205,302,4
|
||||||
|
205,304,5
|
||||||
|
205,362,6
|
||||||
|
205,57,6
|
||||||
|
206,305,0
|
||||||
|
207,306,0
|
||||||
|
207,307,1
|
||||||
|
208,308,0
|
||||||
|
209,421,0
|
||||||
|
209,309,0
|
||||||
|
210,310,0
|
||||||
|
210,311,2
|
||||||
|
210,312,3
|
||||||
|
211,313,0
|
||||||
|
212,314,0
|
||||||
|
213,315,0
|
||||||
|
214,316,0
|
||||||
|
214,207,1
|
||||||
|
214,369,2
|
||||||
|
214,108,2
|
||||||
|
215,317,0
|
||||||
|
215,422,1
|
||||||
|
215,318,1
|
||||||
|
215,111,3
|
||||||
|
216,319,0
|
||||||
|
217,320,0
|
||||||
|
217,423,1
|
||||||
|
217,321,1
|
||||||
|
217,369,2
|
||||||
|
217,108,2
|
||||||
|
218,322,0
|
||||||
|
219,323,0
|
||||||
|
219,424,1
|
||||||
|
219,324,1
|
||||||
|
220,325,0
|
||||||
|
221,326,0
|
||||||
|
222,327,0
|
||||||
|
223,328,0
|
||||||
|
223,329,2
|
||||||
|
224,330,0
|
||||||
|
225,425,0
|
||||||
|
225,331,0
|
||||||
|
226,332,0
|
||||||
|
227,426,0
|
||||||
|
227,333,0
|
||||||
|
227,427,2
|
||||||
|
227,334,2
|
||||||
|
227,362,3
|
||||||
|
227,57,3
|
||||||
|
228,335,0
|
||||||
|
229,336,0
|
||||||
|
230,428,0
|
||||||
|
230,337,0
|
||||||
|
231,423,0
|
||||||
|
231,321,0
|
||||||
|
231,207,1
|
||||||
|
231,429,2
|
||||||
|
231,338,2
|
||||||
|
232,423,0
|
||||||
|
232,321,0
|
||||||
|
232,339,1
|
||||||
|
233,423,0
|
||||||
|
233,321,0
|
||||||
|
233,401,1
|
||||||
|
233,174,1
|
||||||
|
234,423,0
|
||||||
|
234,321,0
|
||||||
|
234,401,1
|
||||||
|
234,174,1
|
||||||
|
234,340,2
|
||||||
|
234,430,3
|
||||||
|
234,341,3
|
||||||
|
234,362,4
|
||||||
|
234,57,4
|
||||||
|
235,431,0
|
||||||
|
235,342,0
|
||||||
|
236,343,0
|
||||||
|
237,344,0
|
||||||
|
238,345,0
|
||||||
|
238,346,1
|
||||||
|
238,369,2
|
||||||
|
238,108,2
|
||||||
|
239,347,0
|
||||||
|
239,348,1
|
||||||
|
240,349,0
|
||||||
|
240,362,1
|
||||||
|
240,57,1
|
||||||
|
240,90,2
|
||||||
|
241,349,0
|
||||||
|
241,362,1
|
||||||
|
241,57,1
|
||||||
|
241,350,2
|
||||||
|
241,198,3
|
||||||
|
242,432,0
|
||||||
|
242,351,0
|
||||||
|
242,352,2
|
||||||
|
243,353,0
|
||||||
|
243,354,1
|
||||||
|
244,355,0
|
||||||
|
245,356,0
|
||||||
|
246,433,0
|
||||||
|
246,357,0
|
6
dbstruct/data_preview_size.txt
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
1,thm,200,200,0,Thumbnail,1,0,0,0
|
||||||
|
2,pre,900,540,0,Preview,1,0,1,0
|
||||||
|
3,scr,1400,800,0,Screen,0,1,0,0
|
||||||
|
4,lpr,2000,2000,0,"Low resolution print",0,0,0,0
|
||||||
|
5,hpr,999999,999999,0,"High resolution print",0,0,0,0
|
||||||
|
6,col,100,75,0,Collection,1,0,0,0
|
439
dbstruct/data_report.txt
Normal file
@@ -0,0 +1,439 @@
|
|||||||
|
1,"Values used in resource edits","SELECT
|
||||||
|
TRIM( RIGHT ( diff, LENGTH ( diff ) - LOCATE ( '\n+', diff ) - 2 ) ) AS `Value`,
|
||||||
|
count(*) AS `Count`
|
||||||
|
FROM resource_log WHERE type = 'e'
|
||||||
|
|
||||||
|
# --- date ranges
|
||||||
|
# Make sure date is greater than FROM date
|
||||||
|
and date > DATE('[from-y]-[from-m]-[from-d]')
|
||||||
|
# Make sure date is less than TO date
|
||||||
|
and date > DATE('[to-y]-[to-m]-[to-d]')
|
||||||
|
|
||||||
|
group by 1 order by 2 desc limit 5000;
|
||||||
|
",0
|
||||||
|
2,"Keywords used in searches","select k.keyword 'Keyword',sum(count) Searches from keyword k,daily_stat d where k.ref=d.object_ref and d.activity_type='Keyword usage'
|
||||||
|
|
||||||
|
# --- date ranges
|
||||||
|
# Make sure date is greater than FROM date
|
||||||
|
and
|
||||||
|
(
|
||||||
|
d.year>[from-y]
|
||||||
|
or
|
||||||
|
(d.year=[from-y] and d.month>[from-m])
|
||||||
|
or
|
||||||
|
(d.year=[from-y] and d.month=[from-m] and d.day>=[from-d])
|
||||||
|
)
|
||||||
|
# Make sure date is less than TO date
|
||||||
|
and
|
||||||
|
(
|
||||||
|
d.year<[to-y]
|
||||||
|
or
|
||||||
|
(d.year=[to-y] and d.month<[to-m])
|
||||||
|
or
|
||||||
|
(d.year=[to-y] and d.month=[to-m] and d.day<=[to-d])
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
group by k.ref order by Searches desc
|
||||||
|
",0
|
||||||
|
3,"Resource download summary","
|
||||||
|
select r.ref 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = r.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) AS 'Title',
|
||||||
|
count(*) Downloads
|
||||||
|
from resource_log rl
|
||||||
|
join resource r on rl.resource=r.ref
|
||||||
|
where rl.type='d'
|
||||||
|
and rl.date>=date('[from-y]-[from-m]-[from-d]') and rl.date<=adddate(date('[to-y]-[to-m]-[to-d]'),1)
|
||||||
|
group by r.ref order by 'Downloads' desc
|
||||||
|
",0
|
||||||
|
4,"Resource views","
|
||||||
|
select r.ref 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = r.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) 'Title',sum(count) Views from resource r,daily_stat d where r.ref=d.object_ref and d.activity_type='Resource view'
|
||||||
|
|
||||||
|
# --- date ranges
|
||||||
|
# Make sure date is greater than FROM date
|
||||||
|
and
|
||||||
|
(
|
||||||
|
d.year>[from-y]
|
||||||
|
or
|
||||||
|
(d.year=[from-y] and d.month>[from-m])
|
||||||
|
or
|
||||||
|
(d.year=[from-y] and d.month=[from-m] and d.day>=[from-d])
|
||||||
|
)
|
||||||
|
# Make sure date is less than TO date
|
||||||
|
and
|
||||||
|
(
|
||||||
|
d.year<[to-y]
|
||||||
|
or
|
||||||
|
(d.year=[to-y] and d.month<[to-m])
|
||||||
|
or
|
||||||
|
(d.year=[to-y] and d.month=[to-m] and d.day<=[to-d])
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
group by r.ref order by Views desc;
|
||||||
|
",0
|
||||||
|
5,"Resources sent via e-mail","
|
||||||
|
select r.ref 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = r.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) 'Title',sum(count) Sent from resource r,daily_stat d where r.ref=d.object_ref and d.activity_type='E-mailed resource'
|
||||||
|
|
||||||
|
# --- date ranges
|
||||||
|
# Make sure date is greater than FROM date
|
||||||
|
and
|
||||||
|
(
|
||||||
|
d.year>[from-y]
|
||||||
|
or
|
||||||
|
(d.year=[from-y] and d.month>[from-m])
|
||||||
|
or
|
||||||
|
(d.year=[from-y] and d.month=[from-m] and d.day>=[from-d])
|
||||||
|
)
|
||||||
|
# Make sure date is less than TO date
|
||||||
|
and
|
||||||
|
(
|
||||||
|
d.year<[to-y]
|
||||||
|
or
|
||||||
|
(d.year=[to-y] and d.month<[to-m])
|
||||||
|
or
|
||||||
|
(d.year=[to-y] and d.month=[to-m] and d.day<=[to-d])
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
group by r.ref order by Sent desc;
|
||||||
|
",0
|
||||||
|
6,"Resources added to collection","
|
||||||
|
select cl.resource 'Resource',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = cl.resource AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) 'Title',
|
||||||
|
count(*) 'Collection Add Count'
|
||||||
|
from collection_log cl
|
||||||
|
where BINARY cl.type='a'
|
||||||
|
and cl.date>=date('[from-y]-[from-m]-[from-d]')
|
||||||
|
and cl.date<=adddate(date('[to-y]-[to-m]-[to-d]'),1)
|
||||||
|
group by resource
|
||||||
|
order by resource;
|
||||||
|
",0
|
||||||
|
7,"Resources created","
|
||||||
|
|
||||||
|
select
|
||||||
|
rl.date 'Date / Time',
|
||||||
|
concat(u.username,' (',u.fullname,' )') 'Created By User',
|
||||||
|
g.name 'User Group',
|
||||||
|
r.ref 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = r.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) 'Resource Title'
|
||||||
|
|
||||||
|
from
|
||||||
|
resource_log rl
|
||||||
|
join resource r on r.ref=rl.resource
|
||||||
|
left outer join user u on rl.user=u.ref
|
||||||
|
left outer join usergroup g on u.usergroup=g.ref
|
||||||
|
where
|
||||||
|
rl.type='c'
|
||||||
|
and
|
||||||
|
rl.date>=date('[from-y]-[from-m]-[from-d]') and rl.date<=adddate(date('[to-y]-[to-m]-[to-d]'),1)
|
||||||
|
order by rl.date
|
||||||
|
",0
|
||||||
|
8,"Resources with zero downloads","
|
||||||
|
select ref 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = resource.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) 'Title' from resource where ref > 0 and ref not in
|
||||||
|
|
||||||
|
(
|
||||||
|
select object_ref from daily_stat
|
||||||
|
WHERE activity_type='Resource download'
|
||||||
|
AND
|
||||||
|
(
|
||||||
|
year>[from-y]
|
||||||
|
or
|
||||||
|
(year=[from-y] and month>[from-m])
|
||||||
|
or
|
||||||
|
(year=[from-y] and month=[from-m] and day>=[from-d])
|
||||||
|
)
|
||||||
|
AND
|
||||||
|
(
|
||||||
|
year<[to-y]
|
||||||
|
or
|
||||||
|
(year=[to-y] and month<[to-m])
|
||||||
|
or
|
||||||
|
(year=[to-y] and month=[to-m] and day<=[to-d])
|
||||||
|
)
|
||||||
|
group by object_ref
|
||||||
|
)
|
||||||
|
|
||||||
|
AND
|
||||||
|
DATE_FORMAT(creation_date, '%Y-%m-%d')<=date('[to-y]-[to-m]-[to-d]')
|
||||||
|
|
||||||
|
AND
|
||||||
|
ref>0
|
||||||
|
",0
|
||||||
|
9,"Resources with zero views","
|
||||||
|
select ref 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = resource.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) 'Title' from resource where ref not in
|
||||||
|
|
||||||
|
(
|
||||||
|
SELECT object_ref FROM daily_stat d
|
||||||
|
|
||||||
|
WHERE d.activity_type='Resource view'
|
||||||
|
|
||||||
|
AND
|
||||||
|
(
|
||||||
|
year>[from-y]
|
||||||
|
or
|
||||||
|
(year=[from-y] and month>[from-m])
|
||||||
|
or
|
||||||
|
(year=[from-y] and month=[from-m] and day>=[from-d])
|
||||||
|
)
|
||||||
|
|
||||||
|
AND
|
||||||
|
(
|
||||||
|
year<[to-y]
|
||||||
|
or
|
||||||
|
(year=[to-y] and month<[to-m])
|
||||||
|
or
|
||||||
|
(year=[to-y] and month=[to-m] and day<=[to-d])
|
||||||
|
)
|
||||||
|
|
||||||
|
group by object_ref
|
||||||
|
)
|
||||||
|
|
||||||
|
AND
|
||||||
|
DATE_FORMAT(creation_date, '%Y-%m-%d')<=date('[to-y]-[to-m]-[to-d]')
|
||||||
|
|
||||||
|
AND
|
||||||
|
ref>0
|
||||||
|
",0
|
||||||
|
10,"Resource downloads by group","
|
||||||
|
select
|
||||||
|
g.name 'Group Name',
|
||||||
|
count(rl.resource) 'Resource Downloads'
|
||||||
|
|
||||||
|
from
|
||||||
|
resource_log rl
|
||||||
|
join resource r on r.ref=rl.resource
|
||||||
|
left outer join user u on rl.user=u.ref
|
||||||
|
left outer join usergroup g on u.usergroup=g.ref
|
||||||
|
where
|
||||||
|
rl.type='d'
|
||||||
|
and rl.date>=date('[from-y]-[from-m]-[from-d]') and rl.date<=adddate(date('[to-y]-[to-m]-[to-d]'),1)
|
||||||
|
group by g.ref order by 'Resource Downloads' desc
|
||||||
|
",0
|
||||||
|
11,"Resource download detail","
|
||||||
|
select
|
||||||
|
rl.date 'Date / Time',
|
||||||
|
concat(u.username,' (',u.fullname,' )') 'Downloaded By User',
|
||||||
|
g.name 'User Group',
|
||||||
|
r.ref 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = r.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) 'Resource Title',
|
||||||
|
rt.name 'Resource Type'
|
||||||
|
|
||||||
|
from
|
||||||
|
resource_log rl
|
||||||
|
join resource r on r.ref=rl.resource
|
||||||
|
left outer join user u on rl.user=u.ref
|
||||||
|
left outer join usergroup g on u.usergroup=g.ref
|
||||||
|
left outer join resource_type rt on r.resource_type=rt.ref
|
||||||
|
where
|
||||||
|
rl.type='d'
|
||||||
|
and
|
||||||
|
rl.date>=date('[from-y]-[from-m]-[from-d]') and rl.date<=adddate(date('[to-y]-[to-m]-[to-d]'),1)
|
||||||
|
order by rl.date
|
||||||
|
",0
|
||||||
|
12,"User details including group allocation","select
|
||||||
|
u.username 'Username',
|
||||||
|
u.email 'E-mail address',
|
||||||
|
u.fullname 'Full Name',
|
||||||
|
u.created 'Created',
|
||||||
|
u.last_active 'Last Seen',
|
||||||
|
g.name 'Group name'
|
||||||
|
|
||||||
|
from user u join usergroup g on u.usergroup=g.ref
|
||||||
|
|
||||||
|
order by username;
|
||||||
|
",0
|
||||||
|
13,"Expired Resources","
|
||||||
|
select distinct resource.ref 'Resource ID',resource.field8 'Resource Title',node.name 'Expires'
|
||||||
|
from resource
|
||||||
|
join resource_node on resource.ref=resource_node.resource
|
||||||
|
join node on node.ref=resource_node.node
|
||||||
|
join resource_type_field on node.resource_type_field=resource_type_field.ref
|
||||||
|
where resource_type_field.type=6 and node.name>=date('[from-y]-[from-m]-[from-d]') and node.name<=adddate(date('[to-y]-[to-m]-[to-d]'),1) and length(node.name)>0 and resource.ref>0 order by resource.ref;
|
||||||
|
",0
|
||||||
|
14,"Resources created - with thumbnails","
|
||||||
|
select
|
||||||
|
r.ref 'thumbnail',
|
||||||
|
rl.date 'Date / Time',
|
||||||
|
concat(u.username,' (',u.fullname,' )') 'Created By User',
|
||||||
|
g.name 'User Group',
|
||||||
|
r.ref 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = r.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) 'Resource Title'
|
||||||
|
|
||||||
|
from
|
||||||
|
resource_log rl
|
||||||
|
join resource r on r.ref=rl.resource
|
||||||
|
left outer join user u on rl.user=u.ref
|
||||||
|
left outer join usergroup g on u.usergroup=g.ref
|
||||||
|
where
|
||||||
|
rl.type='c'
|
||||||
|
and
|
||||||
|
rl.date>=date('[from-y]-[from-m]-[from-d]') and rl.date<=adddate(date('[to-y]-[to-m]-[to-d]'),1)
|
||||||
|
order by rl.date;
|
||||||
|
",0
|
||||||
|
16,"Database statistics","
|
||||||
|
|
||||||
|
select
|
||||||
|
(select count(*) from resource) as 'Total resources',
|
||||||
|
(select count(*) from keyword) 'Total keywords',
|
||||||
|
(select count(*) from node) as 'Total nodes (field options)',
|
||||||
|
(select count(*) from resource_node) as 'Resource - node (field option) relationships',
|
||||||
|
(select count(*) from collection) as 'Total collections',
|
||||||
|
(select count(*) from collection_resource) as 'Collection resource relationships',
|
||||||
|
(select count(*) from user) as 'Total users';
|
||||||
|
",0
|
||||||
|
17,"Mail Log","
|
||||||
|
SELECT
|
||||||
|
ml.ref,
|
||||||
|
date,
|
||||||
|
mail_to 'TO',
|
||||||
|
IFNULL(u.username, 'SYSTEM') 'FROM',
|
||||||
|
subject,
|
||||||
|
sender_email
|
||||||
|
FROM mail_log ml
|
||||||
|
LEFT JOIN user u ON u.ref=ml.mail_from
|
||||||
|
WHERE
|
||||||
|
date>=date('[from-y]-[from-m]-[from-d]') and
|
||||||
|
date<=adddate(date('[to-y]-[to-m]-[to-d]'),1)
|
||||||
|
ORDER BY ml.ref DESC
|
||||||
|
",0
|
||||||
|
18,"Resource comments","
|
||||||
|
SELECT c.ref 'Ref', c.created 'Date', c.resource_ref 'Resource ID', c.resource_ref 'thumbnail', c.body 'Comment',
|
||||||
|
ifnull(concat(u.username,' (',u.fullname,')'),concat('ANONYMOUS: ',c.fullname,' (',c.website_url,')')) 'User', ifnull(c.email,u.email) Email
|
||||||
|
|
||||||
|
FROM comment c LEFT JOIN user u ON u.ref=c.user_ref
|
||||||
|
|
||||||
|
WHERE
|
||||||
|
|
||||||
|
c.created>=date('[from-y]-[from-m]-[from-d]') and c.created<=adddate(date('[to-y]-[to-m]-[to-d]'),1)
|
||||||
|
order by c.created DESC;",0
|
||||||
|
19,"File integrity check report","
|
||||||
|
SELECT * FROM
|
||||||
|
(SELECT 'Oldest' AS State, ref 'Resource', ifnull(last_verified,'NEVER') 'Verified' FROM resource WHERE ref>0 AND integrity_fail=0 ORDER BY last_verified ASC LIMIT 1) AS a
|
||||||
|
UNION ALL
|
||||||
|
SELECT * FROM
|
||||||
|
(SELECT 'Newest' AS State, ref 'Resource', ifnull(last_verified,'NEVER') 'Verified' FROM resource WHERE ref>0 AND integrity_fail=0 ORDER BY last_verified DESC LIMIT 1) AS b;",0
|
||||||
|
20,"Request details","
|
||||||
|
SELECT
|
||||||
|
cres.resource 'Resource ID',
|
||||||
|
typ.name 'Resource Type',
|
||||||
|
usreq.username 'User',
|
||||||
|
req.comments 'Comments',
|
||||||
|
req.created 'Date requested',
|
||||||
|
req.reasonapproved 'Reason approved',
|
||||||
|
CASE
|
||||||
|
WHEN req.status = 0 THEN 'Pending'
|
||||||
|
WHEN req.status = 1 THEN 'Approved'
|
||||||
|
WHEN req.status = 2 THEN 'Declined'
|
||||||
|
ELSE 'UNDEFINED'
|
||||||
|
END 'Outcome',
|
||||||
|
usapp.username 'Approved / Declined by'
|
||||||
|
|
||||||
|
FROM request req
|
||||||
|
|
||||||
|
JOIN collection_resource cres ON req.collection=cres.collection
|
||||||
|
|
||||||
|
JOIN resource res ON cres.resource = res.ref
|
||||||
|
|
||||||
|
JOIN resource_type typ ON res.resource_type = typ.ref
|
||||||
|
|
||||||
|
JOIN user usreq ON req.user = usreq.ref
|
||||||
|
|
||||||
|
LEFT OUTER JOIN user usapp ON req.approved_declined_by = usapp.ref
|
||||||
|
|
||||||
|
WHERE req.created>=date('[from-y]-[from-m]-[from-d]') AND req.created<=adddate(date('[to-y]-[to-m]-[to-d]'),1)
|
||||||
|
|
||||||
|
ORDER BY req.created desc;",0
|
||||||
|
21,"Searches with no results", "
|
||||||
|
SELECT logged, `user`, search_string, resource_types, archive_states, result_count
|
||||||
|
FROM search_log AS sl
|
||||||
|
WHERE sl.result_count = 0
|
||||||
|
AND sl.logged >= date('[from-y]-[from-m]-[from-d]')
|
||||||
|
AND sl.logged <= adddate(date('[to-y]-[to-m]-[to-d]'), 1)
|
||||||
|
ORDER BY ref DESC;",0
|
||||||
|
22,"Resource download detail (search results)","
|
||||||
|
SELECT rl.date AS 'Date / Time',
|
||||||
|
concat(u.username,' (',u.fullname,' )') AS 'Downloaded By User',
|
||||||
|
g.name AS 'User Group',
|
||||||
|
r.ref AS 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = r.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) AS 'Resource Title',
|
||||||
|
rt.name AS 'Resource Type'
|
||||||
|
|
||||||
|
FROM resource_log rl
|
||||||
|
JOIN resource r ON r.ref = rl.resource
|
||||||
|
LEFT OUTER JOIN user u ON rl.user = u.ref
|
||||||
|
LEFT OUTER JOIN usergroup g ON u.usergroup = g.ref
|
||||||
|
LEFT OUTER JOIN resource_type rt ON r.resource_type = rt.ref
|
||||||
|
|
||||||
|
WHERE rl.type = 'd'
|
||||||
|
AND rl.date >= date('[from-y]-[from-m]-[from-d]') AND rl.date <= adddate(date('[to-y]-[to-m]-[to-d]'), 1)
|
||||||
|
AND r.ref IN [non_correlated_sql]
|
||||||
|
ORDER BY rl.date;",1
|
||||||
|
23,"Resource download summary (search results)","
|
||||||
|
SELECT r.ref AS 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = r.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) AS 'Title',
|
||||||
|
count(*) AS 'Downloads'
|
||||||
|
FROM resource_log rl
|
||||||
|
JOIN resource r on rl.resource = r.ref
|
||||||
|
WHERE rl.type = 'd'
|
||||||
|
AND rl.date >= date('[from-y]-[from-m]-[from-d]') AND rl.date <= adddate(date('[to-y]-[to-m]-[to-d]'), 1)
|
||||||
|
AND r.ref IN [non_correlated_sql]
|
||||||
|
GROUP BY r.ref
|
||||||
|
ORDER BY 'Downloads' DESC;",1
|
||||||
|
24,"Resources created - with thumbnails (search results)","
|
||||||
|
SELECT r.ref AS 'thumbnail',
|
||||||
|
rl.date AS 'Date / Time',
|
||||||
|
concat(u.username,' (',u.fullname,' )') AS 'Created By User',
|
||||||
|
g.name AS 'User Group',
|
||||||
|
r.ref AS 'Resource ID',
|
||||||
|
( SELECT n.name
|
||||||
|
FROM resource_node rn, node n
|
||||||
|
WHERE rn.resource = r.ref AND n.ref = rn.node and n.resource_type_field = [title_field]
|
||||||
|
LIMIT 1 ) AS 'Resource Title'
|
||||||
|
|
||||||
|
FROM resource_log AS rl
|
||||||
|
JOIN resource AS r ON r.ref = rl.resource
|
||||||
|
LEFT OUTER JOIN user AS u ON rl.user = u.ref
|
||||||
|
LEFT OUTER JOIN usergroup AS g ON u.usergroup = g.ref
|
||||||
|
|
||||||
|
WHERE rl.type = 'c'
|
||||||
|
AND rl.date >= date('[from-y]-[from-m]-[from-d]') AND rl.date <= adddate(date('[to-y]-[to-m]-[to-d]'), 1)
|
||||||
|
AND r.ref IN [non_correlated_sql]
|
||||||
|
ORDER BY rl.date;",1
|
4
dbstruct/data_resource_type.txt
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
1,Photo,,,,,,fas fa-image,,
|
||||||
|
2,Document,,,,,,fas fa-file-alt,,
|
||||||
|
3,Video,,,,,,fas fa-video,,
|
||||||
|
4,Audio,,,,,,fas fa-music,,
|
43
dbstruct/data_resource_type_field.txt
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
1,keywords,Keywords - Other,,9,60,1,0,1,,1,2#025,,0,,"IPTC:Keywords,Subject,XMP:Keywords",1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
3,country,Country,,9,80,1,0,1,country,1,2#101,,0,,"IPTC:Country-PrimaryLocationName,XMP:Country",1,0,,0,1,,0,0,,,,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
8,title,Title,,0,10,1,0,1,title,0,2#005,,1,,"IPTC:ObjectName,XMP:title",1,0,,0,1,,0,0,,,,,,,,,,,,1,1,1,1,0,0,0,
|
||||||
|
9,extract,Document extract,,1,7,0,0,0,,1,,"<div class=""RecordStory"">
|
||||||
|
<h1>[title]</h1>
|
||||||
|
|
||||||
|
<p>[value]</p>
|
||||||
|
|
||||||
|
</div>",0,,,1,0,,0,1,,0,0,,,,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
10,credit,Credit,,0,120,1,0,1,,1,2#080,,0,,"IPTC:Credit,XMP:Credit",1,0,,0,1,,0,0,,,,,,,,,,,,1,1,1,1,0,0,0,
|
||||||
|
12,date,Date,,4,90,1,0,1,creation_date,1,2#055,,0,,"DateTimeOriginal,IPTC:DateCreated,XMP:DateCreated",0,0,,0,1,,0,0,"if ($value!=''){$value=nicedate($value,false);}",,,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
18,caption,Caption,,1,20,1,0,1,,1,2#120,"<div class=""item""><h3>[title]</h3><p>[value]</p></div>
|
||||||
|
|
||||||
|
<div class=""clearerleft""> </div>",0,,"IPTC:Caption-Abstract,XMP:Description",1,0,,0,1,,0,0,,,,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
25,notes,Notes,,1,130,0,0,1,,1,2#103,"<div class=""RecordStory"">
|
||||||
|
|
||||||
|
<h1>[title]</h1>
|
||||||
|
|
||||||
|
<p>[value]</p>
|
||||||
|
|
||||||
|
</div>",0,,JobID,1,0,,0,1,,0,0,,,,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
29,person,Named person(s),,9,70,1,0,1,,1,,,0,,"XMP:PersonInImage,XMP:People",1,0,,0,1,,0,0,,,,,,,,,,,,1,1,1,1,0,0,0,
|
||||||
|
51,originalfilename,Original filename,,0,100,1,0,1,file_path,1,,,0,,,1,0,,0,1,,1,0,,,,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
52,camera,Camera make / model,,0,1600,0,0,0,,1,,,0,,Model,1,0,,0,1,,1,0,,,,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
54,source,Source,,3,1601,0,0,0,,1,,,0,,XMP:FileSource,1,0,,0,1,,0,0,,,,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
72,text,Extracted text,,5,110,0,0,1,,0,,"<div class=""item""><h3>[title]</h3><p>[value]</p></div><div class=""clearerleft""> </div>",0,,,1,0,,0,1,,1,0,,,,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
73,subject,Keywords - Subject,,2,30,1,0,1,,1,,,0,,,1,0,,0,1,,0,0,,,0,,,,,,,,,1,1,1,1,0,0,0,
|
||||||
|
74,event,Keywords - Event,,2,50,1,0,1,,1,,,0,,,1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
75,emotion,Keywords - Emotion,,2,40,1,0,1,,1,,,0,,,1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
76,framerate,Frame Rate,,0,0,1,0,0,,1,,,0,,framerate,1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
77,videobitrate,Video Bitrate,,0,0,1,0,0,,1,,,0,,videobitrate,1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
78,aspectratio,Aspect Ratio,,0,0,1,0,0,,1,,,0,,aspectratio,1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
79,videosize,Video Size,,0,0,0,0,0,,1,,,0,,imagesize,1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
80,duration,Duration,,0,0,0,0,0,,1,,,0,,duration,1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
81,channelmode,Channel Mode,,0,0,1,0,0,,1,,,0,,channelmode,1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
82,samplerate,Sample Rate,,0,0,0,0,0,,1,,,0,,samplerate,1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
83,audiobitrate,Audio Bitrate,,0,0,1,0,0,,1,,,0,,audiobitrate,1,0,,0,1,,0,0,,,0,,,,,,,,,0,1,1,1,0,0,0,
|
||||||
|
84,recognised,Keywords - Recognised,0,9,0,1,0,0,,1,,,0,,,1,0,,0,1,,0,0,,,0,,,,,,,0,,0,1,1,1,0,0,0,
|
||||||
|
85,landmark,Keywords - Landmark,0,9,0,1,0,0,,1,,,0,,,1,0,,0,1,,0,0,,,0,,,,,,,0,,0,1,1,1,0,0,0,
|
||||||
|
86,accessibilityalttext,Accessibility - Alt Text,0,0,0,0,0,0,,1,,,0,,AltTextAccessibility,1,0,"Enter text describing the appearance of the image from a visual perspective, focusing on details that are relevant to the purpose and meaning of the image.
|
||||||
|
|
||||||
|
A maximum of 250 characters can be entered.",0,1,,0,0,,,0,,"^.{0,250}$",,,,,0,,0,1,1,1,0,0,0,
|
||||||
|
87,accessibilityextend,Accessibility - Extended Description,,1,0,0,0,0,,1,,,0,,ExtDescrAccessibility,1,0,"Enter the text describing the appearance of an image from a visual perspective, focusing on relevant details that further describe the meaning and purpose of the image.",0,1,,0,0,,,0,,,,,,,0,,0,1,1,1,0,0,0,
|
15
dbstruct/data_resource_type_field_resource_type.txt
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
9,2
|
||||||
|
52,1
|
||||||
|
54,1
|
||||||
|
76,3
|
||||||
|
77,3
|
||||||
|
78,3
|
||||||
|
79,3
|
||||||
|
80,4
|
||||||
|
81,4
|
||||||
|
82,4
|
||||||
|
83,4
|
||||||
|
84,1
|
||||||
|
85,1
|
||||||
|
86,1
|
||||||
|
87,1
|
1
dbstruct/data_tab.txt
Executable file
@@ -0,0 +1 @@
|
|||||||
|
1,Default,10
|
1
dbstruct/data_user_collection.txt
Normal file
@@ -0,0 +1 @@
|
|||||||
|
1,1,0
|
6
dbstruct/data_usergroup.txt
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
1,Administrators,"s,g,c,t,h,r,u,i,e-2,e-1,e0,e1,e3,v,o,m,q,f*,j*,k,R,Ra,Rb,x,hdta,lm,cm",0,,,,,,,,1,0,,,,,,,,
|
||||||
|
2,"General Users","s,e-1,e-2,g,d,q,f*,j*,z1,z2,z3",0,,,,,,,,1,1,,,,,,,,
|
||||||
|
3,"Super Admin","s,g,c,a,t,h,hdt_ug,u,r,i,e-2,e-1,e0,e1,e2,e3,o,m,g,v,q,f*,j*,k,R,Ra,x,ex",0,,,,,,,,1,0,,,,,,,,
|
||||||
|
4,Archivists,"s,g,c,t,h,r,u,i,e1,e2,e3,v,q,f*,j*",0,,,,,,,,1,0,,,,,,,,
|
||||||
|
5,"Restricted User - Requests Emailed (manual fulfilment)","s,f*,j*,q,dtu,z1,z2,z3",0,,,,,,,,0,0,,,,,,,,
|
||||||
|
6,"Restricted User - Requests Managed","s,f*,j*,q,dtu,z1,z2,z3",0,,,,,,,,1,0,,,,,,,,
|
12
dbstruct/help_activity_log.txt
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
A log of all user activity across the system.
|
||||||
|
ref,int(11),
|
||||||
|
logged,datetime,The date and time of the activity
|
||||||
|
user,int(11),
|
||||||
|
log_code,char(1),A single character code defining the activity type
|
||||||
|
note,text,Further information relating to the activity
|
||||||
|
value_old,text,If the activity involved a change - the old value
|
||||||
|
value_new,text,If the activity involved a change - the new value
|
||||||
|
value_diff,text,The difference between the old and new values
|
||||||
|
remote_table,varchar(100),The table the activity related to
|
||||||
|
remote_column,varchar(100),The column the activity related to
|
||||||
|
remote_ref,varchar(100),The row the activity related to
|
10
dbstruct/help_annotation.txt
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
Resource annotations.
|
||||||
|
ref,int(11),
|
||||||
|
resource,int(11),
|
||||||
|
resource_type_field,int(11),
|
||||||
|
user,int(11),
|
||||||
|
x,decimal(17),The coordinates of the annotation.
|
||||||
|
y,decimal(17),The coordinates of the annotation.
|
||||||
|
width,decimal(17),The dimensions of the annotation.
|
||||||
|
height,decimal(17),The dimensions of the annotation.
|
||||||
|
page,int(11),For mult-page resources - the page of the annotation.
|
3
dbstruct/help_annotation_node.txt
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
A join table connecting resource annotations to keyword nodes for annotating resources with fixed list metadata.
|
||||||
|
annotation,int(11),
|
||||||
|
node,int(11),
|
23
dbstruct/help_collection.txt
Normal file
@@ -0,0 +1,23 @@
|
|||||||
|
Collections are groups of resources.
|
||||||
|
ref,int(11),
|
||||||
|
name,varchar(100),The collection display name.
|
||||||
|
user,int(11),User ID
|
||||||
|
created,datetime,
|
||||||
|
public,int(11),Set to '1' for public collections and featured collections (deprecated - use type instead).
|
||||||
|
theme,varchar(100),The first level theme category. Defined for multi-level featured collections.
|
||||||
|
theme2,varchar(100),The second level theme category. Defined for multi-level featured collections.
|
||||||
|
theme3,varchar(100),The third level theme category. Defined for multi-level featured collections.
|
||||||
|
allow_changes,int(11),
|
||||||
|
cant_delete,int(11), Prevent collection from being deleted (used for e.g. user 'New uploads' collections)
|
||||||
|
keywords,text,Optional keywords entered by the user and indexed for collection searching.
|
||||||
|
savedsearch,int(11),
|
||||||
|
home_page_publish,int(11),(legacy) used if $home_dash=false
|
||||||
|
home_page_text,text,(legacy) used if $home_dash=false
|
||||||
|
home_page_image,int(11),(legacy) used if $home_dash=false
|
||||||
|
session_id,int(11),Used for anonymous access with collections enabled - the session ID cookie used by the anonymous user, as a single user is used for all accesses.
|
||||||
|
description,text,Textual description.
|
||||||
|
type,int(11),Collection type such as Public / Featured / Upload / Select (see include/definition.php)
|
||||||
|
parent,int(11),The parent collection for collections existing within a tree structure such as Featured Collections.
|
||||||
|
thumbnail_selection_method,int(11),How do we select the thumbnails to show on the tile for this collection?
|
||||||
|
bg_img_resource_ref,int(11),The resource ID of the preview image.
|
||||||
|
order_by,int(11),YES,,0,The order by of the collection. Used only by Featured Collections at the moment.
|
3
dbstruct/help_collection_keyword.txt
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
A join table connecting collections with keywords, for indexing of collections to enable rapid collection searching.
|
||||||
|
collection,int(11),
|
||||||
|
keyword,int(11),
|
8
dbstruct/help_collection_log.txt
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
A log of all activity relating to a collection.
|
||||||
|
ref,int(11),
|
||||||
|
date,datetime,
|
||||||
|
user,int(11),
|
||||||
|
collection,int(11),
|
||||||
|
type,char(1),Activity type - see include/definitions.php
|
||||||
|
resource,int(11),
|
||||||
|
notes,varchar(255),Notes
|
8
dbstruct/help_collection_resource.txt
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
Defines the contents of a collection.
|
||||||
|
collection,int(11),
|
||||||
|
resource,int(11),
|
||||||
|
date_added,timestamp,Date resource added to collection
|
||||||
|
comment,text,Used if $collection_commenting=true
|
||||||
|
rating,int(11),Used if $collection_commenting=true
|
||||||
|
use_as_theme_thumbnail,int(11),(boolean) Use resource as featured collection thumbnail image (if manual selection is set for collection)
|
||||||
|
sortorder,int(11),Sort order
|
9
dbstruct/help_collection_savedsearch.txt
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
A list of saved searches which can exist within collections.
|
||||||
|
ref,int(11),
|
||||||
|
collection,int(11),
|
||||||
|
search,text,The search string
|
||||||
|
restypes,text,The resource types used when searching
|
||||||
|
starsearch,int(11),
|
||||||
|
archive,varchar(50),Workflow states (comma separated)
|
||||||
|
created,timestamp,Date created
|
||||||
|
result_limit,int(11),Maximum number of results to return
|
12
dbstruct/help_comment.txt
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
Resource comments.
|
||||||
|
ref,int(11),
|
||||||
|
ref_parent,int(11),Parent comment reference
|
||||||
|
created,timestamp,
|
||||||
|
hide,int(1),(boolean) Hide comment?
|
||||||
|
collection_ref,int(11),
|
||||||
|
resource_ref,int(11),
|
||||||
|
user_ref,int(11),
|
||||||
|
fullname,varchar(100),External commenter's full name (anonymous access)
|
||||||
|
email,varchar(100),Commenter's email (anonymous access)
|
||||||
|
website_url,text,Commenter's website link (anonymous access)
|
||||||
|
body,text,Comment text
|
9
dbstruct/help_daily_stat.txt
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
Daily statistics, grouped by day, usergroup and activity type, for easy summaries used by analytics.
|
||||||
|
year,int(11),Year the activity took place
|
||||||
|
month,int(11),Month the activity took place
|
||||||
|
day,int(11),Day the activity took place
|
||||||
|
usergroup,int(11),
|
||||||
|
activity_type,varchar(50),The activity type code
|
||||||
|
object_ref,int(11),The ID of the table in question, such as the resource ID in the case of a resource activity
|
||||||
|
count,int(11),How many times this activity was carried out on the object in the day in question by any user
|
||||||
|
external,tinyint(1),Did this activity happen via an external share?
|
11
dbstruct/help_dash_tile.txt
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
Dash tiles, displayed on the home page.
|
||||||
|
ref,int(11),
|
||||||
|
title,varchar(255),Title text
|
||||||
|
txt,text,Tile text
|
||||||
|
all_users,int(1),(boolean) Is tile published to all users?
|
||||||
|
default_order_by,int(11),Default order
|
||||||
|
url,text,Anchor link href URL
|
||||||
|
link,text,Link text
|
||||||
|
reload_interval_secs,int(11),
|
||||||
|
resource_count,int(1),Number of resources (if search/collection tile)
|
||||||
|
allow_delete,int(1),(boolean) Can tile be deleted?
|
14
dbstruct/help_external_access_keys.txt
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
When externally sharing there will be one row here for each resource shared.
|
||||||
|
resource,int(11),
|
||||||
|
access_key,char(10),External access key
|
||||||
|
user,int(11),
|
||||||
|
usergroup,int(11),
|
||||||
|
collection,int(11),
|
||||||
|
request_feedback,int(11),(boolean) When emailing external contacts, allow recipients to select resources and add feedback when accessing share
|
||||||
|
email,varchar(100),Email address share was created for
|
||||||
|
date,datetime,Date share created
|
||||||
|
lastused,datetime,Date share was last accessed
|
||||||
|
access,int(11),Access level 0 = open, 1 = restricted
|
||||||
|
expires,datetime,Share expiration date
|
||||||
|
password_hash,varchar(100),Hash of share password (NULL if not set)
|
||||||
|
upload,int(11),Set to 0 for standard external view access share, 1 for an external upload share for a collection
|
4
dbstruct/help_filter.txt
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
Filter definition. Used for search, edit and derestrict filters on usergroups
|
||||||
|
ref,int(11),
|
||||||
|
name,varchar(200),Name of filter
|
||||||
|
filter_condition,int(11),Defines which rules must be met to satisfy the filter (RS_FILTER_ALL|RS_FILTER_NONE|RS_FILTER_ANY)
|
3
dbstruct/help_filter_rule.txt
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
Defines the rules that make up a filter.
|
||||||
|
ref,int(11),
|
||||||
|
filter,int(11),
|
4
dbstruct/help_filter_rule_node.txt
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
Defines the nodes and conditions that make up a filter rule.
|
||||||
|
filter_rule,int(11),
|
||||||
|
node_condition,int(11),(boolean) Whether the given node is required to be present or absent to satisfy the rule
|
||||||
|
node,int(11),
|
4
dbstruct/help_ip_lockout.txt
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
IP address lockout - for denying access after a number of invalid login attempts.
|
||||||
|
ip,varchar(40),Client IP address
|
||||||
|
tries,int(11),Number of login attempts
|
||||||
|
last_try,datetime,Time and date of last attempt
|
11
dbstruct/help_job_queue.txt
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
The job queue - a list of active offline jobs such as preview processing.
|
||||||
|
ref,int(11),
|
||||||
|
type,varchar(100),Job type e.g. collection_download that matches the name of handler files in include/job_handlers. Custom types can be created by plugins if they also include a handler
|
||||||
|
job_data,mediumtext,JSON encoded job data
|
||||||
|
start_date,datetime,Earliest time to start the job
|
||||||
|
user,int(11),
|
||||||
|
status,int(11),Job status code e.g. STATUS_COMPLETE. See definitions.php
|
||||||
|
success_text,varchar(250),Text to include in message if job completes successfully
|
||||||
|
failure_text,varchar(250),Text to include in message if job fails
|
||||||
|
job_code,varchar(100),Unique hash. Used to prevent duplicate jobs
|
||||||
|
priority,tinyint(1),Job priority. Lower numbers are higher priority. Refer to definitions.php and Knowledge Base for more information
|
5
dbstruct/help_keyword.txt
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
A list of keywords used when indexing. With stemming enabled (the default) the stems are stored as well as the full keywords.
|
||||||
|
ref,int(11),
|
||||||
|
keyword,varchar(100),An individual word, used for indexing/searching. When stemming is enabled the word stems are also stored in this table as keywords.
|
||||||
|
soundex,varchar(50),A <a href='https://en.wikipedia.org/wiki/Soundex'>Soundex</a> representation of the keyword, used when suggesting searches after zero results - it can show keywords that sound similar and help correct typos.
|
||||||
|
hit_count,int(11),How many times this keyword has been used within resource metadata. Used to sort keywords when suggesting alternatives to the user.
|
3
dbstruct/help_keyword_related.txt
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
Defines related keywords. When a keyword is searched for, related keywords are also searched for.
|
||||||
|
keyword,int(11),
|
||||||
|
related,int(11),The ID of the related keyword.
|
7
dbstruct/help_mail_log.txt
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
A log storing all e-mails sent, mainly for diagnosis purposes.
|
||||||
|
ref,int(11),
|
||||||
|
date,datetime,Date and time the e-mail was sent.
|
||||||
|
mail_to,varchar(100),Recipient's e-mail address.
|
||||||
|
mail_from,int(11),User ID of the sending user.
|
||||||
|
subject,varchar(150),E-mail subject.
|
||||||
|
sender_email,varchar(200),E-mail address of the sending user.
|
10
dbstruct/help_message.txt
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
User messages. Use for system and user to user messaging
|
||||||
|
ref,int(11),
|
||||||
|
created,DATETIME,
|
||||||
|
owner,int(11),User reference
|
||||||
|
message,MEDIUMTEXT,Message text
|
||||||
|
url,text,Message URL. Appears as link with message and in message list.
|
||||||
|
expires,DATETIME,Message expiration date
|
||||||
|
related_activity,int(11),Used with related_ref to link system generated messages to e.g. a user account request so that all related messages can be deleted once account is approved
|
||||||
|
related_ref,int(11),Related activity reference e.g. user ref
|
||||||
|
type,int(11),Denotes various types of message e.g. user message, screen. Defined by the enabled bits. Refer to definitions.php for more information
|
7
dbstruct/help_node.txt
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
Node keyword list (fixed metadata). Used for the fixed list types such as drop down boxes and category trees.
|
||||||
|
ref,int(11),
|
||||||
|
resource_type_field,int(11),Which metadata field this belongs to.
|
||||||
|
name,mediumtext,The display name.
|
||||||
|
parent,int(11),For category trees - defines node hierarchy.
|
||||||
|
order_by,int(11),Defines the order of the nodes for display purposes.
|
||||||
|
active,tinyint(1),Flag node as active (1) or deactivated (0).
|
4
dbstruct/help_node_keyword.txt
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
Keyword nodes are indexed - broken down into single word keywords.
|
||||||
|
node,int(11),
|
||||||
|
keyword,int(11),
|
||||||
|
position,int(11),The position within the node string, e.g. node "red cat", keyword "cat" would be in the second position. Used for quoted searching.
|
15
dbstruct/help_plugins.txt
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
Lists all plugins active on the system and stores plugin configuration.
|
||||||
|
name,varchar(50),The folder name containing the plugin
|
||||||
|
descrip,text,A textual description of the plugin loaded from the .yaml file
|
||||||
|
author,varchar(100),The author of the plugin, loaded from the .yaml file
|
||||||
|
update_url,varchar(100),Loaded from the .yaml file
|
||||||
|
info_url,varchar(100),The URL of the plugin's project page for more information. Loaded from the .yaml file
|
||||||
|
inst_version,float,The installed version number. Loaded from the .yaml file
|
||||||
|
config,longblob,Serialised plugin configuration data
|
||||||
|
config_json,mediumtext,JSON encoded configuration data
|
||||||
|
config_url,varchar(100),Plugin configuration URL. Loaded from the .yaml file
|
||||||
|
enabled_groups,varchar(200),Comma separated list of group refs. Used if disable_group_select=0 to enable plugin for specified groups
|
||||||
|
priority,int(11),Defines the order that plugin hooks will be called. Plugins with higher priority numbers will be called later. Loaded from the .yaml file
|
||||||
|
disable_group_select,int(11),Prevent plugin from being enabled only for certain groups. Loaded from the .yaml file
|
||||||
|
title,varchar(100),A 'friendly' title to display as the plugin name instead of the folder name used in 'name'. Loaded from the .yaml file
|
||||||
|
icon,varchar(100),A FontAwesome icon string to display in the UI. Loaded from the .yaml file
|
11
dbstruct/help_preview_size.txt
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
Defines preview sizes used for resource preview and thumbnail generation.
|
||||||
|
ref,int(11),
|
||||||
|
id,char(3),Short code e.g. 'scr', 'lpr'
|
||||||
|
width,int(11),Width in pixels
|
||||||
|
height,int(11),Height in pixels
|
||||||
|
padtosize,int(11),(boolean) Add padding to make image required size. If set to 0 the image will be scaled to fit within the defined dimensions
|
||||||
|
name,varchar(50),Friendly name
|
||||||
|
internal,int(11),(boolean) For system use. Prevents deletion.
|
||||||
|
allow_preview,int(11),(boolean) Show a link to preview this size on the resource view page?
|
||||||
|
allow_restricted,int(11),(boolean) Allow users with restricted access to see this preview size
|
||||||
|
quality,int(3),JPEG quality
|
5
dbstruct/help_report.txt
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
Reports as listed in the admin area.
|
||||||
|
ref,int(11),
|
||||||
|
name,varchar(100),Report name.
|
||||||
|
query,text,SQL defining the report.
|
||||||
|
support_non_correlated_sql,tinyint(1),Can this report run on search results? 1 - yes, 0 - no.
|