Collections functions
General functions
Render functions
Theme permission functions
Resource functions

can_delete_collection()

Description

Check if user has the appropriate access to delete a collection.

Parameters

ColumnTypeDefaultDescription
$collection_data array Array of collection details, typically from get_collection()
$userref int Id of user
$k int "" External access key value

Return

boolean Returns true is the collection can be deleted or false if it cannot.

Location

include/collections_functions.php lines 6659 to 6669

Definition

 
function can_delete_collection($collection_data$userref$k "")
    {
    if(!(
$k == '' && (($userref == $collection_data['user']) || checkperm('h')) && $collection_data['cant_delete'] == 0))
        {
        return 
false;
        }
    else
        {
        return 
true;
        }
    }

This article was last updated 26th September 2022 13:05 Europe/London time based on the source file dated 22nd September 2022 11:00 Europe/London time.