Posted by plsk on October 15, 2009 at 6:53am
4 followers
Jump to:
| Project: | Node Reference formatters |
| Version: | 6.x-1.2 |
| Component: | Miscellaneous |
| Category: | support request |
| Priority: | normal |
| Assigned: | plsk |
| Status: | active |
| Issue tags: | CCK, custom, Node Reference formatter, views |
Issue Summary
thank you for this module, very good work.
my question is: How to use another cck fields than teaser or full node in fieldset or cluetip ?
how to use overide in template.php ?
I would like to display any cck fields in cluetip and/or fieldset
can you help me ?
by advance thank you,
Alex
Comments
#1
Hello Alex,
If you select Full node than you'd get all the content including all CCK fields but if I understood you properly you would like to display only certain CCK field ?
In this case you can select one of the 'Custom' styles (for instance Cluetip : Custom) and then put code similar to this to your
template.phpfile:<?phpfunction phptemplate_nodereference_formatters_cluetip_custom($nid) {
if ($node = node_load($nid)) {
$output = '<div class="nodereference-formatters">';
$output .= $node->FIELD_YOURFIELDNAME[0]['value'];
$output .= $node->FIELD_YOUROTHERFIELDNAME[0]['value'];
$output .= '</div>';
return $output;
}
}
?>
?>
#2
Good help, should be put into the readme or description.. Thank You!
Or perhaps a user interface fpr these settings? Would be great..
#3
Hi, subscribing, could with this, I also show the imagefield as a picture as node reference formatter?
greetings, Martijn