(Better) Token integration
alippai - August 7, 2009 - 12:04
| Project: | Content Profile |
| Version: | 6.x-1.x-dev |
| Component: | Miscellaneous |
| Category: | feature request |
| Priority: | normal |
| Assigned: | alippai |
| Status: | closed |
| Issue tags: | token |
Description
This small module makes content profile fields available as user tokens. E.g.: you can use 'real name' or 'address' as tokens in other modules. (in my case activity module)
| Attachment | Size |
|---|---|
| cp_tokens.tar_.gz | 1.49 KB |

#1
Fixed the "namespace", added the dependencies and package to the .info file.
#2
hm, for sure we can't ship with that in the base module, as it has a significant impact on performance, but it would make sense to add it as extension module. However for that it would need more polishing - as of now I think it would have problems with some cck fields like user references. Perhaps it could reuse the information about the available cck or node tokens somehow. Also it should do something about preventing token loops (user -> node -> user.. ?)
#3
So it has support for text and number, single value fields. Added support for flag friends module - content profile tokens for requested and requestee.
#4
#5
What about my comments from #2?
#6
Got your irc message, I see it'S restricted to numbers and textfields now. So it should be fine.
-> I added in to the module and mentioned it in the README. I fixed some coding style issues and also noted that it didn't use 'user' as typen when doing the replacements. I've no time to test this right now, so I'm attaching the proposed changes. -> Testers needed!
@alippai: I removed your @author comment as with the time also others contribute to the module, but I mentioned you in the README as original author. Is it ok that way?
#7
oh and I fixed the module to depend on 'content' too.
#8
The patch in #6 works fine, at least for our purposes: it is exactly what we needed to get Content Profile fields output as part of RSS feeds using the RDF module. Many thanks, Adam and Wolfgang.
#9
alippai told me on IRC that it's fine that way -> committed, thanks!
#10
Automatically closed -- issue fixed for 2 weeks with no activity.