Collections functions
General functions
Render functions
Theme permission functions
Resource functions

save_alternative_file()

Parameters

ColumnTypeDefaultDescription
$resource
$ref

Location

include/resource_functions.php lines 4907 to 4915

Definition

 
function save_alternative_file($resource,$ref)
    {
    
# Saves the 'alternative file' edit form back to the database
    
$name           getval("name","");
    
$description    getval("description","");
    
$alt_type       getval("alt_type","");
    
ps_query("UPDATE resource_alt_files SET name = ?,description = ?,alt_type = ? WHERE resource = ? AND ref = ?",
    array(
"s",$name,"s",$description,"s",$alt_type,"i",$resource,"i",$ref));
    }

This article was last updated 5th February 2023 06:35 Europe/London time based on the source file dated 3rd February 2023 13:55 Europe/London time.