I'd like to do a bit of advanced theming which requires the $recipient object to be passed to the theme. This is similar to #752838: Pass $subject to the template, which suggested this, but only the $subject part was added. This is a patch against 6.x-1.x that would also pass $recipient.

CommentFileSizeAuthor
#1 1114536-theme_recipient-1-D6.patch1.21 KBrjbrown99

Comments

rjbrown99’s picture

Status: Active » Needs review
StatusFileSize
new1.21 KB

Here's the patch.

sgabe’s picture

I think you can use tokens to get the recipient in the message.

rjbrown99’s picture

I'm sure you can do that for rules and such, but I'd like the recipient $object to show up in the theme preprocess function so I can do things with it. As of now, the $variables array that comes to preprocess does not have the object. I can't see how a token would be accessed at that point but I'd be happy to hear about it.

sgabe’s picture

Status: Needs review » Fixed

Thank you, committed in both branches.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.