Shortcodes are useful to change the settings at page level
Shortcode Attributes :
If an Attribute is not given, shortcode uses the values from Plugin Settings page.
page_id – to Change the Page ID.
color – to change the messenger theme color, add hex color code. ( since 2.1 )
logged_in_greetings – to change the greetings text for logged in user ( since 2.1 )
logged_out_greetings – to change the greetings text for the logged out user (since 2.1 )
ref – to change ref attribute
greeting_dialog_display – show, hide, fade
- Show – greeting dialog will always be shown when the plugin loads.
- Fade – greeting dialog will be shown when the plugin loads, then fade away and stay hidden afterward.
Leave blank to apply default settings
Greetings Dialog Display
greeting_dialog_delay – Set the number of seconds of delay before the greeting dialog is shown after the plugin is loaded.
Greetings Dialog Delay
hide_desktop – To hide the messenger on the desktop, set hide_desktop=true
hide_mobile – To hide the messenger on the mobile, set hide_mobile=true.
Examples:
Basic Shortcode
[chatbot]
It gets the default values, as defined in plugin Settings page.
To change page id
[chatbot page_id="1744915998866434"]
To Change Greetings Dialog
[chatbot logged_in_greetings="Get 20% discount" ref="20-discount"]
If Page ID is changed, Don’t forget to add domains to ‘Whitelisted Domains’ for that Facebook Page.
To avoid duplicates, Adding Shortcode in a post removes the default Settings Messenger and add new Messenger based on the Shortcode Attributes.