Paste Search Dynamic
geo_to_string($geo)
  1. <?php
  2.  
  3. function geo_to_string($geo) {
  4.   return implode("; ", array_map(function($coord) {
  5.     return implode(", ", [$coord->longitude, $coord->latitude]);
  6.   }, $geo));
  7. }
  8.  
  9. $arr = [
  10.         json_decode('{"longitude": "1", "latitude": "1"}'),
  11.         json_decode('{"longitude": "1", "latitude": "1"}')
  12. ];
  13.  
  14. echo( $d->d->c ?? 'hi');
  15.  
  16. ?>
Parsed in 0.010 seconds