Question

i want remote html content on my page. for that i am getting an array in stdclass object array. i print_r(array) which is given below

stdClass Object (
     [player_video] => Array ( )
     [Title] => Ciara
     [video_Link] => Oh.flv
     [img] => img
     [desc] =>
     [view] => 18
     [artist_name] => Ciara
 ) 

how can i get title from this array. i tried $array[0]['Title'] $array['player_video']['Title'] but all these type of functions return nothing. i think i m using wrong approach. Please guide how to achieve this. Thanks

Was it helpful?

Solution

$array seems not to be an array at all. You'll get the title attribute of this object with $array->Title

OTHER TIPS

Use arrow -> instead of square brackets []. Try this -

$array->Title

If it's an object then try:

$stdClass->Title;
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top