PHP code example of eduardo-marcolino / acf-fields-in-custom-table
1. Go to this page and download the library: Download eduardo-marcolino/acf-fields-in-custom-table library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
eduardo-marcolino / acf-fields-in-custom-table example snippets
add_filter( 'acfict_table_prefix', function( $prefix, $tablename ) {
return 'newprefix_';
}, 10, 2);
//Will disable WP Post Meta storage for all field groupd with "ACF: Fields in Custom Table" enabled.
add_filter( 'acf/pre_update_value', function( $default, $value, $post_id, $field )
{
if( $field[ACF_FICT::SETTINGS_ENABLED] ) {
return false;
}
return $default;
}, 10, 4);