Closed (outdated)
Project:
Automatic Nodetitles
Version:
7.x-1.x-dev
Component:
User interface
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
20 Jan 2011 at 08:13 UTC
Updated:
24 Jul 2018 at 05:04 UTC
Jump to comment: Most recent
Comments
Comment #1
jcarlson34 commentedYes this is an issue with Token and not Automatic Nodetitles. Check out this thread for your answers and updates: #691078: Field tokens
Field tokens aren't available in the Drupal 7 Token module yet and the patch at the above thread only supports a few types of field tokens right now. Hopefully the rest will be supported soon.
Also: after installing the token patch, clear your cache to see the fields show up for Automatic Nodetitles.
Comment #3
mikeker commentedJust a quick note, since it seems that #691078: Field tokens is stalled waiting for review, that the $node variable is available if tick "Evaluate PHP in pattern". That let's you do something like this:
until tokens and fields gets straightened out...
Comment #4
danepowell commentedThis isn't really fixed, just waiting on the resolution of that other issue... it's a fairly big issue so I think it should stay open, and perhaps a disclaimer should be added to the ANT project page that Token integration is not fully functioning in D7.
Comment #5
sunketh commentedhttp://drupal.org/node/691078#comment-4499612 this more or less works.
Comment #6
fagoyou can also use the entity tokens module of http://drupal.org/project/entity
It has no support for multiple-value fields yet, though : see #1058856: Entity tokens not created for multi-value fields
Comment #7
aaron commentedsubscribe
Comment #8
jcarlson34 commentedAs stated by webchick in commet 1 of #691078: Field tokens, you can also use the Taxonomy Entity Index module now (located at http://drupal.org/project/taxonomy_entity_index) for basic field token support until the token module field tokens patch is ready.
Comment #9
zilverdistel commentedsubscribing
Comment #10
nmc commentedsubscribing
Comment #11
ownage commentedHas anyone figured out how to use Field Tokens with Automatic Node Titles using the Field Tokens patch?
I am freaking out. I've installed the patch, and inserting the tokens, (say last name for instance), [node:field-last-name] INSERTS JUST THAT into the title.
The only thing that has affected this is this non-working patch:
http://drupal.org/node/1123266
Which instead of inserting the actual token as the title, then inserts blank nothingness for the title.
Anyone have some advice?
Comment #12
zilverdistel commented@ownage: You could implement hook_tokens() and hook_token_info() to provide the tokens you need.
It doesn't seem likely http://drupal.org/node/691078 will be resolved all too soon.
Comment #13
mikeker commented@ownage, see my comment in #3. You have full access to the node object if you use PHP and should be able to get at any Field entity.
Comment #14
jcarlson34 commentedTokens beta 4 now has basic token support. Also check out this post about adding tokens: http://drupal.org/node/1252608
Comment #15
tdous commentededit: Found the answer to my crap question. Nothing too interesting to anyone else so taking this out.
Comment #16
manish-31 commentedPlease use current version of token module, all the field tokens are available. To view or use field tokens click on the link "Browse available tokens" and look for the field.
Comment #17
manish-31 commentedComment #18
gaurav.kapoor commented