Collections functions
Encryption functions
General functions
Theme permission functions
Resource functions

addAnnotationNodes()

Description

Add relations between annotation and nodes

Parameters

ColumnTypeDefaultDescription
$annotation_ref integer
$nodes array

Return

boolean

Location

include/annotation_functions.php lines 450 to 467

Definition

 
function addAnnotationNodes($annotation_ref, array $nodes)
    {
    if(
=== count($nodes))
        {
        return 
false;
        }

    
$query_insert_values '';
    foreach(
$nodes as $node)
        {
        
$query_insert_values .= ',(' escape_check($annotation_ref) . ', ' escape_check($node['ref']) . ')';
        }
    
$query_insert_values substr($query_insert_values1);

    
sql_query("INSERT INTO annotation_node (annotation, node) VALUES  {$query_insert_values}");

    return 
true;
    }

This article was last updated 5th July 2020 04:35 Europe/London time based on the source file dated 17th January 2020 16:11 Europe/London time.