Widgets
Embed Pozi widgets into your website to enable visitors to view a map or specific details about any address.
Pozi offers two kinds of widgets.
Data Widget
The Pozi data widget enables users to search any address to display specific details about the location (eg, waste collection details).
Demo
Example data widget
Type ‘3 Queen Street’ to try it out.
<iframe height="200px" width="100%" overflow="hidden" frameBorder="0" src="https://southerngrampians.pozi.com/widget.html#card=Waste%20Collection&fieldnames=Next Rubbish Pickup,Next Recycling Pickup,Next Organics Pickup&fontsize=20"></iframe>Examples
- Cardinia Shire Council - Bin Collection Days
- Frankston City Council - Bin Information
- Northern Grampians Shire Council - Bin Collection Date
- Horsham Rural City Council - Waste Collection Days
- City of Greater Bendigo - Bin Night
Configuration
The Pozi data widget can be configured to display the result of any individual dataset that appears in the What’s Here results of the Info Panel of your site.
All you need is the name of the dataset (as displayed in the dataset’s tab heading).
https://<sitename>.pozi.com/#/card[<datasetname>]/widget[true]/
Example:
- site name:
strathbogie - dataset name:
wastecollection(derived from the “Waste Collection” results tab heading in the What’s Here results, with any spaces or underscores removed)
The basic widget URL is constructed as follows:
https://strathbogie.pozi.com/#/card[wastecollection]/widget[true]/
The resulting widget displays a table view of the results for the address specified by the user.
See Embedding the Widget below to learn how to configure the widget with your URL.
Options
Display Specific Fields
By default, the data widget displays all fields as a table. If you want to instead see a list of fields, you can specify the field names within the &fieldnames=... parameter, separated by commas.
Example:
https://southerngrampians.pozi.com/widget.html#card=Waste Collection&fieldnames=Next Rubbish Pickup,Next Recycling Pickup,Next Organics PickupHide Field Names
This parameter hides the field names and only displays the field data.
fieldnameshide=true
Font Size
By default the font size of the widget text is set to 18. However, you can specify a different font size by using the optional font size parameter, for example:
fontsize=10
Troubleshooting
Some fields are not showing in the results
If the widget URL specifies field names to display via fieldnames=..., these fields must exist in the source data.
If expected attributes are not showing, check that the field names in the source data have not changed. If they have changed, update the widget URL accordingly.
Map Widget
The Pozi map widget enables users to search any address to launch an instance of the Pozi web application focussed on the address location.
Example map widget
Type ‘3 Queen Street’ to try it out.
<iframe height="200px" width="100%" overflow="hidden" src="https://southerngrampians.pozi.com/widget.html#newtab=true"></iframe>Example
Options
Redirect
If this parameter is added, the current page will be redirected to the Pozi map zoomed to the address.
redirect=true
New Tab
If this parameter is added, the Pozi map will be loaded in a new tab zoomed to the address. Note this option can have issues with browser security such as the built in popup blockers, in particular in Firefox. Whilst the user can change the settings in their browser to allow popups, depending on the expected customer, it may be more appropriate to avoid using the Newtab parameter and live with the downside of having the Pozi map load in the same tab as the address search was performed.
newtab=true
Embedding the Widget
Once you’ve generated the URL for your data or map widget (including any optional parameters), you can embed the widget in your website using an iframe.
The HTML for the iframe is as follows:
<iframe style="border:none; height: 300px; width: 100%; overflow: hidden;" src="https://<your-URL>"></iframe>