0) { $addarray = explode(",", $add); } else { $addarray[0] = $add; unset($add); } // If collection has been shared externally need to check access and permissions $externalkeys = get_collection_external_access(($to_collection === '') ? $usercollection : $to_collection); if (count($externalkeys) > 0) { if (checkperm("noex")) { $allowadd = false; } else { foreach ($addarray as $add) { $resaccess = get_resource_access($add); // Not permitted if share is open and access is restricted if (min(array_column($externalkeys, "access")) < $resaccess) { $allowadd = false; } } } if (!$allowadd) { ?> 1) { $allowadd = false; } } } if ($allowadd) { foreach ($addarray as $add) { #add to current collection if ( $usercollection == -$userref || $to_collection == -$userref || !add_resource_to_collection($add, ($to_collection === '') ? $usercollection : $to_collection, false, getval("size", "")) ) { ?> 0) { $removearray = explode(",", $remove); } else { $removearray[0] = $remove; unset($remove); } foreach ($removearray as $remove) { #remove from current collection if (!remove_resource_from_collection($remove, ($from_collection === '') ? $usercollection : $from_collection)) { ?> 0) { // If collection has been shared externally users with this permission can't add resources ?>
"; $blocked_types = get_resource_types(implode(",", $resourcesnotadded["blockedtypes"])); foreach ($blocked_types as $blocked_type) { if ($warningtext == "") { $warningtext .= ""; unset($resourcesnotadded["blockedtypes"]); } if (!empty($resourcesnotadded)) { // There are resources blocked from being added due to archive state if ($warningtext == "") { $warningtext .= "

"; } $warningtext .= $lang["notapprovedresources"] . implode(", ", $resourcesnotadded); } ?>




0 && count($result) > 0 && $min_access == 0 ) { if ($terms_download) { if ($download_usage) { $download_url = generateURL( $baseurl_short . '/pages/terms.php', [ 'k' => $k, 'collection' => $usercollection, 'url' => generateURL($baseurl_short . 'pages/download_usage.php', ['collection' => $usercollection, 'k' => $k]) ] ); } else { $download_url = generateURL( $baseurl_short . '/pages/terms.php', [ 'k' => $k, 'collection' => $usercollection, 'url' => generateURL($baseurl_short . 'pages/collection_download.php', ['collection' => $usercollection, 'k' => $k]) ] ); } } elseif ($download_usage) { $download_url = generateURL($baseurl_short . 'pages/download_usage.php', ['collection' => $usercollection, 'k' => $k]); } else { $download_url = generateURL($baseurl_short . 'pages/collection_download.php', ['collection' => $usercollection, 'k' => $k]); } ?>



0 && checkperm("q") && $min_access != 0 # Ability to request a whole collection (only if user has restricted access to any of these resources) ) { ?>

:

0) { # Loop through resources for thumbnails for standard display for ($n = 0; $n < count($result) && $n < $count_result && $n < $max_collection_thumbs; $n++) { if (!isset($result[$n]) || !is_array($result[$n])) { # $result can be a list of suggested searches, in this case do not process this item. continue; } $ref = $result[$n]["ref"]; $resource_view_title = i18n_get_translated($result[$n]["field" . $view_title_field]); ?>
style="display:none;" > $ref, "search" => "!collection" . $usercollection, "order_by" => $order_by, "sort" => $sort, "k" => $k, "curpos" => $n, ]); ?>
" alt="" onload="this.width/=2;this.onload=null;" />
$ref, "search" => "!collection" . $usercollection, "k" => $k ]); ?>
" >  
$ref, "collection" => $usercollection, "k" => $k, ]); ?>
$ref, "search" => '!collection' . $usercollection, "order_by" => $order_by, "sort" => $sort, "offset" => $offset, "archive" => $archive, "k" => $k, "curpos" => $n, "restypes" => $restypes, ] ); # Include standard search views include "search_views/resource_tools.php"; } # End of remove link condition ?>
$max_collection_thumbs) { ?> 0 && $addarray[0] != "") { # Animate the new item ?>

0 && count($result) > 0) { if ($terms_download) { if ($download_usage) { $download_url = generateURL( $baseurl_short . '/pages/terms.php', [ 'k' => $k, 'collection' => $usercollection, 'url' => generateURL($baseurl_short . 'pages/download_usage.php', ['collection' => $usercollection, 'k' => $k]) ] ); } else { $download_url = generateURL( $baseurl_short . '/pages/terms.php', [ 'k' => $k, 'collection' => $usercollection, 'url' => generateURL($baseurl_short . 'pages/collection_download.php', ['collection' => $usercollection, 'k' => $k]) ] ); } } elseif ($download_usage) { $download_url = generateURL($baseurl_short . 'pages/download_usage.php', ['collection' => $usercollection, 'k' => $k]); } else { $download_url = generateURL($baseurl_short . 'pages/collection_download.php', ['collection' => $usercollection, 'k' => $k]); } ?>
  • 0) { # Ability to request a whole collection (only if user has restricted access to any of these resources) $min_access = collection_min_access($result); if ($min_access != 0) { ?>
  •