Add Param Type Join KC discussion

add_param_type() is used to add new parameter type such as Input, Checkbox, Text, etc.




  1. Name [string]: Name of the newly added parameter type.
  2. Func [string]: Name of the callback function. Please check the Additional Notes below for more details.
  3. class=”kc-param”: Set class name of the input which will return value.

Additional Notes:

Callback Function uses JS Templates; it passes values through “Data” variable .

  • Templates will pass a data variable which can then be called upon output values.
  • Escaped output goes in two curly braces {{data.escaped}}.
  • Unescaped data goes in three curly braces {{{data.unescaped}}}.
  • Arbitrary logic (JavaScript code) goes in carrot hash template tags <# //logic #>.
  • None of the three token markers above will be returned as it is.

Callback Function Parameters:

  1. Value [string]: Value of the parameter.
  2. Options [array]: List of options registered via mapping. These are used in some parameter types such as select, checkbox, radio, etc.
  3. Name [string]: Name of the parameter that is registered via mapping.
  4. Type [string]: Parameter type.
  5. Callback [function]: Call after the parameter is rendered.



This method allows you do more actions after the parameter has been rendered.