1. Home
  2. Docs
  3. Function Reference
  4. Functions
  5. bind_fn()

bind_fn()

Bind posted data keys with table field names.

Copy to Clipboard

Parameters

$table_str

Target tableĀ (without table_prefix)

$data_arr

Data to save, in $_POST format

$toLower_bln

If true, change keys to lowercase (default true)

$echoQuery_bln

If true the query will be echoed out (default false)

Return

mixed

Returns false if failed, otherwise returns the array

Example

Copy to Clipboard

The above example will remove “wrong_column”, and keep the keys existing in the target table, return them in an associated array.

Copy to Clipboard

Location

This function can be found here: