I'm trying to theme the values in the asin cck field, but the asin cck field doesn't seem to adhere to the same node template variable conventions as the other cck fields adopt.
My other CCK fields (date, text, etc.) are available from either
$node->field_name and
$node->content->field_name_rendered
but the asin cck field is only available from either:
$node->field_name or, unconventionally
$node[0]
See the attached dev render screenshot.
Has this been realised already in another thread?
| Comment | File | Size | Author |
|---|---|---|---|
| asin_cck_field_node_array_structure.jpg | 111.21 KB | martysteer |
Comments
Comment #1
rfayDifferent CCK types use different approaches, and I don't know why. Standard text fields are field_name[instance][value]. Numbers are different. ASINs are different. They're field_name[instance][asin]. But it's quite common for different CCK types to be different.
It would be quite disruptive to change this. I can't say it makes sense, but I can say it seems like a waste to change. Marking won't fix. Feel free to continue the conversation if you'd like.
I suspect the 0 thing is a result of something you've created - I don't know what that is.