Tailoring Site Responses to Microsoft Tag Requests


Introduction:

Microsoft Tag is interesting alternative to the use of typical QR tags; the response options to reading a Microsoft Tag include returning the user's rough position as latitude and longitude or a postal code. One may also track the device ID and use that to determine if the user is scanning the tag for the first time. Microsoft also manages the creation and storage of the tags though the Microsoft Tag website (http://tag.microsoft.com); further details regarding the use of tags in print or other media are described on this site. Further, Microsoft distributes the Microsoft Tag Reader application and makes it available to most mobile platforms including Windows Phone, iPhone, Blackberry, and Android based phones.

The site also provides access to reporting tools that may be used to study the success of Microsoft Tag based marketing efforts.

                                                   Microsoft Tag Requests

In terms of responding to a tag scan, Microsoft Tag offers five alternatives; scanning a Tag may result in (and all of this is described on the website):

  1. Opening up a new URL in the device browser. This could be used to direct the user to a website, or to a video - any content made available by URL access.
  2. Creation of a vCard that will permit the user to add you to their contact list. The intent seems to be to support the use of Tags on a business card - with a Microsoft Tag embedded on a business card; the user can scan the tag and immediately add the cardholder to their contact list.
  3. Download an app to the user's device (and tailored for use on that device type).
  4. Deliver a message of up to 1000 characters (Free Text Tag) to the user.
  5. Giving a phone number to the user that they may consent to call immediately. In the demo provided with this article, we are going to determine which of six taxi companies in Atlanta, Georgia is closest to the user and give that user that taxi company's phone number.
    Creating a tag is dead simple; the site provides a tool to site account holders for that purpose. To create an account you need only supply the site with your Windows Live account information.

Once you have created an account on the site, navigate to the Tag Manager application.

Tag Requests

Figure 1: The Tag Manager Application (http://tag.microsoft.com/manageads.aspx)

With the tag manager open, select "Create a Tag"; once done a dialog for tag creation be displayed. The tag manager Create a New Tag dialog requests a tag tile, type (app download, URL, free text, vCard, or dialer). You may upload a thumbnail image for the logo, set a start and end date for when the tag will be supported, and other information pertinent to the tag type selected (e.g., a mobile URL for a URL type tag). With all the information provided, the user may save the tag - it will then be made available for rendering.

Microsoft Tag

Figure 2: Displaying the coordinates in Yahoo Maps

 Tag Requests in Microsoft

Figure 3: Tag Render Icons

Selecting the render icon will open the render dialog; from there the user may select one for options for rendering. The option is custom; with this option the tag is rendered using dots. The purpose of this option is to allow the user to underlay an image under the tag - such as a company logo.

Tag Rendering Dialog

Figure 4: Tag Rendering Dialog

With the full frame and helper options, the tag is provided along with instructions for obtaining the Microsoft Tag Reader application (directing the user to visit http://gettag.mobi). The last option is plain, in that the Microsoft Tag is rendered alone and without an underlying image or instructions for downloading the reader app. Other options on the dialog allow the user to set the size of the Microsoft Tag and render it in black and white (which could be useful for printed materials). There are size limits posted on the site and the minimum sizes of color and black and white tags are different.

Now, when using the URL tag type, it is possible to affix query string values to that URL. For example, adding "?zipcode={!PostalCode}&lat={!Lat}&long={!Long}" to the end of the URL will put the user's current zip code, latitude, and longitude into the query string in lieu of the placeholders. The receiving site could then use that information to tailor the interface when the user accesses the site. Now, I should point out that the position information is intentionally degraded (for the safety of the user) and it is not accurate to more than a half mile. Still, if we know the user's position to that level, we can still do some customization of our response to a tag based redirection to our targeted site; that is in fact the basis for the demo application included with this article.

The Demonstration Website

The demonstration application is based on a notional Cab business. The story is we have a person that owns a few cab companies in and around the Atlanta metropolitan area. This person has decided to use Microsoft Tags to promote his businesses - it is decided that Microsoft Tags will be printed onto signs offering cab services and placed at the airport, Marta stations, hotels, night clubs, and so forth.

Our business owner also wants to save some money on fuel costs by routing the closest cabs to the site user. Each of the cab companies has a different name, address and phone number and the business owner wants to capture the user's latitude and longitude, figure out how far the user is from each of the cab companies and route that user's phone to a site where they will be provided with the nearest cab company's telephone number so that the user may immediately contact the closest taxi company.

So, if we have a user in need of a cab and the user sees and scans the taxi service's Microsoft Tag from a sign, the user will be directed to the a website. The website will capture the latitude and longitude of the user's phone, call a method to determine which business location is nearest to the user, and open up its landing page showing the nearest cab company to the user's present location along with a link to the company's phone number. The user then taps the link and the phone dials the nearest cab company to arrange a pickup. If the user has not enabled location, the user will directed to a main phone number where an agent will capture the user's information during the call and route the appropriate cab to the user's location.

Microsoft

Figure 5: Notional Taxi Cab Application

Trying out the example

The download includes the project, it is standard ASP.NET project with C# as the code behind. The download also includes a script to create an instance of the database on you instance of SQL Server. The script creates a single table, Store Locations, and this table has name, contact information, address, and latitude and longitude for the business address. The cab companies are real; I just geocoded the addresses of nine actual cab companies in the Atlanta area for the demo.

The project was written as a standard web forms project but really you'd want to write something that would look ok on a mobile browser. The Microsoft Tag reader application will run on Windows Phone, iPhone, Android, Blackberry, and so forth so you would really want to think about that.

The solution contains the web application and a simple data access layer. If you create the database from the script, when you open the solution, just update the connection to point to your instance of the database. You should be able to run the solution after doing so.

To try out different address, just open the project properties, select the web tab, and update the query string associated with the Specific Page under start action. You can then run the web application and see the address of the nearest cab company change in response to the values entered. Keep in mind that the lat/long are degraded intentionally by Tag and will only be accurate to .5 miles or there about. Too bad really, one could do so much more with more locations (like immediately hailing the cab to the user's exact position). At any rate, by plugging in the degraded position you can simulate what you'd be getting back from Tag and test with that.

Microsoft

Figure 6: Setting the specific page value to a specific lat/long.

There is nothing new or novel about the code used to find the nearest location; I am sure you can find similar code without looking too hard (I am not sure where this code came from, I've been using it a while and it does the job). You can review what is used in this demo application if you like; it finds the nearest location and then populates the web form with values for that particular office. I am only interested in the nearest location and so I am only returning a single location; you might need to return several of the nearest locations and may need to return a collection depending upon the nature of the business. The purpose of the demo is just to show something useful one can do with the Microsoft Tags but that would be difficult to pull off with QR tags.

Summary

Microsoft Tag is fairly new product and it has a lot more potential than QR tags given the implementation options. One could think of a lot things you could do with the optional information; since you are able to create and manage as many tags as you'd like, the options are really huge. For example, a zoo might create a tag for every type of animal in the park and put a tag on the sign describing the animal; a visitor could scan the tag and be directed to a video showing the animal as it exists in nature (that would be nice for the nocturnal animals - bats are not much fun to look at around 2PM). Or they could link other content showing where the animal came from, where and when it was born, just about anything interesting about a specific animal or type of animal. A business could use Microsoft Tags on business cards, individual employee directories could be published with a vCard tag. There are a lot of uses and I think it is a great idea overall.

Up Next
    Ebook Download
    View all
    Learn
    View all