3.34. Defining custom short codes to use anything in templates¶
Sometimes, you need a certain information from the target site, for example, in the post content. You can retrieve anything from the target site and assign it to a custom short code that can be used in the templates of the plugin. By this way, you can add that information into any template. To achieve this, do the following:
- Go to Site Settings Page and activate Post Tab
- Go to Custom Short Codes Section
- Configure the short codes in Custom Content Selectors for Shortcodes setting. For more information, see Custom Content Selectors for Shortcodes.
- Go to a template, such as Main Post Template. The custom short code you defined in the previous step should be shown as a button. Click to that button to copy the short code.
- Paste the short code into anywhere you want in the template.
- Save the site settings (See: Saving The Settings)