In a project I wanted to get the Node ID from a nodereference to be used as "Replacement pattern" in "Output this field as a link" for another field, e.g in the linknode/[field_my_nodereference]. I couldn't find out how to to this without a new formatter.

It's against 6.x-2.5 but I can re-roll if this is deemed useful.

Comments

ncameron’s picture

+1 for this. Just coded almost the exact same code to accomplish this. What is the process for getting this into the module?

Anonymous’s picture

I have applied this patch and it works perfectly!

I had actually half written the same patch, but I missed the extra array at the top of the module!

This is very useful and I cannot believe it's not part of the module already - surly, getting a simple handle on the referenced nodes ID is an essential part of this module?

Can more people review/test this patch and lets get it in the main code ASAP?

ncameron’s picture

One minor issue with this. When there are multiple node reference values and the content is outputted as a CSV file (via views bonus pack) the values are displayed next to each other e.g, 427943 instead of 427, 943.

I've been looking through the code, but can't work out how to format multiple values, any ideas?

Cheers,

Neil