1283 Posts
Bucklash
9 years ago
Topic

Hi folks

Hoping to get some guru guidance please.

I am trying to access data within a groupx field.

Using $print_r($cck); I can see the data I want but I an unable to access it

Output Example

[groupx_field] => stdClass Object (
    [id]...
 ...[value] => Array
    (
        [0] => Array
              (
              [my_field_a] => stdClass Object
                  (
                         [id]...
                     ...[title]
                   )
etc....
     

I can do this:

<?php echo $cck->get("groupx_field)->value; ?>

 

I can do this:

<?php echo $cck->get("groupx_field)->value[0];

But I can not do this:

<?php echo $cck->get("groupx_field)->value[0]->my_field_a->id; ?>

I realise this is more of a php question rather than Seblod but any pointers would be great. 
Kind regards
Bucklash                 
Need some help?

2 replies have been added to this thread, and the topic is marked as solved.
You should subscribe to a club in order to read all posts.