Function __global->_selectcode_to_generic

Definitions

sources/selectcode.php

  • Turn an Selectcode (a filter specifying which records to match) into a list of ID numbers.
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Return: array

Parameters

Name Type Default Set Range Description
$filter string required parameter N/A N/A The filter
$field_name ?string required parameter N/A N/A The database's ID field for the record-set we're matching (null: use a different lookup method)
$table_name ?string required parameter N/A N/A The database's table for the record-set we're matching (null: use a different lookup method)
$ids_and_parents ?array required parameter N/A N/A A map between record-set IDs and record-set parent-category-IDs (null: use a different lookup method)
$ids_and_parents_callback ?mixed required parameter N/A N/A A call_user_func_array specifier to a function that will give a map between record-set IDs and record-set parent-category-IDs. We pass a call_user_func_array specifier because we don't want to have to generate it unless we need to (if we need to do 'avoiding' matches or 'subtree' matches) (null: use a different lookup method)
$parent_spec__table_name ?string required parameter N/A N/A The database's table that contains parent/child relationships in the record-set's category-set (the category-set is equal to the record-set if we're matching categories, but not if we're matching entries) (null: don't support subtree [*-style] searches)
$parent_spec__parent_name ?string required parameter N/A N/A The database's field name for the category-set's parent-category-ID (null: don't support subtree [*-style] searches beyond the tree base)
$category_field_name ?string required parameter N/A N/A The database's field name for the record-set's container-category specifier (null: don't support subtree [*-style] searches)
$parent_spec__field_name ?string required parameter N/A N/A The database's field name for the category-set's category-ID (null: don't support subtree [*-style] searches beyond the tree base)
$numeric_record_set_ids boolean required parameter N/A N/A Whether the record-set IDs are numeric
$numeric_category_set_ids boolean required parameter N/A N/A Whether the category-set IDs are numeric
$db ?object required parameter N/A N/A Database connector to use (null: website)

Return

  • A list of ID numbers
  • Type: array
  • Set: N/A
  • Range: N/A