Hello everyone and thanks for your time. I am trying to set up a loop to pull specific fields from a json api feed. The json feed can be seen here:
https://uysmiami.com/search/api_server_custom.php
I am trying to set up a loop to grab data from specific fields from the feed but with my limited php am grabbing other stuff as well. The results of my loop are can be seen at:
http://uysmiami.com/search/stevetest.php
the code I'm using is:
<?php
$json = file_get_contents('https://api.iyba.pro/vessel?key=95d30b94b3a7e8b8c2df379fb00816960f86e203&id=80393');
$data = json_decode($json,true );
foreach($data as $vdata)
{ foreach($vdata as $number){
echo "Name: ".$number['ListingOwnerName']."<br />";
} }
?>
how can I pull the fields I want and not the first two and last 4 lines of meaningless stuff?
Thanks again.