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 can't figure out the syntax for using database fields in the autnodetitles. and where can I get a list of approved fields?
Comments
Comment #1
hchall CreditAttribution: hchall commentedHey, me too. There seems to be a standard syntax for getting field values associated with a node via the Token API, but I can't any list of syntax that might include clues on how to reference one or several fields for use as node titles. This is an important feature, and I'm optimistic we'll hear from the developers soon.
Thanks for seeding this request.
Hardy
Comment #2
hchall CreditAttribution: hchall commentedI just clicked on 'Automatic Title Generation' group heading visible via 'administer>>content types>>your content>>edit' and there was that elusive list of all available tokens. And there was the one I was looking for. My initial approach at the [is_this_a_token] syntax resulted in a title '[is_this_a_token]' because the token actually included a suffix '-raw' since I was referencing a text field.
The new result from '[is_this_a_token-raw'] which returned that node's value for that field; in this case, 'the coffee must have helped'.
I'm requesting a modification to this module to more easily find this list of tokens via an additional comment in the "Pattern for the Title" help comment. Or perhaps some additional text for "Replacement Patterns" saying "Token reference list". It would be cool if these were automatically inserted when clicked upon.
Comment #3
manish-31 CreditAttribution: manish-31 at OpenSense Labs for DrupalFit commented