You would like to integrate a localisation system in your applications, K2 in particular, so that your users can locate an address on a map. With this article you will be able to do it in a few minutes.
You will have this result at the end of the article:
Follow instructions below :
1. Create a view
- The Text Box will contain the address entered by the user.
- the button localization allows you to validate”
- The Data Label will contain the html script that will allow the address to be displayed on the map.
2. Check Literal in the data label properties
3. Create an expression
- Give a name to your expression.
- Paste this html script into the expression:
- Then modify the expression by holding the click on the Text Box and releasing the click at that variable “q=”, exactly as in the figure below
- Finally click on OK.
4. Add the rule : when the button is clicked
5. Configuring data transfer
Hold the click on the expression and drop it into the data label.
6. Save the rule
Congratulations you now know how to integrate a location map into your K2 application. 🙂