Process a token from panel context in a ctools content type plugin I have a ctools content type plugin. It has a simple text field settings form. In there I am putting a token from the panel content e.g. %vn_subject:vn-subject-facebook-link. I am then rendering this into a template. However, it is just rendering out the token as above without processing it. How can I process the token if possible to retrieve the required field value?
Thanks
The magic function is ctools_context_keyword_substitute 

The key to getting this working is to make sure that you use the all contexts flag in your plugin configuration.

$plugin = array(
  'single' =&gt; TRUE,
  'title' =&gt; t('Instagram'),
  'category' =&gt; t('Content'),
  'all contexts' =&gt; TRUE,
);

/**
 * Render the custom content type.
 */
function MODULE_PANE_content_type_render($subtype, $conf, $panel_args, $context) {

  ....

  $replaced = ctools_context_keyword_substitute('your_string_with_%keywords', array(), $context);

  ....
}