MyListing v1.7.5: Maps & more!
Due to recent changes in Google Maps billing system, and because of the fact Google is restricted in countries such as China, we thought it necessary to provide an alternative for Maps, Location Geocoding, Reverse Geocoding, and Places Autocomplete in MyListing.
Mapbox felt an adequate choice, being an established maps provider, offering all of the services above, and having competitive pricing, with a free monthly plan of up to 50K map views/month, and 50K geocoding requests/month (click here to view full pricing table).
Note: Google Maps remains the default maps provider.
There’s a new settings page in WP Admin > Theme Tools > Map Services, for configuring everything related to Maps.
After installing this update, you won’t have to do any additional configuring, all settings that were previously located in Theme Tools > Theme Options, have been moved to this page, and will retain their previous values.
Switching to Mapbox
First thing you’ll need to do is create a Mapbox account here. The registration process is really fast, with no billing information or additional data required.
After registration is complete, go to your account, and under Access Tokens section, grab the default public token, or create a custom one.
Once you’ve obtained the access token, go back to your site, in WP Admin > Theme Tools > Map Services, switch “Map Service Provider” to Mapbox, and enter the access token in the field below.
That’s all — Maps throughout your site will start using Mapbox. Other than the different map skins and slightly different map control layout, the experience will be the same as it is with Google Maps.
Default Maps Language, Custom Map Skins, etc.
Both Google Maps and Mapbox now support setting the default language for maps, restricting autocomplete return types and location, as well as adding custom map skins.
This is a feature that’s been requested for a while, and it’s finally here — the listing permalink structure can be modified with listing type, region, and category information.
Modifiying the structure
The permalink structure can be modified in
WP Admin > Settings > Permalinks, under the
Listing Base setting. While it has been possible to modify the permalink base word, which is usually /listings/, it’s now possible to add other information, and even get completely rid of the base word.
What tags can be used?
The currently supported tags are:
%listing_type%— Displays the listing type
%listing_category%— Displays the listing category, or the first selected category in case multiple categories are enabled.
%listing_region%— Displays the listing region, or the first selected region in case multiple regions are enabled.
Multiple tags can be used in the listing base. The below examples are all valid:
How can the value returned by
%listing_type% tag be modified?
This value can be modified in the listing type editor, which you can access in
WP Admin > Listing Types. Go to the
General tab in the editor, and look for the new
Added package visibility settings for Static Code blocks
Since Static Code blocks aren’t related to listing fields, it wasn’t possible to benefit from field package visibility settings to hide/show these type of blocks. The visibility settings are embedded below the usual block settings, as seen in the image below.
All new features
- Added Mapbox support, as a Google Maps alternative.
- Added custom listing permalinks, with support for listing type, category, region, and url-s without a base static word.
- Added option to set Maps language in WP Admin > Theme Tools > Map Services.
- Added ability to use custom map skins in WP Admin > Theme Tools > Map Services.
- Added package visibility settings for static code blocks in single listing page (Can be used to display ads in listings with specific packages).
- Added ‘step size’ setting for Range and Proximity filters, making it possible to set the search radius to less than 1km.
- Improved term blocks layout in single listing page.
- Users will be prompted to share their device location when searching for nearby listings.
- Enabled map interactions on single listing page maps.
- Added [[:currentuserlogin]] to retrieve logged in user’s username in Shortcode content blocks and other places that support the bracket syntax.
- Added “Listing Type(s)” column in term view screen in WP Admin > Listings > (Categories/Tags/Regions).
- Added geolocation button in the location field in Add Listing page.
- Numeric listing fields with ‘0’ as value not showing up on content blocks.
- Info cards section bug when editing in Elementor.
- Claimed badge not shown in single listing page when Paid Listings module is disabled.
- Parallax effect on single listing page when using custom header templates & similar issue with “27 > Page Heading” Elementor widget.
- Using multiple work hours blocks in single listing page not working properly.
- Multiselect fields not showing the assigned placeholder in Add Listing page.
- Yoast SEO not recognizing the description field when editing a listing in backend.
- Conflict with Yoast SEO’s latest version, preventing the plugin from working in single term page in backend.
- Using backslashes in field names in listing type editor breaks the listing type config.
- Listing type editor not loading config immediately on page load.
- Not possible to deselect custom term landing page (for listing categories, regions, and tags).