1. Home
  2. Docs
  3. LocateAndFilter WP plugin
  4. Developer’s Guide
  5. Add new Custom tags

Add new Custom tags

If you want to use any functionality or shortcode in map template or tooltip you can use Additional tags
This method allows you to define new custom tags.

Description : LocateAndFilter tags are pseudo-shortcodes of the form : |nameOfTag| , ex : |place_tags|
They are used in the navlist and tooltip template editors. They symbolize a piece of data and will be substituted by their value at runtime.

Args :
[array] $arr_tags : array of tags. Form expected: $arr_tags = array(field name => Tagname);
[string] $scope : The scope of the filters : a post type, “user” or “all” [string] $getDataCallbackFn : callback function name, gets the datas for passed field and marker ID [string] $addon_name : Addon name, no space or special char

Example : This will create a tag |place_tags|. The new tag appears in the backoffice, in the “Tooltips & Navlist” tab. You can now, if you want to, define a filter on that tag using Locate_And_Filter_Addon_Helper :: define_filters

Example : This will create a tag for shortcode |custom_shortcode_filed|.

Example : This will create a tag for ACF |advanced_custom_field|.

Example :you can add Custom tag via plugin

Was this article helpful to you? Yes No

How can we help?