Data Sanitation
-
Database
$wpdb->insert( $table, (array) $data )
$data should be unescaped (the function will escape them for you). Keys are columns, Values are values.
$wpdb->update( $table, (array) $data, (array) $where )
$data should be unescaped. Keys are columns, Values are values. $where should be unescaped. Multiple WHERE conditions are AND ed together.The above was taken from the “Data Validation” page.
I have a function already built in my plugin that sanitizes the data so, does the above reference “data should be unescaped” mean that the data “could” be escaped?I guess the real question would be will the plugin be accepted in the repository with a function that escapes the data?
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Data Sanitation’ is closed to new replies.