In trying to get location_cck working via these patches:
http://drupal.org/node/427432#comment-2334350
http://drupal.org/node/391160#comment-2333860
and then Auto Nodetitle via the suggested issue here:
http://drupal.org/node/383244#comment-2252516
I have discovered that the token support in location_cck doesn't provide a raw token and, as such, can't be properly used in Auto Nodetitle as thing's like apostrophes will be encoded. I imagine this is because the field data is check_plain()'d, but I'm not sure where. In any case, my solution was to add raw tokens to the location_cck.module by using html_entity_decode().
I've attached a patch with that addition.

Comments

yesct’s picture

Status: Active » Postponed (maintainer needs more info)

Please check to see if this is still a problem in the new release. If it is, reply with a new summary and set the status back to active.

jdschroeder’s picture

Version: 6.x-3.x-dev » 6.x-3.1
Category: bug » feature
Status: Postponed (maintainer needs more info) » Needs review
StatusFileSize
new2.16 KB

Same deal in 3.1. If I want to use the location title as a node title using auto_nodetitle, I need to be able to use raw input to avoid encoded apostrophes, ampersands, and the like.

I've re-factored the above patch to work on location.token.inc in 6.x-3.1, adding raw counterparts for each of the items in the hook_token_list implementation.

stephesk8s’s picture

The tokens listed in the patch are the _N tokens. How does it work for the cck field for location name [field_location_embed-name]?

adraskoy’s picture

This still appears to be an issue for 6.x-3.1, re cck location fields; there are no raw versions.

adraskoy’s picture

StatusFileSize
new691 bytes

Here's a patch for adding raw tokens for CCK Location.

podarok’s picture

Version: 6.x-3.1 » 7.x-3.x-dev

all feature requests should be rolled against latest 7.x-3.x-dev and after commit can be backported to 6.x branch

Status: Needs review » Needs work

The last submitted patch, location_cck_raw_tokens.patch, failed testing.

adraskoy’s picture

Status: Needs work » Needs review

#5: location_cck_raw_tokens.patch queued for re-testing.

Status: Needs review » Needs work

The last submitted patch, location_cck_raw_tokens.patch, failed testing.