Hi,

in the field help it says
Alternately, this code can be supplied by your own custom function named computed_field_field_sa_item_list_price_compute($node, $field, $node_field).
This should read
Alternately, this code can be supplied by your own custom function named computed_field_field_sa_item_list_price_compute($node, $field, &$node_field).

/Kevin

Comments

millenniumtree’s picture

That one missing ampersand got me pretty upset, but that's pretty mild compared to what they did to the display function!

When your _display() function, as described, is placed in a module, assigning a value to $display does ABSOLUTELY NOTHING. You have to RETURN the value. This is not explained.
In fact, the display function can not even access the stored value using $node_field_item['value'] like you did in the UI!!

Here's a _display() function for a field named 'field_comp_c' that just passes the stored value through unformatted.

function computed_field_field_comp_c_display($field, $element, $node) {
	return $element['#item']['value'];
}
dqd’s picture

Issue summary: View changes

Due to the Drupal core life cycle policy and security support advisery, Drupal 6 is no longer supported. So issues for Drupal 6 cannot be longer maintained. The project maintainer has asked for closing all D6 issues to clean up the issue queue.

dqd’s picture

Status: Needs review » Closed (won't fix)