Need help with Joomla? We are available for hire to help with Joomla customization, upgrades, maintenance, and custom development.
Explore our services
OS Property support center

SOLVED is it possible to apply custom styling Map

  • MelanieB
  • Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
9 years 5 months ago - 9 years 5 months ago #97748 by MelanieB
Hi,

is it possible to add custom styling to the OS Property Map? I have other maps on my site and wanted to have them all look similar.

I have copied the Json code from mapstyle.withgoogle.com/
And I just wondered if you knew how I could apply it in your OS Property Map?
Code:
[ { "elementType": "geometry", "stylers": [ { "color": "#242f3e" } ] }, { "elementType": "labels.text.fill", "stylers": [ { "color": "#746855" } ] }, { "elementType": "labels.text.stroke", "stylers": [ { "color": "#242f3e" } ] }, { "featureType": "administrative.locality", "elementType": "labels.text.fill", "stylers": [ { "color": "#d59563" } ] }, { "featureType": "poi", "elementType": "labels.text.fill", "stylers": [ { "color": "#d59563" } ] }, { "featureType": "poi.park", "elementType": "geometry", "stylers": [ { "color": "#263c3f" } ] }, { "featureType": "poi.park", "elementType": "labels.text.fill", "stylers": [ { "color": "#6b9a76" } ] }, { "featureType": "road", "elementType": "geometry", "stylers": [ { "color": "#38414e" } ] }, { "featureType": "road", "elementType": "geometry.stroke", "stylers": [ { "color": "#212a37" } ] }, { "featureType": "road", "elementType": "labels.text.fill", "stylers": [ { "color": "#9ca5b3" } ] }, { "featureType": "road.highway", "elementType": "geometry", "stylers": [ { "color": "#746855" } ] }, { "featureType": "road.highway", "elementType": "geometry.stroke", "stylers": [ { "color": "#1f2835" } ] }, { "featureType": "road.highway", "elementType": "labels.text.fill", "stylers": [ { "color": "#f3d19c" } ] }, { "featureType": "transit", "elementType": "geometry", "stylers": [ { "color": "#2f3948" } ] }, { "featureType": "transit.station", "elementType": "labels.text.fill", "stylers": [ { "color": "#d59563" } ] }, { "featureType": "water", "elementType": "geometry", "stylers": [ { "color": "#17263c" } ] }, { "featureType": "water", "elementType": "labels.text.fill", "stylers": [ { "color": "#515c6d" } ] }, { "featureType": "water", "elementType": "labels.text.stroke", "stylers": [ { "color": "#17263c" } ] } ]

Kind regards

Mel
Last edit: 9 years 5 months ago by Mr. Dam.

Please Log in or Create an account to join the conversation.

  • MelanieB
  • Topic Author
  • Offline
  • Elite Member
  • Elite Member
More
9 years 5 months ago #97754 by MelanieB
Replied by MelanieB on topic Is it possible to apply custom styling to Map
Ah I figured it out. I replaced the code for Style 1 in the helpers file with the code I pasted here and it works beautifully :)

Please Log in or Create an account to join the conversation.

More
9 years 3 months ago #100980 by Pascal Bazzea
Replied by Pascal Bazzea on topic SOLVED is it possible to apply custom styling Map
Thank you Melanie :)

Please Log in or Create an account to join the conversation.

Moderators: Mr. Dam, Nguyen Phu Quan