Thanks. I think we were writing at the same time.
Unserializing the $output won't work, because the $output comes with some other stuff, like html.
$data = unserialize($row->{$field->field_alias});
print $data['attributes']['Attending'][0];
To all, I apologize for not quoting the array keys in my previous "I got it" post.
But thank you.
I've posted an issue for documentation at the Views queue, suggesting a change in the explanatory text of views-view-field.tpl.php to be explicit that the snippet is literal.
Shai
On Thu, Sep 2, 2010 at 9:30 PM, Cory Gilliam
<imaaxa@gmail.com> wrote:
The data you are trying to get is inside an array that is inside an array.
Array(
[kit_id] => 570
[module] => uc_product_kit
[attributes] => Array(
[Attending] => Array(
[0] => Jane Doe, John Doe
)
[Note] => Array(
[0] => We are friends of Eric Smith and Sandy Smith
)
)
[shippable] => 0
[unique_id] => 4c7d632a8090c7.95333579
)
You need to add the name of the array that this array is in.
$data = unserialize($output);
print $data['attributes']['Attending'][0];
Little rusty at this. Hope that helps.
Cory
--
[ Drupal support list | http://lists.drupal.org/ ]