Coding standards
Security in ResourceSpace
Developer reference
Database
Action functions
Admin functions
Ajax functions
Annotation functions
API functions
Collections functions
Comment functions
Config functions
CSV export functions
Dash functions
Debug functions
Encryption functions
Facial recognition functions
File functions
General functions
Language functions
Log functions
Login functions
Message functions
Migration functions
Node functions
PDF functions
Plugin functions
Render functions
Reporting functions
Request functions
Research functions
Slideshow functions
Theme permission functions
User functions
Video functions
Database functions
Metadata functions
Resource functions
Search functions
Map functions
Job functions
Tab functions
Test functions

delete_nodes_for_resource_type_field()

Description

Delete all nodes for a resource type field

Parameters

ColumnTypeDefaultDescription
$ref
$resource_type_field integer ID of the resource type field

Return

void

Location

include/node_functions.php lines 196 to 203

Definition

 
function delete_nodes_for_resource_type_field($ref)
{
    if (
is_null($ref) || '' === trim($ref) || === $ref) {
        
trigger_error('$ref must be an integer greater than 0');
    }

    
ps_query("DELETE FROM node WHERE resource_type_field = ?", array("i",$ref));
}

This article was last updated 16th June 2025 13:05 Europe/London time based on the source file dated 9th May 2025 16:15 Europe/London time.