Usage:

This shortcode is used to automatically assign or remove a specified tag to a contact record in ActiveCampaign or to  generate a link/button within a page or post which, when clicked, will set or remove a specified tag to the contact record in your ActiveCampaign application.

This shortcode does NOT supports conditional branching with [ELSE_tag].
Shortcode nesting is NOT supported.

Parameters:

Tag ID’s vs. tag names:
We encourage the use of tag ID’s over tag names. Unless a tag is deleted, its tag ID can be considered persistent. Tag names, on the other hand, can be changed any time. Using a tag name that has been changed can lead your shortcode, hook or module to no longer work as expected.
cid The ActiveCampaign contact id you want to assign tags or remove tags.
Default: the current logged in ActiveCampaign contact .
Required: no. If no, logged in ActiveCamaign contact’s id will be used.
assign One or more tag ID’s or tag names taken from ActiveCampaign you wish to assign to this contact. If more than one is entered, please separate with commas.
Default: none.
Required: yes, if tag(s) to remove are not passed.
remove One or more tag ID’s or tag names taken from ActiveCampaign you wish to remove from this contact. If more than one is entered, please separate with commas.
Default: none.
Required: yes, if tag(s) to assign are not passed.
autorun If set to yes, the shortcode will execute without waiting for user input. If not set to yes, it will generate a form and a submit button and wait for user input. If the autorun option is used, the other parameters will be ignored (link_text, link_style, button_text, button_image, button_style, redirect_popup, aftertext).
Default: no.
Required: no.
link_text The text that should be displayed for the link.
Default: “Click here to submit”
Required: no.
link_style Any inline style you want to apply to the link.
Default: none.
Required: no.
button_text The text that should be displayed in the button.
Default: none .
Required: no.
button_image The HTTP/URL path to the image of your choice.
Default: none
Required: yes, if “buttontext” is not used..
button_style Any inline style you want to apply to the button image or HTML button.
Default: none.
Required: no.
redirect Sends the user to the URL of your choice after assigning/removing the tags. A special value can be passed, #reload#, to force a full reload of the current page.
Default: none .
Required: no.
redirect_popup Determines whether the user will be redirected to a new window after clicking the link or button or not. Only used if the “redirect” parameter is used. Set to ‘yes’ to activate this option.
Default: none.
Required: no.
after_text The text that should be displayed after the request has been processed, if the user hasn’t been redirected.
Default: none.
Required: no.
autocreate_tags If set to yes, non-exisiting tags in your ActiveCampaign application will be generated.
Default: yes.
Required: no.

Example:

[mbr_tag assign='55,66,77' remove='123,45' button_text='Click here' button_image='imageURL' redirect='redirURL' after_text='Your request has been processed.']

[mbr_tag assign='12,34,MY TAG NAME'  redirect='#reload#' link_text='Click here']

[mbr_tag autorun='yes' assign='12,34,56' remove='123,987' autocreate_tags='yes']

[mbr_tag cid='1234'  assign='12,34,56'  redirect='#reload#']

API:

There is currently no ActiveMember360 API function equivalent for this shortcode.

Note:

The #reload# value for the “redirect” parameter will ensure that the page is reloaded, forcing any other shortcodes on the page to resolve based on the latest changes that may have been introduced by the tags.