Sorry if this is a particularly stupid question but it's late and I'm going slightly round the bend on this.
I have an object returned from an API which echo '<pre>';print_r($r);echo '</pre>'; gives as:
stdClass Object ( [id] => 49 [submitdate] => 2015-11-05 14:33:16 [lastpage] => 4 [startlanguage] => en [Qu1[SQ001]] => Fred Bloggs [Qu1[SQ003]] => Caretaker [Feedback] => Great course, thank you ) The line echo '<p>Feedback: '.$r -> Feedback.'</p>'; displays 'Great course, thank you' as expected, but echo '<p>'.$r -> Qu1 -> SQ001.'</p>'; doesn't show 'Fred Bloggs', instead I get an error: Notice: Undefined property: stdClass::$Qu1.
Please will somebody tell me what I'm doing wrong?
$r -> Feedback(and$r -> id), but not if I try and get the name (Fred Bloggs), I expected it to be$r -> Qu1 -> SQ001, but I get the error as described.$r->Qu1['SQ001']Notice: Undefined property: stdClass::$Qu1