Monday, November 5, 2012

fetch json data in php - Stack Overflow

code starts from here

stdClass Object     (         [rank] => -text_relevance         [match-expr] => (label 'gold')         [hits] => stdClass Object             (                 [found] => 2                 [start] => 0                 [hit] => Array                     (                         [0] => stdClass Object                             (                                 [id] => ras_csv_540                                 [data] => stdClass Object                                     (                                         [all_us_sic_codes] => Array                                             (                                                 [0] => 55119901                                             )                                          [company_name] => Array                                             (                                                 [0] => Gold Key Automotive Ltd                                             )                                      )                              )                          [1] => stdClass Object                             (                                 [id] => saga_csv_540                                 [data] => stdClass Object                                     (                                         [all_us_sic_codes] => Array                                             (                                                 [0] => 55119901                                             )                                          [company_name] => Array                                             (                                                 [0] => Gold Key Automotive Ltd                                             )                                      )                              )                      )              )          [facets] => stdClass Object             (                 [contact_title] => stdClass Object                     (                         [constraints] => Array                             (                                 [0] => stdClass Object                                     (                                         [value] => ATV Dealer                                         [count] => 2                                     )                              )                      )                  [primary_city] => stdClass Object                     (                         [constraints] => Array                             (                                 [0] => stdClass Object                                     (                                         [value] => Surrey                                         [count] => 2                                     )                              )                      )              )          [info] => stdClass Object             (                 [rid] => e2467862eecf73ecc33b5ac97bb48a2ce547e09ccc6aef4ca2afe3b77febad30db8b184c072d5d32                 [time-ms] => 3                 [cpu-time-ms] => 0             )      ) 

want get only [0] => Gold Key Automotive Ltd line in php

Source: http://stackoverflow.com/questions/13229426/fetch-json-data-in-php

birmingham news lee evans lee evans 49ers vs giants giants vs 49ers san francisco 49ers san francisco 49ers

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.