Closed (fixed)
Project:
Token
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
5 Apr 2008 at 08:32 UTC
Updated:
6 Nov 2010 at 08:05 UTC
Jump to comment: Most recent file
I've created a 'send tokenised email' action in relation to new comments. The body is like so:
New comment posted by : [comment-author-name]
Comment title : [comment-title]
Comment body :
[comment-body]
After each new comment is posted the very next screen is blank with the following error message at the top:
Fatal error: Call to undefined function token_replace_all() in /mounted-storage/.../token/token_actions.module on line 126
Any help please.
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | token_actions.module.patch | 982 bytes | seanr |
| #3 | 242944_token_function_not_found.patch | 906 bytes | greggles |
Comments
Comment #1
gregglesPerhaps this was a mistake and it should really be token_replace_multiple? Eaton wrote that code and I'm not really sure about how/why it works...
Comment #2
superjacent commentedHas anyone else reproduced this error.
Comment #3
gregglesIn #253094: "Unable to send mail" with send tokenized e-mail redfox75 mentioned this as well so I've changed it.
Comment #4
seanrThat patch missed two more calls to the same function just a couple lines lower. See attached.
Comment #5
superjacent commentedI've manually patched the token_actions file and now the comments are recorded but there is an error message at the top of the page
Unable to send e-mail. Please contact the site admin, if the problem persists.The email address is correct.
From the 'Recent Log Entries' page the error is reported like this
Error sending e-mail (from admin@prime357.org to new comment - tokenised).. From the wording of this error message, it appears the 'to' email address is incorrect.Comment #6
seanrsuperjacent - separate issue for that here: http://drupal.org/node/253094
Comment #7
gregglesThanks, Seanr! Committed to the 6.x-1.x branch.
Comment #8
superjacent commentedI've now got it sending an email. The problem now is that there is no body, just the subject line.
Comment #9
gregglesLet's keep issues focused. This was specifically about problems with a call to a function that was wrong. We need a new issue (or perhaps an existing one covers it) for your current issue.
Comment #10
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.
Comment #11
thomas23@drupal.org commentedHi.
As promised at #288616: undefined function token_replace_all() in token_actions.module I tested version 6.x.1.11 an can now report that it worked for my case. I successfully used the following tokens on new comment action:
[site-name]
[site-url]
[comment-author-name-raw]
[comment-date]
[comment-m]
[comment-yyyy]
[comment-body]
[comment-nid]
I noticed [nid] didn't work but for my case it wasn't what I wanted anyway.
Cheers.