Collections functions
Encryption functions
General functions
Theme permission functions
Resource functions

delete_dash_tile()

Parameters

ColumnTypeDefaultDescription
$tile
$cascade TRUE
$force FALSE

Location

include/dash_functions.php lines 156 to 167

Definition

 
function delete_dash_tile($tile,$cascade=TRUE,$force=FALSE)
    {
    
#Force Delete ignores the allow_delete flag (This allows removal of config tiles)
    
$allow_delete $force"":"AND allow_delete=1";
    
sql_query("DELETE FROM dash_tile WHERE ref='".$tile."' ".$allow_delete);
    if(
$cascade)
        {
        
sql_query("DELETE FROM user_dash_tile WHERE dash_tile='".$tile."'");
        
sql_query("DELETE FROM usergroup_dash_tile WHERE dash_tile = '{$tile}'");
        }
    
hook('after_delete_dash_tile''', array($tile$cascade $force));
    }

This article was last updated 10th July 2020 23:35 Europe/London time based on the source file dated 24th June 2020 14:38 Europe/London time.