public function staticMarkers(array $pos = [], array $style = []) {
		$markers = [];
		$verbose = false;

		$defaults = [
			'shadow' => 'true',
			'color' => 'blue',
			'label' => '',
			'address' => '',
			'size' => ''
		];

		// not a 2-level array? make it one
		if (!isset($pos[0])) {
			$pos = [$pos];
		}

		// new in staticV2: separate styles! right now just merged
		foreach ($pos as $p) {
			$p += $style + $defaults;

			// adress or lat/lng?
			if (!empty($p['lat']) && !empty($p['lng'])) {
				$p['address'] = $p['lat'] . ',' . $p['lng'];
			}
			$p['address'] = urlencode($p['address']);

			$values = [];

			// prepare color
			if (!empty($p['color'])) {
				$p['color'] = $this->_prepColor($p['color']);
				$values[] = 'color:' . $p['color'];
			}
			// label? A-Z0-9
			if (!empty($p['label'])) {
				$values[] = 'label:' . strtoupper($p['label']);
			}
			if (!empty($p['size'])) {
				$values[] = 'size:' . $p['size'];
			}
			if (!empty($p['shadow'])) {
				$values[] = 'shadow:' . $p['shadow'];
			}
			if (!empty($p['icon'])) {
				$values[] = 'icon:' . urlencode($p['icon']);
			}
			$values[] = $p['address'];

			//TODO: icons
			$markers[] = implode('|', $values);
		}

		//TODO: shortcut? only possible if no custom params!
		if ($verbose) {

		}
		// long: markers=styles1|address1&markers=styles2|address2&...
		// short: markers=styles,address1|address2|address3|...

		return $markers;
	}
public function staticMarkers(array $pos = [], array $style = []) {
		$markers = [];
		$verbose = false;

		$defaults = [
			'shadow' => 'true',
			'color' => 'blue',
			'label' => '',
			'address' => '',
			'size' => ''
		];

		// not a 2-level array? make it one
		if (!isset($pos[0])) {
			$pos = [$pos];
		}

		// new in staticV2: separate styles! right now just merged
		foreach ($pos as $p) {
			$p += $style + $defaults;

			// adress or lat/lng?
			if (!empty($p['lat']) && !empty($p['lng'])) {
				$p['address'] = $p['lat'] . ',' . $p['lng'];
			}
			$p['address'] = urlencode($p['address']);

			$values = [];

			// prepare color
			if (!empty($p['color'])) {
				$p['color'] = $this->_prepColor($p['color']);
				$values[] = 'color:' . $p['color'];
			}
			// label? A-Z0-9
			if (!empty($p['label'])) {
				$values[] = 'label:' . strtoupper($p['label']);
			}
			if (!empty($p['size'])) {
				$values[] = 'size:' . $p['size'];
			}
			if (!empty($p['shadow'])) {
				$values[] = 'shadow:' . $p['shadow'];
			}
			if (!empty($p['icon'])) {
				$values[] = 'icon:' . urlencode($p['icon']);
			}
			$values[] = $p['address'];

			//TODO: icons
			$markers[] = implode('|', $values);
		}

		//TODO: shortcut? only possible if no custom params!
		if ($verbose) {

		}
		// long: markers=styles1|address1&markers=styles2|address2&...
		// short: markers=styles,address1|address2|address3|...

		return $markers;
	}
public function staticMarkers ( array $ pos = [ ] , array $ style = [ ] ) { $ markers = [ ] ; $ verbose = false ; $ defaults = [ 'shadow' => 'true' , 'color' => 'blue' , 'label' => '' , 'address' => '' , 'size' => '' ] ; // not a 2-level array? make it one if ( ! isset ( $ pos [ 0 ] ) ) { $ pos = [ $ pos ] ; } // new in staticV2: separate styles! right now just merged foreach ( $ pos as $ p ) { $ p += $ style + $ defaults ; // adress or lat/lng? if ( ! empty ( $ p [ 'lat' ] ) && ! empty ( $ p [ 'lng' ] ) ) { $ p [ 'address' ] = $ p [ 'lat' ] . ',' . $ p [ 'lng' ] ; } $ p [ 'address' ] = urlencode ( $ p [ 'address' ] ) ; $ values = [ ] ; // prepare color if ( ! empty ( $ p [ 'color' ] ) ) { $ p [ 'color' ] = $ this -> _prepColor ( $ p [ 'color' ] ) ; $ values [ ] = 'color:' . $ p [ 'color' ] ; } // label? A-Z0-9 if ( ! empty ( $ p [ 'label' ] ) ) { $ values [ ] = 'label:' . strtoupper ( $ p [ 'label' ] ) ; } if ( ! empty ( $ p [ 'size' ] ) ) { $ values [ ] = 'size:' . $ p [ 'size' ] ; } if ( ! empty ( $ p [ 'shadow' ] ) ) { $ values [ ] = 'shadow:' . $ p [ 'shadow' ] ; } if ( ! empty ( $ p [ 'icon' ] ) ) { $ values [ ] = 'icon:' . urlencode ( $ p [ 'icon' ] ) ; } $ values [ ] = $ p [ 'address' ] ; //TODO: icons $ markers [ ] = implode ( '|' , $ values ) ; } //TODO: shortcut? only possible if no custom params! if ( $ verbose ) { } // long: markers=styles1|address1&markers=styles2|address2&... // short: markers=styles,address1|address2|address3|... return $ markers ; }
Prepare markers for staticMap

@param array $pos markerArrays
- lat: xx.xxxxxx (necessary)
- lng: xx.xxxxxx (necessary)
- address: (instead of lat/lng)
- color: red/blue/green (optional, default blue)
- label: a-z or numbers (optional, default: s)
- icon: custom icon (png, gif, jpg - max 64x64 - max 5 different icons per image)
- shadow: TRUE/FALSE
@param array $style (global) (overridden by custom marker styles)
- color
- label
- icon
- shadow
@return array markers: color:green|label:Z|48,11|Berlin

NEW: size:mid|color:red|label:E|37.400465,-122.073003|37.437328,-122.159928&markers=size:small|color:blue|37.369110,-122.096034
OLD: 40.702147,-74.015794,blueS|40.711614,-74.012318,greenG{|...}
Prepare markers for staticMap