4

I'm trying to create a custom template using the Drupal Newsletter module.

I need to populate the newsletter with existing content. For this, I think I need to replace a token like [node:nid] in the newsletter body (which is created with CKEditor). However, I have been unsuccessful.

When I use the token filter module, I'm only able to replace global tokens like date or [site:url] and not tokens involving a node. Can someone please help me out?

3
  • Could you share the link the Drupal newsletter module. ? :)
    – Vic
    Commented Sep 30, 2013 at 10:03
  • This might work for you: Token Insert Edit: Module Page Description: This module allows you to insert tokens into a textarea. It supports both plain text and wysiwyg textareas. The format used for the insert is compatible with Token Filter.
    – NWOM
    Commented Oct 22, 2013 at 7:36
  • @Vic I believe he is referring to the Newsletter module.
    – NWOM
    Commented Oct 22, 2013 at 7:39

1 Answer 1

0

Tokens are contextual based on where they are used, so it's not possible to reference arbitrary content. If you can add fields to the newsletter, the ideal way to resolve this would be to add a node reference field, then create your tokens by doing something like [newsletter:field_node[0]:entity].

Not the answer you're looking for? Browse other questions tagged or ask your own question.