Link to content in email / extra markup in content

Created on 31 March 2025, 2 days ago

I'm running into two issues.

I'm using Mime Mail as the formatter and sender for Push Framework.

I would like to provide a link to the content item that triggers the push notification in email. I'm trying to use the [current-page:url] token, but the link it generates is to cron: http:///admin/config/system/cron. Is there a way to include a link to the content itself?

And I'm also using [push-object:content] to include the teaser display of the content. It's ending up in the email with a bunch of markup that's not in the actual content:


email test β†’

Is there something I can change to just display the basic content of the item?

πŸ’¬ Support request
Status

Active

Version

2.2

Component

Miscellaneous

Created by

πŸ‡ΊπŸ‡ΈUnited States bkerwin

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @bkerwin
  • πŸ‡ΊπŸ‡ΈUnited States bkerwin
  • πŸ‡ΊπŸ‡ΈUnited States bkerwin
  • πŸ‡ΊπŸ‡ΈUnited States bkerwin
  • πŸ‡©πŸ‡ͺGermany jurgenhaas Gottmadingen

    The token [current-page:url] is the current page, but you want the URL of your entity. So, you should look into the token browser to find out how the token for that entity looks like. Maybe something like [node:url].

    And HTML emails is a challenge, it needs some experimentation to get this to work. We've not enabled that at our client's sites yet.

  • πŸ‡ΊπŸ‡ΈUnited States bkerwin

    I tried using [node:url] but it doesn't render the link. Is there something we need to do to enable it to be rendered? [current-page:url] does render the link to cron so I'm not sure why [node:url] doesn't work.

  • πŸ‡©πŸ‡ͺGermany jurgenhaas Gottmadingen

    Well, I was only giving an abstract example. The real token syntax depends on what data is available to the token service at that point. And that determines the token name then that needs to be used. But again, we've never done that in our projects, so I'm just trying to give hints on where to look at.

  • πŸ‡ΊπŸ‡ΈUnited States bkerwin

    Ok, so it sounds like there currently there isn't a way to include a link to the entity that generates the notification. [node:url] does appear to be what we'd want, how would we go about adding it to the token service?

  • πŸ‡©πŸ‡ͺGermany jurgenhaas Gottmadingen

    it sounds like there currently there isn't a way to include a link to the entity

    That's not what I'm saying. There are tokens around at the point of rendering, I just don't know which ones, and I don't know about your context. Notifications can be about very different entity types, etc. I was just trying to explain that the "current-page" can certainly not be the correct token. Everything else needs some research and playing around with the tool, but I currently don't have the bandwidth to do that.

  • πŸ‡ΊπŸ‡ΈUnited States bkerwin

    I understand and appreciate you taking the time to respond here. Our scenario is pretty simple, when a node is added we generate email to the subscribed users and in the email we need a link to that node. We're using DANSE to generate the events and Push Framework to handle the notifications. [current-page:url] renders a link to the cron admin page (https:///admin/config/system/cron).

    is what appears in the token browser in the Push Framework admin. It seems like push-object is the only thing that refers to an object with a url but it's not the node.

    If there's any more guidance you could provide that would be great, I understand if not and thank you.

Production build 0.71.5 2024