original_string: public function mapUrl(array $options = []) {
  		$url = $this->_protocol() . 'maps.google.com/maps?';
  
  		$urlArray = !empty($options['query']) ? $options['query'] : [];
  		if (!empty($options['from'])) {
  			$urlArray['saddr'] = $options['from'];
  		}
  
  		if (!empty($options['to']) && is_array($options['to'])) {
  			$to = array_shift($options['to']);
  			foreach ($options['to'] as $key => $value) {
  				$to .= '+to:' . $value;
  			}
  			$urlArray['daddr'] = $to;
  		} elseif (!empty($options['to'])) {
  			$urlArray['daddr'] = $options['to'];
  		}
  
  		if (isset($options['zoom']) && $options['zoom'] !== false) {
  			$urlArray['z'] = (int)$options['zoom'];
  		}
  		//$urlArray[] = 'f=d';
  		//$urlArray[] = 'hl=de';
  		//$urlArray[] = 'ie=UTF8';
  
  		$options += [
  			'escape' => true,
  		];
  
  		$query = http_build_query($urlArray);
  		if ($options['escape']) {
  			$query = h($query);
  		}
  
  		return $url . $query;
  	}
code: public function mapUrl(array $options = []) {
  		$url = $this->_protocol() . 'maps.google.com/maps?';
  
  		$urlArray = !empty($options['query']) ? $options['query'] : [];
  		if (!empty($options['from'])) {
  			$urlArray['saddr'] = $options['from'];
  		}
  
  		if (!empty($options['to']) && is_array($options['to'])) {
  			$to = array_shift($options['to']);
  			foreach ($options['to'] as $key => $value) {
  				$to .= '+to:' . $value;
  			}
  			$urlArray['daddr'] = $to;
  		} elseif (!empty($options['to'])) {
  			$urlArray['daddr'] = $options['to'];
  		}
  
  		if (isset($options['zoom']) && $options['zoom'] !== false) {
  			$urlArray['z'] = (int)$options['zoom'];
  		}
  		//$urlArray[] = 'f=d';
  		//$urlArray[] = 'hl=de';
  		//$urlArray[] = 'ie=UTF8';
  
  		$options += [
  			'escape' => true,
  		];
  
  		$query = http_build_query($urlArray);
  		if ($options['escape']) {
  			$query = h($query);
  		}
  
  		return $url . $query;
  	}
code_tokens: public function mapUrl ( array $ options = [ ] ) { $ url = $ this -> _protocol ( ) . 'maps.google.com/maps?' ; $ urlArray = ! empty ( $ options [ 'query' ] ) ? $ options [ 'query' ] : [ ] ; if ( ! empty ( $ options [ 'from' ] ) ) { $ urlArray [ 'saddr' ] = $ options [ 'from' ] ; } if ( ! empty ( $ options [ 'to' ] ) && is_array ( $ options [ 'to' ] ) ) { $ to = array_shift ( $ options [ 'to' ] ) ; foreach ( $ options [ 'to' ] as $ key => $ value ) { $ to .= '+to:' . $ value ; } $ urlArray [ 'daddr' ] = $ to ; } elseif ( ! empty ( $ options [ 'to' ] ) ) { $ urlArray [ 'daddr' ] = $ options [ 'to' ] ; } if ( isset ( $ options [ 'zoom' ] ) && $ options [ 'zoom' ] !== false ) { $ urlArray [ 'z' ] = ( int ) $ options [ 'zoom' ] ; } //$urlArray[] = 'f=d'; //$urlArray[] = 'hl=de'; //$urlArray[] = 'ie=UTF8'; $ options += [ 'escape' => true , ] ; $ query = http_build_query ( $ urlArray ) ; if ( $ options [ 'escape' ] ) { $ query = h ( $ query ) ; } return $ url . $ query ; }
docstring: Returns a maps.google url
  
  Options:
  - from: necessary (address or lat,lng)
  - to: 1x necessary (address or lat,lng - can be an array of multiple destinations: array('dest1', 'dest2'))
  - zoom: optional (defaults to none)
  - query: Additional query strings as array
  - escape: defaults to true
  
  @param array $options Options
  @return string link: http://...
docstring_tokens: Returns a maps . google url