php - Parse This Json Array - Unable to get the values -


i need values of company names , how can ...

here output of json ...

array  (      [version] => 2      [query] => web developer      [location] => hyderabad, andhra pradesh      [paginationpayload] =>       [results] => array          (              [0] => array                  (                      [company] => ibm                      [country] => in                      [date] => mon, 02 apr 2017 07:10:15 gmt                      [formattedrelativetime] => 4 days ago                      [stations] =>                   )              [1] => array                  (                      [company] => iprism                      [country] => in                      [date] => mon, 01 apr 2017 07:10:15 gmt                      [formattedrelativetime] => 5 days ago                      [stations] =>                   )              [2] => array                  (                      [company] => sunlife                      [country] => in                      [date] => mon, 03 apr 2017                      [formattedrelativetime] => 3 days ago                      [stations] =>                   )       )  )

i need value of every company listed here in new line ,

ibm iprism sunlife

you have use foreach loop achieve result

 foreach($array['results'] $company){      echo $company['company'].'<br />';  } 

change name $array actual array variable


Comments

Popular posts from this blog

inversion of control - Autofac named registration constructor injection -

verilog - Systemverilog dynamic casting issues -

ios - Change Storyboard View using Seague -