Giter Club home page Giter Club logo

arcgis-dijit-geocoder-js's Introduction

arcgis-dijit-geocoder-js

Features

Geocoder widget for place searching with autocomplete.

Instructions

See example HTML file included in download.

New to Github? Get started here.

Requirements

  • Notepad or HTML editor
  • A little background with Javascript
  • Experience with the ArcGIS JavaScript API would help.

Resources

Issues

Find a bug or want to request a new feature? Please let us know by submitting an issue.

Contributing

Anyone and everyone is welcome to contribute.

Licensing

Copyright 2012 Esri

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

A copy of the license is available in the repository's license.txt file.

[](Esri Tags: ArcGIS JavaScript API Geocoder Dijit Public) [](Esri Language: JavaScript)

arcgis-dijit-geocoder-js's People

Contributors

driskull avatar jgravois avatar markstos avatar odoe avatar robkspeer avatar tsamaya avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

arcgis-dijit-geocoder-js's Issues

Geocoder widget hard limit to five results

The ArcGIS Web AppBuilder uses the Dijit Geocoder widget from the Javascript API, but the results are limited to five, and this seems to be because of line 838 in Geocoder.js:

for (i = 0; i < this.get("results").length && i < 5; ++i) {

Not sure if this should be a hard limit or configurable, since you can configure the widget to return more results, but the dropdown box from this Geocoder widget won't show more than five.

suffix prevents suggested locations from being zoomed to when selected

Hi there,

I came across a problem with the Geocoder when trying to limit the set of returned suggestions in terms of the source country.

In my case, I would like the Geocoder to return only locations within the United Kingdom. Because of that I tried setting the 'sourceCountry' parameter to 'GBR' but that didn't make a difference. For example, when typing in 'Newport' there are 4 US locations and 1 UK location where the UK one is third in the list.

I then tried using the parameter 'suffix' and set it to ' GBR'. This solved the problem with the accuracy of the suggestions as now they all come from the UK.

However, only suggested locations for towns and postcode lookups work when the 'suffix' parameter is used. When I try to lookup a more specific address starting with a road name, I get the correct list of suggestions but when I click on any of them, nothing happens. To add to the confusion when I delete the 'GBR' suffix from a specific address suggestion, the map zooms in to an expected location.

I and my team would be really grateful if you could look into that. Especially into why the sourceCountry parameter doesn't limit the suggestions to the specified country and why the suffix parameter breaks specific address lookups.

Below my Geocoder init:

            var geocoder = new Geocoder({
                map: map,
                autoComplete: true,
                arcgisGeocoder: {
                    name: "Esri World Geocoder",
                    sourceCountry: "GBR",
                    suffix:" GBR",
                    placeholder: "Search for location ... ",
                    localSearchOptions: {
                        minScale: 0
                    }
                }
            }, "search");

Thanks a lot,
Tomasz

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.