Collections functions
General functions
Render functions
Theme permission functions
Resource functions

add_user_dash_tile()

Parameters

ColumnTypeDefaultDescription
$user
$tile
$order_by
$reorder TRUE

Location

include/dash_functions.php lines 935 to 948

Definition

 
function add_user_dash_tile($user,$tile,$order_by,$reorder=TRUE)
    {
    if(!
is_numeric($user)||!is_numeric($tile)){return false;}
    if(!
is_numeric($order_by))
        {
        
$order_by=append_user_position($user);
        
$reorder=FALSE;
        }
        
    
ps_query("INSERT INTO user_dash_tile (user,dash_tile,order_by) VALUES (?, ?, ?)  ON DUPLICATE KEY UPDATE order_by= ?", ['i'$user'i'$tile'i'$order_by'i'$order_by]);
        
    if(
$reorder){reorder_user_dash($user);}
    return 
true;
    }

This article was last updated 30th September 2022 16:35 Europe/London time based on the source file dated 27th September 2022 15:05 Europe/London time.