affiliate-toolkit registers some custom post types and also taxonomies. Sometimes you may want to override certain parameters that are set by default.
This function is called when registering the taxonomies and is used to override the post types.
function atkp_taxonomy_posttypes_callback($taxs, $taxonomyname) {
//Fügt die Taxonomie "Produktkategorie" auch dem "Beitrags"-Typ hinzu
if($taxonomyname == 'produktkategorie')
array_push($taxs, 'post');
return $taxs;
}
add_action('atkp_taxonomy_posttypes', 'atkp_taxonomy_posttypes_callback', 10, 2);
Parameter | Description |
taxes | Contains the array in which the custom post types for the registry are contained (by default: atkp_product and atkp_fieldgroup depending on the taxonomy). |
taxonomyname | Contains the name of the taxonomy which is registered (e.g. "brand"). |
Return value | The modified array with the custom post types. |
This function is called directly before registration.
function atkp_register_taxonomy_callback($taxargs, $taxonomyname) {
//Aktiviert für die Taxonomie "marke" die Bearbeitung über das Backend (Standardmäßig ausgeblendet)
if($taxonomyname == 'marke')
$taxargs['show_ui'] = true;
return $taxargs;
}
add_action('atkp_register_taxonomy', 'atkp_register_taxonomy_callback', 10, 2);
Parameter | Description |
taxargs | Contains the array which will be passed to the register_taxonomy function. |
taxonomyname | Contains the name of the taxonomy which is registered (e.g. "brand"). |
Return value | The modified array. |
You are currently viewing a placeholder content from Facebook. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More InformationYou need to load content from hCaptcha to submit the form. Please note that doing so will share data with third-party providers.
More InformationYou need to load content from reCAPTCHA to submit the form. Please note that doing so will share data with third-party providers.
More InformationYou need to load content from reCAPTCHA to submit the form. Please note that doing so will share data with third-party providers.
More InformationYou need to load content from reCAPTCHA to submit the form. Please note that doing so will share data with third-party providers.
More InformationYou need to load content from Turnstile to submit the form. Please note that doing so will share data with third-party providers.
More InformationYou are currently viewing a placeholder content from Instagram. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More InformationYou are currently viewing a placeholder content from X. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More Information