The Page Template setting on the Pages tab allows you to change the default page layout for a store page. The template should be written using basic HTML as allowed by the WordPress page editor in “text” (versus visual) mode.
The [storepage] shortcode works for Pages only. It allows any field from the base Store Locator Plus locations table to be output on the page.
You must specifiy a field to output by using the field attribute. For example [storepage field=”sl_store”]. As of version 3.9 of Store Locator Plus the field names are:
- sl_store – the store name
- sl_tags – the comma separated raw tag list from Pro Pack
- sl_url – the website URL
- sl_image – the image URL if entered
- sl_pages_url – the store page URL
- iconarray – display an array of Tagalong category icons.
To reset the Page Template to the default value, expand the Page Layout Template under the Pages/Initial Page Features and just erase what was in there, delete, save settings, and the Page Template will go back to the new default, you must update SLP 4.3.13 or above and Pages 4.3.01.
The revised Default Page Template has eliminated any href of shortcodes in an html string as WordPress 4.2.3 no longer allows that.
As of Store Pages version 3.10+ you can leave off the preceding sl_, so sl_store becomes field=”store”.
You can add a type attribute to modify the way the field data is rendered. (version 3.10+) As of WP update 4.2.3 you can no longer have a shortcode in double quotes. In other words, WP no longer allows quoted shortcodes inside of quotes
- hyperlink – will prepend http:// to the field data if it does not already start with http://Example:
[storepage field="url" ];[storepage field="url"];
Adding A Map
Here is one method for adding a map to the Store Pages template using an iframe within the template:
The 4.3 version contains some new shortcodes, in particular this one will be helpful:
- Note: Some themes may cause a conflict on your individual Store Pages. We have been notified by a forum contributor that the “Ronneby” Theme is one of those themes that interrupts the map being displayed on individual Store Pages. There may be others out there. Pages follows the WP taxonomy and Posting structure.
Google Maps Iframe Method
Google recently changed their map embedding feature. Using an iframe now requires that you sign up for an API key via Google Developer Console. You must turn on the Google Maps Embed API and then fetch your credentials so you can paste your API key into the URL string for the iframe source.
Please note: WordPress, also changed the best practices and you need to really know what you are doing and be very familiar with the WP codex and dichotomy.