$longitude = round((min($longitudes)+max($longitudes))/2, 6);
//Set map
- $map = $this->config['cache'].'/'.$this->config['prefixes']['multi'].'/'.$zoom.'/'.($latitude*1000000%10).'/'.($longitude*1000000%10).'/'.$coordinate.'-'.$zoom.'-'.$width.'x'.$height.'.'.$_format;
+ //XXX: use hash with number of coordinates instead of coordinate value, filename over 255 characters isn't supported on many systems
+ $map = $this->config['cache'].'/'.$this->config['prefixes']['multi'].'/'.$zoom.'/'.($latitude*1000000%10).'/'.($longitude*1000000%10).'/'.$hash.'-'.count($coordinates).'-'.$zoom.'-'.$width.'x'.$height.'.'.$_format;
//Without map file
if (!is_file($map)) {