Hi! Thanks for visiting my blog. If you've received any value from my content would you mind supporting my new startup by downloading our browser add-on? It's called PriceBlink and makes online shopping a breeze. You can watch it in action here and download it for Chrome, Firefox, IE, or Safari by going to PriceBlink.com. Thank you and I hope you enjoy!

List/Map Interaction and Usability

May 21

This whole geotagging concept has me thinking quite a bit.  One of the things that I’ve been concerned about is usability.  This is one of the major factors that comes into play when building any sort of website or webapp.  If you check out the geotagging concept you’ll notice that making a selection in the list centers the map and shows the appropriate info window.  It would be cool to allow users to use their up/down arrow keys to scroll through the list and center the map on the selected tag.  I consider this expected behavior when viewing any sort of information in list format.  The problem is that this isn’t always the easy thing to achieve.

Frameworks such as Adobe Flex and standard HTML select lists ship with this functionality.  When you roll your own (which I’ve done here) then you’re out of luck.  You have to come up with some fairly extensive code to accomplish this task.  With that being said I’m currently looking into a few different options that will prevent me from reinventing the wheel.  I’m not interested in a Flex solution for this app, although Adobe’s UI components do rock.  We use them extensively at work.  Adobe’s Spry framework looks promising although it’s currently in its infancy.  I’ll definitely be keeping an eye on it and many other Ajax components that could do the job.

The benefit of rolling your own code is that you understand it, therefore easier debugging.  Not only that, it’s generally pretty lightweight since you’re writing code to perform a certain task and not serve the masses of developers who may use it.

In regards to List/Map interaction I also think it’s expected behavior for a selection on the map to trigger a selection in the list.  Once again, with frameworks this is easy because someone else has already solved the problem.  Trying to accomplish this through standard HTML, JavaScript, and CSS can get tricky fast.  This obviously means I’ll spend some time looking into it :)

As more and more apps utilize mapping I think this will become a common UI pattern.  Users like to be given a context of where they are and provided with some level of feedback.  If you access my geotagging concept and select something in the list you’ll see the map recenter.  Now select a different marker on the map, nothing happens in the list.  The previous selection is highlighted, which is very misleading.  I’ll be working to get that fixed soon.
This may seem like common sense, but I see this type of stuff overlooked all the time.  Although the solution seems pretty straightforward, it can be a mammoth to code.  At any rate, I’ll be digging around for possible solutions and will continue to post my progress.

Read More

More Geotagging Stuff

May 18

I spent some time this evening adding a sidebar to the geotagging app. If you click on a tag in the right sidebar the map is recentered and a window displays the tag information. Now I just need to get it so other BlueGPS users can post their favorite tags. Once this is achieved the possibilities are limitless in terms of how the information can be displayed to the user as well as functionality. Below is a screen and you can check out the working version by clicking here. I’m trying to work out a bug where the tags in the sidebar don’t correspond with the proper locations on the map. But you get the drift of what it’s trying to do.

Read More

Geotagging Concept

May 17

I’ve been spending what little spare time I have on BlueGPS and getting data from Windows Mobile over to my Rails app. I received a few feature requests from BlueGPS users asking for the ability to “geotag” locations with a simple note. I ultimately want to build in photo capabilities, but I’ll save that for a rainy day. So over the past few days I’ve been geotagging some of my favorite locations and have posted them here. You can see SensorLogic’s headquarters in the screen below. I took this the other day while leaving work and am amazed at the accuracy of my GPS receiver. It’s definitely accurate within meters.

If you’re interested in sharing your favorite locations with the community then look out for the next version of BlueGPS. I think of all the possibilities with sharing this type of information and how it can be used from a social aspect. Think of creating a geotag and then letting users add comments, rate the location, get directions, add to places to visit, etc. There’s a ton of potential with location based services and I’m hoping to see some ideas I’ve had over the past few years come to fruition. Needless to say, the technology to support this type of application currently exists and it’s only going to become more mainstream.

Read More

Ruby on Rails XML Builder

May 15

While working on a recent update to BlueGPS I’ve added the ability to “geotag” favorite spots with a location and basic note. The data is uploaded from a Windows Mobile device to a remote server. The server is currently running Ruby on Rails. I’ve added methods to add geotags and am currently working on the interface to display them. Since these tags will ultimately live on a Google map it makes sense to deliver them as XML and load them via AJAX.

Much to my suprise Rails provides just the mechanism to get data in an XML format. This is known as the Rails Builder. Generating XML is as simple as specifying a .rxml template instead of .rhtml. For example, my controller has an action of get_locations and instead of specifying a view name of get_locations.rhtml, I used get_locations.rxml. The builder code looks like:

xml.locations do
@locations.each do |temp|
xml.location(:lat => temp.latitude, :lon => temp.longitude, :note => temp.note) do
end
end
end

and generates the following XML:

[locations]
[location note="Ella's favorite little donut shop." lat="3250.1878,N" lon="09645.8498,W"][/location]
[location note="Golf Galaxy superstore. A good place to blow all your money!" lat="3252.5340,N" lon="09646.1594,W"][/location]
[location note="Matt's Rancho Martinez. Great Mexican food!" lat="3248.7498,N" lon="09645.2135,W"][/location]
[location note="SensorLogic Headquarters" lat="3257.5224,N" lon="09649.4056,W"][/location]
[/locations]

These are actual tags I generated over the weekend using the next version of BlueGPS. I’ll be working to display this data on a Google map in the next few days. The next version of BlueGPS will support geotagging and I’m hoping users will share their favorite spots with the community.

Read More

Configuring Ruby on Rails dispatch.cgi for Linux

May 14

I’ve been doing most of my Rails development using the built-in WEBrick server. I recently ran into a problem when deploying my application to a production environment. The production server was running Rails with Apache. Since I’m new to this type of configuration I ran into problems when trying to access the production app. Whenever I accessed any controller I received the following error message:

Rails application failed to start properly

After digging around I came to find out that my dispatch.cgi file (stored in the public directory) was configured incorrectly. Sometimes I do local development and testing on a PC and that’s where the problems began. When generating the Rails shell in Windows the dispatch.cgi file contains the following line:

#!c:/program files/ruby/bin/ruby

This won’t work on *nix so I had to update the statement to read:

#!/usr/local/bin/ruby

The paths to these binaries may vary depending on your environment, but you get the idea. I spent a couple of hours on this and hopefully my time invested will save you some hassle.

Read More