- Written by Super User
I've made the decision to, at least for now, open up the API to anyone who wants to use it without authentication. This means that using the service is as simple as fetching the response of a URI.
To get basic information for all of the countries in the world, go to http://geodata.solutions/restapi
If you want a little more info on Canada (and let's face it, who wouldn't?), it's http://geodata.solutions/restapi?country=Canada&limit=10
If it was British Columbia that really peaked your interest, go to http://geodata.solutions/restapi?country=Canada&state=British+Columbia
All of this is made easy using the API wizard, where you can choose what information you want, see a preview of the output, and be provided the URI.
Allowing for open, unauthenticated access seemed like the right thing to do in order to get people using the system quickly, and to grow in popularity and features. Over coming week, the intention is to produce more focussed API queries that are suited for specific tasks, such as jQuery code examples for Country -> State dropdown sets that might allow users to fine-tune their operation to suit their requirements. Other implementations might be getting latitude and longitude data for mapping purposes, fetching the Japanese names for countries, comparing the geographical size of countries, ordering lists by timezones, creating population heat maps for the USA, or various other things.
I encourage you to try out the API. I've worked hard on it. See what uses you can find for it, and get in touch if you have any specific requests in mind.
- Written by Super User
If you've been wondering why a world of web site developers, CMS teams, shopping cart providers, and blue chips are all maintaining their own independent geographical databases, then you're not alone.
Imagine if every website wanting to display the weather forecasts, forex information, or sporting results all had to download CSV files from a github repository and then commit themselves to maintaining their own lists forever more.
Countries, states and cities may not pop into existence as often as the weather changes, but the idea that every website should maintain their own database seems crazy. It's the kind of thing that it ideally suited to a web service.
Updating country lists may be a mere irritation, an occasional chore, for a website administrator. After all, the last time a new country needed to be added was back in 2011, when South Sudan gained independence from Sudan. However, states and their names change much more frequently, and towns and cities even more so. And then there's additional information about locations, such as their population, that change even more frequently.
The point of Geodata Solutions is to make that task a job for one organisation rather than for millions around the world. I plan to build on the existing database I've created, keep it current, and build on its assets. My hope is that this project will change the way geographical information is sourced in web applications. Syndicated usage of the system will alleviate the duplicated burden of maintaining local data stores while allowing error reporting and updates to be submitted by millions of users.
The RESTful interface is in 'Beta' at the moment. It offers country lists, state lists and city lists, along with some basic additional location information. Developers wanting to use the system should get in touch for an API key*, as well as requests for new search types or filtering, or new pieces of data. There's also quite a big job in completing gaps in the data set, of which population data is a significant one.
Get in touch, and point others who may be interested in this direction
Contact Andy with feedback or to request a key (I'll automate the API key process when we're tested and stable)
The REST API is open for use without any registration or API key, just start making the requests. See how it's done on the REST Demo page
- Written by Super User
I'm pleased to announce that version 1.0.1 of the Geodata Solutions Location List Custom Fields Plugin is now completed.
Joomla site owners can now add location data to their content, categories, user and contacts components.
There were some difficulties along the way. Given the newness of the custom fields functionality, there is little documentation for the new plugin type, and the routine for adding new custom field types differs from the custom fields types offered in the default Joomla package, which have their templates hard-baked into the core. I have to thank people on the Joomla forum, who were able to assist with questions and offer support.
This is just the first iteration of the extension, and there are many improvements to come, within the functionality of the plugin's code, and also in the web service offered on the Geodata Solutions side.
A few 'hacks' were required in this version:
- The jQuery chosen library had to be subverted in order to get the ajax functionality of the lists (as coded in general-use code snippet version) to work within Joomla's back end. The ability to 'destroy' the -chzn elements was available in Joomla 2.5, but it seems this was removed in J3.x. This version of the extension uses a hack that hides the chosen elements and unhides the original form fields offered by cavarief here.
- Authentication currently checks the HOST header in the js request- it's the crudest way of recording the usage of each separate implementation of the system, but hardly the most reliable
- Proposed solution in the next release would be to have a key generated with each download of the plugin (I think I can do this without requiring registration with Geodata Solutions- something that I think is a barrier to quick implementation) which the user could simply enter into the plugin configuration
- Very high volume sites might have to subscribe to support the service at a later stage
- There are issues related to the output/override of custom fields in the user component. This is reported issue, and one that I hope will be corrected in a future Joomla version. Until then users will have to put up with the pipe-separated format used for stage within their user profile views in the front end (eg. Australia|Victoria|Ballarat ) or create their own template override. If you want some help implementing this, or want to share your solution, then please get in touch.
The plugin was submitted to the JED on 4th July, and at time of writing is pending approval, but you can download Location Lists Custom Fields Plugin and read the (minimal) Location Lists Documentation
- Written by Super User
The introduction of Joomla! 3.7 saw brand new possibilities in the form of custom fields. Now, website admins can add their own fields to articles, user profiles and other components without any coding needed at all. The new fields can be filtered by user access and category, and allow Joomla site owners t customise the core Joomla component to meet their own specific use cases.
Joomla introduced a bevvy of its own custom field types which will cover many requirements, but it seemed to us that Joomla users could benefit from having geodata solutions ajax-driven dropdowns in their sites by adding out own custom fields plugin.
Things were pretty tough at the start. Because the new plugin types were so new, there was very little documentation on how it was done, but with help from Joomla forums, we got there.
The fields plugin is due to be completed at the end of June and should be hitting the Joomla Extension Directory a week or two after that.
We're pleased than in less than a month, Joomla users will be able to have reliable, clever and customisable dropdowns integrated into their articles and user profiles.
When the plugin is released, we'll follow up with a full article demonstrating how it works, and giving some examples of hoe Joomla site owners might find it useful.