- Posts: 13
COMMUNITY FORUM
can't get extra field value in content module
- Mark Landry
-
Topic Author
- Offline
- New Member
Less
More
12 years 3 months ago #109818
by Mark Landry
can't get extra field value in content module was created by Mark Landry
Hi
I'm trying to customize the k2 content module template.
Having a hard time getting custom field data for the second field.
Trying this, but I don't get anything:
echo $item->extra_fields[1]->value;
if I try "print_r($item->extra_fields);" I can see all the data for the particular item, but I can't extract the value.
Thanx for your help
Mark
I'm trying to customize the k2 content module template.
Having a hard time getting custom field data for the second field.
Trying this, but I don't get anything:
echo $item->extra_fields[1]->value;
if I try "print_r($item->extra_fields);" I can see all the data for the particular item, but I can't extract the value.
Thanx for your help
Mark
Please Log in or Create an account to join the conversation.
- william white
-
- Offline
- Platinum Member
Less
More
- Posts: 3722
12 years 3 months ago #109819
by william white
Replied by william white on topic Re: can't get extra field value in content module
try adderssing the extra fields as described here if your using 2.6.2 or later
Please Log in or Create an account to join the conversation.
- xaoc
-
- Offline
- Junior Member
Less
More
- Posts: 33
12 years 3 months ago #109820
by xaoc
Replied by xaoc on topic Re: can't get extra field value in content module
you must add
Log in or Create an account to join the conversation.
- Mark Landry
-
Topic Author
- Offline
- New Member
Less
More
- Posts: 13
12 years 3 months ago #109821
by Mark Landry
Replied by Mark Landry on topic Re: can't get extra field value in content module
Thanx, I'll give that a try.
I noticed that if I set extra fields to "show" the output changes and my code works...
I noticed that if I set extra fields to "show" the output changes and my code works...
Please Log in or Create an account to join the conversation.