Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
- I created a custom content type "research_question" which has a normal title
- I created another custom content type "research_blog" which has an automatic nodetitle. This content type has a cck field "field_research_question", which references nodes of type "research_question".
- In "research blog", I set the token [field_research_question-title] as the pattern for the title. As a test I created a content of this type, and chose a pre-created node for the field "field_research_question". From the dropdown for this field I can see something like "Week 1: Research Question", which is the title of a pre-created node of type "research_question". After adding this node, I expected the title will be "Week 1: Research Question", but it turned out to be 173, which is the nid of the aforesaid node.
- I tested this by using "[field_research_question-title], [field_research_question-nid]" as the pattern for the title for the content type "research_blog". Then added a node of this type as per my previous test. True enough the title of this new node was "173, 173".
It is hence my belief that there is a bug here. That is, the title token returns the node id instead of the node title.
Comment | File | Size | Author |
---|---|---|---|
#1 | token_cck.inc_.patch | 117 bytes | pvasener |
Comments
Comment #1
pvasener CreditAttribution: pvasener commentedI had the same problem. This is due to a small bug in the token_cck.inc file. Here is the patch.
Comment #2
eaton CreditAttribution: eaton commentedThanks. Part of the official relase now. :)
Comment #3
(not verified) CreditAttribution: commented