CM HelpScout Docs Portal (CMHSDP) - Options - User JavaScript Callback

User JavaScript Callback

Navigate to the  Admin Panel → CM HelpScout Docs Portal → Options.

Click on User JavaScript Callback tab.

Caution: This option is only for advanced users. Modify only if you know what are you doing.

User callback is executed after every CM HelpScout Docs Portal Plugin content load. As parameter is always passed object { type: typename, data: data }.

Type depends on performed action:

  • listcategories - list of collection's categories are displayed.
  • listarticles - list of category's articles are displayed.
  • article - article content loaded (only shortcode for collection or category).
  • singlearticle - article content loaded (only shortcode for single article).
  • searcharticles - searching results are displayed.

Data also depends on the performed action and includes all of the data coming from the API. So it's possible to eg. dynamically change the <title> of the page.

Callback should looks like function(e){ ... }.

Below: Sample callbacks.

Click on Save Changes button.

More information about the CM HelpScout Docs Portal WordPress  Plugin

Other WordPress products can be found at CreativeMinds WordPress Store

Let us know how we can Improve this Product Documentation Page

To open a Support Ticket visit our support center
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.