I am trying to build a link using the CCK Taxonomy field. When I reference the CCK Taxonomy field (field_org) it comes up null.

$display = '<a href="add/volunteer-signup?project_name=' . urlencode($node->field_position_title[0]['value']) . '&org=' . urlencode($node->field_org[0]['value'])   . '" ' . 'TARGET="_blank">Apply for this volunteer position</a>';

Results in:
http://www.zzz.net/sfn/node/add/volunteer-signup?project_name=Article+Content+Coordinator&org=

When I substitute in the first field for testing

$display = '<a href="add/volunteer-signup?project_name=' . urlencode($node->field_position_title[0]['value']) . '&org=' . urlencode($node->field_position_title[0]['value'])   . '" ' . 'TARGET="_blank">Apply for this volunteer position</a>';

Results in:
http://www.zzz.net/sfn/node/add/volunteer-signup?project_name=Article+Content+Coordinator&org=Article+Content+Coordinator

Comments

jarea’s picture

I was finally able to get to where I wanted to go with the following statements

$tid = $node->field_org[0]['tid'];
$term = taxonomy_get_term ( $tid );
robertdouglass’s picture

Status: Active » Fixed

That makes sense. The CCK engine is storing the node/term relation (the tid), and the taxonomy engine is storing the information about the term (the term name).

Anonymous’s picture

Status: Fixed » Closed (fixed)