Hello,
On a map which is set with phocamaps 3.0.12 on Joomla! 3.10.10, i'am using openstreetmap with fontawesome icons. The issue is that i want to set a number in the icon instead the one taken from fontawesome. I have 17 icons on this map, so i need to numbered these icons from 1 to 17.
Is-there a way to achieve that when using openstreetmap ?
Is-this a way to use fontawesome 5.x with openstreetmap on phocamaps ?
Thanks by advance
Use numbers on icons markers with openstreetmap
-
- Phoca Member
- Posts: 26
- Joined: 26 Jun 2017, 16:25
- Jan
- Phoca Hero
- Posts: 48403
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Use numbers on icons markers with openstreetmap
Hi, in fact you don't need to use fontawesome only, with another prefix, etc. you can even use another library, but I think, you need to do specific icon for each number version. There is no some dynamic script to create the numbers.
Jan
Jan
If you find Phoca extensions useful, please support the project
-
- Phoca Member
- Posts: 26
- Joined: 26 Jun 2017, 16:25
- Jan
- Phoca Hero
- Posts: 48403
- Joined: 10 Nov 2007, 18:23
- Location: Czech Republic
- Contact:
Re: Use numbers on icons markers with openstreetmap
Hi, openstreetmap only works with icons defined in CSS
If you find Phoca extensions useful, please support the project
-
- Phoca Enthusiast
- Posts: 52
- Joined: 24 Jul 2018, 16:33
Re: Use numbers on icons markers with openstreetmap
Thanks for this discussion.
One way would be to define an "Additional Icon Class" in "Design Settings (OpenStreetMap)" tab for each marker: one, two, etc.
Then, in the site CSS, define the content of the classes:
etc.
You've to remove or replace ".fa" from the above code if you don't use "Icon Prefix".
Please note that this will delete the circle or any icon defined in "Marker Icon".
One way would be to define an "Additional Icon Class" in "Design Settings (OpenStreetMap)" tab for each marker: one, two, etc.
Then, in the site CSS, define the content of the classes:
Code: Select all
.one.fa::before {
content: "1";
}
.two.fa::before {
content: "2";
}
You've to remove or replace ".fa" from the above code if you don't use "Icon Prefix".
Please note that this will delete the circle or any icon defined in "Marker Icon".