Zh GoogleMap FAQ: Difference between revisions
mNo edit summary |
|||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
== How to create Custom Icon for clusters (for each | == How to create Custom Icon for clusters (for each Group) == | ||
You can not only change cluster icon, but also define different icons for group of placemarks. | You can not only change cluster icon, but also define different icons for group of placemarks. | ||
Line 7: | Line 7: | ||
* Create any number of your Placemarks | * Create any number of your Placemarks | ||
* Create a few | * Create a few Group | ||
* For this | * For this group set property ''Override Cluster Icon'' to '''Yes''' | ||
* Assign | * Assign Group to each Placemark | ||
* Open Map Details, open '''Placemarks''' slider and set: | * Open Map Details, open '''Placemarks''' slider and set: | ||
** ''Show placemarks in cluster'' to '''Yes''', it is to enable marker clustering | ** ''Show placemarks in cluster'' to '''Yes''', it is to enable marker clustering | ||
** ''Group placemarks in cluster by | ** ''Group placemarks in cluster by group property'' to '''Yes''', in this case for each Group will be created personal clusterer with it's settings (placemark icon in this options too) | ||
== How to define the Same Icon for placemarks, belonging to same | == How to define the Same Icon for placemarks, belonging to same Group == | ||
You can overide Icon Type setting for placemark by define property for | You can overide Icon Type setting for placemark by define property for Group. | ||
* Create any number of your Placemarks | * Create any number of your Placemarks | ||
* Create a few | * Create a few Group | ||
* Assign | * Assign Group to each Placemark | ||
* For this | * For this group set property ''Override Placemark Icon'' to '''Yes''' | ||
In this case you could not think of correct setting for placemark icon. For each group of placemark the icon of placemark will be overridden by group property. | In this case you could not think of correct setting for placemark icon. For each group of placemark the icon of placemark will be overridden by group property. | ||
== How to use Marker Manager ( This feature is disabled for a few months ) == | == How to use Marker Manager ( This feature is disabled for a few months ) == |
Latest revision as of 12:01, 10 October 2019
How to create Custom Icon for clusters (for each Group)
You can not only change cluster icon, but also define different icons for group of placemarks.
It is demo for Map with Different Clusters
- Create any number of your Placemarks
- Create a few Group
- For this group set property Override Cluster Icon to Yes
- Assign Group to each Placemark
- Open Map Details, open Placemarks slider and set:
- Show placemarks in cluster to Yes, it is to enable marker clustering
- Group placemarks in cluster by group property to Yes, in this case for each Group will be created personal clusterer with it's settings (placemark icon in this options too)
How to define the Same Icon for placemarks, belonging to same Group
You can overide Icon Type setting for placemark by define property for Group.
- Create any number of your Placemarks
- Create a few Group
- Assign Group to each Placemark
- For this group set property Override Placemark Icon to Yes
In this case you could not think of correct setting for placemark icon. For each group of placemark the icon of placemark will be overridden by group property.
How to use Marker Manager ( This feature is disabled for a few months )
Marker manager is used to show/hide placemark depend on zoom level
It is a demo for Map with MarkerManager
- Create any number of your Placemarks
- Create a few Placemark Group
- Define Min Zoom for Marker Manager and Max Zoom for Marker Manager for range of zooms to show this placemark group
- Assign Placemark Group to each Placemark
- Open Map Details
- Open Placemarks slider and set Show placemarks in cluster to No to disable Marker Clusterer (because it show/hide placemarks)
- Open Placemark Groups slider and set Placemark Group Control to No to disable Managing Placemarks by Placemark Group List (because it show/hide placemarks)
- Open Advanced options slider and set Marker Manager to Yes to enable Marker Manager
How to create Find button with Autocomplete field
See a demo links, and context - it is a field on top of the map
And this is a demo what we need Find with Autocomplete
- Open Map Details
- Open slider Map Find Control (geocoding) and set:
- Find Control (geocoding) to Yes to enable Find option
- Draw route from search point to place if you want to draw route to map center
- Open slider Control Positions and set position of control Find Control (geocoding)
- Open slider Places Library and set:
- Enable using Places to Yes to enable Places API
- Show Autocomplete field' to Yes to enable Autocomplete feature
- set Radius to 0 if you don't want to see nearest places, which can be shown by Places API
- Open slider Route and set:
- Draggable if you want to have draggable route to your place
- Show Route Panel if you want to see route details
- Open slider Map Find Control (geocoding) and set:
And remember, you can restrict search for "Find control" and for "Autocomplete feature".
For Find - it is set in map details, go to Map Controls tab. Section "Map Find Control (geocoding)". Field Search Region
For Autocomplete - it is in map details, go to Places Library tab. Field Search country
That fields can be different, check tooltip for fields and my docs
How to use external styles
In some cases there is an option to change CSS styles for some objects.
In this case there is a list item, named like Style, Placemark Group CSS and etc.
For styling CSS class is using there, and predefined classes stored in component CSS files. But not for external type.
And for each type of styles there is special suffix for class name, you can check it in firebug, for example.
The list item value External created for user customization, because component CSS files you can't change, because if you change it, new release of component overrides your changes.
Therefore you should use template CSS files, of create yours.
Using template CSS files
For customization by template CSS files you should add your styles into yours template CSS.
Go to admin panel.
Menu Extensions -> Template Manager
You'll see two tabs
- Styles
- Templates
On the first tab you can define what template you use for admin and what - for site.
Switch to the second tab, and in table find your template, which you use for site part (front end).
And click on the second column (title of template) for opening template details
When you'll see details, you can notice Stylesheets block, which contains list of template files. That is out point to change.
When you check your page, you can check what template CSS styles is loaded (from page source, for example), and what style from what file is applied on some page items (by firebug, for example).
For example, it is template.css file.
Open it, and in the end of file add your styles
Using yours CSS files
Some time ago, when plugin started support open map in lightbox, there was a problem - not all styles from template is loaded, and map was not like as in component call.
After that added in map details special field to specify CSS files, which will be loaded when map is displaying.
And this feature you can use in case to add your styles.
Create your CSS file, store it in server folder.
Open map details.
Open slider Advanced options
You'll see Additional CSS styles for loading field.
Enter your filename with path to it. The separator for files is new line or semicolon ;
How to load placemarks
Check this tutorial
Prepare and Load Placemark Data
How to remove Zh Logo
You can remove my logo by setting component option.
Open component options and find powered by list item
Read text and set to No this option
Language: | English • русский |
---|