WPML
apply_filters( 'wpml_sub_setting', mixed|bool $default, string $key, string $sub_key )
Tipo
filter
Categoria
Varie
Versione di WPML
3.2

Descrizione

Restituisce un valore di una sotto-impostazione di WPML.

Argomenti

$default
(mixed|bool) (Obbligatorio) Il valore da restituire se la chiave delle impostazioni non esiste. Imposta su false se non utilizzato
$key
(stringa) (Obbligatorio) La chiave del nome delle impostazioni a cui appartiene la sottochiave
$sub_key
(stringa) (Obbligatorio) La sottochiave di cui restituire il valore

Esempio di utilizzo

Esempio
// $my_book_translation_option will return the translation option configured for the custom post type 'book'
$my_book_translation_option = apply_filters( 'wpml_sub_setting', false, 'custom_posts_sync_option', 'book' );

// $my_author_translation_option will return the translation option configured for the custom taxonomy 'author'
$my_author_translation_option = apply_filters( 'wpml_sub_setting', false, 'taxonomies_sync_option', 'author' );

icl_ls_languages, wpml_sync_custom_field_copied_value, wpml_ls_enable_ajax_navigation, wpml_element_type, wpml_setting, wpml_exclude_post_from_auto_translate, wpml_forms_config_ninja-forms, wpml_forms_config_wpforms, wpml_tf_feedback_open_link, wpml_translatable_user_meta_fields

Tutti i 30 hook della categoria Varie →