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.
To Reproduce:
Create a node type with a CCK location field
Create a node, entering in some data for the cck location field
Create a view, and add the node title and cck location fields to the view.
The location doesn't appear.
Cause:
The location data isn't loaded, so the location_cck formatter functions (theme_location_cck_*) have nothing to work with
The patch in comment #1 copies the filefield's method of loading the necessary data during the "sanitize" operation for hook_field.
Comment | File | Size | Author |
---|---|---|---|
#1 | location-cck-views-999770-1.patch | 856 bytes | setvik |
Comments
Comment #1
setvik CreditAttribution: setvik commentedComment #2
hchall CreditAttribution: hchall commentedSubscribing...
BTW, Thanks for posting this! I'm too novice to do patches, but eager to see this resolved in the next module update.
Comment #3
JimNastic CreditAttribution: JimNastic commentedGreat! This is really helpful!
Thanks!!!!!!
Comment #4
P2790 CreditAttribution: P2790 commentedOutstanding, so helpful! Thanks setvik!!
Comment #5
P2790 CreditAttribution: P2790 commentedTo #2 hchall
1. Create a folder /sites/all/modules/patches
2. Inside of /sites/all/modules/patches create a folder for the patch e.g. location_patch.
3. Inside of this folder place the patch.
4. In terminal go to the directory of the module
5. Put the following code patch -b -p0 < path/file.patch
6. Replace path/file.patch with the location of the patch we created in step 3.
7. We use -b because it creates a backup of the original file within the module directory, identifiable by ‘origin’ at the end of the file name.
Thats what I do, took me a while to figure out the best way to do patches, don't shy away, it can solve problems very quickly, plus with the back-up option you can always revert back if the patch doesn't work!
Comment #6
rooby CreditAttribution: rooby commentedThis is a duplicate of #427432: RTBC Content: Location views field always blank and is now fixed in the latest dev version.