We are creating a public facing web app that contains buildings and have enabled the ability to search by building name. However we've hit a problem searching for buildings where the name of the building includes an accented character. Couple of examples below:
Building Name | Likely Search Term |
Goat Café | Goat Cafe |
Brück | Bruck |
Møller | Moller |
Searching works fine in the app for all three of these examples, providing the user enters the relevant special character (e.g. searching for 'goat café' returns the correct building, but searching for 'goat cafe' does not return the building). The issue is that the general public are more than likely to enter a search term that does not include the accented character, as shown in the 'likely search term' column above.
In an ideal world, the search function in the web map should return the Goat Café feature if a user searches for 'goat café' or 'goat cafe'. Is anyone at ESRI able to confirm if this is possible or likely to be implemented in a future update to Map Viewer/ArcGIS Online?
In the meantime I can think of two workarounds, neither of which is ideal:
Is anyone aware of any other workaround that would present the results in a more user friendly manner and make it look like the search was working as a normal user would expect?
Additionally, related to all the above examples is the problem of apostrophes. These are slightly different in that the apostrophe is an additional character in a building name rather than being an accented version of an existing character (e.g. e and é). For example the dataset includes lots of buildings that include the word: 'King's' in their name, e.g. 'King's House'. The reality is that most users will search without the apostrophe (e.g. 'Kings House') but some users will search with the apostrophe. Regarding apostrophes, ideally the search function in the web map would return the King's House feature if a user searches for 'King's House' or 'Kings House'. The workarounds identified above apply in this situation too but, as with the accented characters, neither are ideal.
Does anyone have any ideas how better to handle searching where the searched value contains an apostrophe? Or is anyone from ESRI able to offer any advice or know if any improvements are in the roadmap for ArcGIS Online?
I can't believe we're the only ones to have come up against this issue, but I can't find any other posts on the topic on this community forum.
My initial thought is to use Create Locator in Arc Pro. Include in your table an alternate name field with no special characters. Use the Point of Interest Role.
Just a quick thought to get you started.
Hi @Roger_Schulz, thanks for the reply. I did think about a Locator as they seem to behave differently and return results with apostrophes even if you omit them from the search term. However, we're using the Search function against the Buildings layer as we want to select the feature to show information in a popup, not just pan/zoom the map to the feature (which is all a Locator will do).
Thanks for the response though.
@MappyIan - Would you use the experience builder search widget?
This may be helpful but it requires turning off search suggestions which are autopopulated when the user is typing. This builds on the second suggestion. The downside is that you need to press enter for the search results.
Data -
This is what it looks like -
Setup of the ExB Search Widget
Maybe this could work for you.
====================================
I wish there was a way to control what's displayed in the search suggestions.
Hi there @gis_KIWI4, thanks for the suggestion. Unfortunately we can't do this in Experience Builder, we're actually building a web app using the ArcGIS Maps SDK for JavaScript. Our custom web app just uses the search options configured in the Web Map. It seems like the problem is a fundamental issue with the way ESRI have configured the searching in the functionality that underpins Map Viewer (and also the Maps SDK for JavaScript).
I can't believe we're the only ones to have come across this problem as anyone creating public-facing apps is going to have the same issues (in my opinion). Everyone is used to searching in Google and that just works in a way that is intuitive. Having to specifically include/exclude accented characters and/or apostrophes is just not how people expect modern web apps to behave.
Ah fair enough.
I have no experience in that space!
All the best.
In the absence of any workable solutions, I've logged this as an idea. All Kudos on the idea would be much appreciated: