Digital Colony!

Amazon Link Builder

Bloggers will often link to media on Amazon. Many have affiliate accounts and earn a small commission if the link referral converts to a sale. However, the process of going to Amazon, locating the book, looking for the ASIN number and hand building a referral link that is XHTML compliant can take a while. Adding an image of the book or DVD makes it even more complicated.

It was too many steps for me, so I created a tool that I hope will be as useful to others as it will be for me.

Build Amazon Link With Image

In a future post, I'll go into the code behind the form.

Labels: ,

 

Using Yahoo! Maps GeoCoding API in C#

Building a map using Yahoo! Maps or Google Maps requires Latitude and Longitude points. Until Yahoo! released it's GeoCoding APIs getting address latitude and longitude was neither easy or free. At this time Yahoo! allows you to GeoCode 50,000 addresses a day. The code below will call the Yahoo! GeoCoding API using C# and ASP.NET 2.0. Yahoo!

Latitude and Longitude Precision

When supplying Yahoo! with an address, it will try to return the highest level of precision. The returned XML document will tell you how precise the latitude and longitude are. If it can't resolve an address, it will return a warning. Yahoo! Map

Files Included in Download

* GeoCode.aspx - Form to enter address. Also will display response from Yahoo!.
* GeoCode.aspx.cs - Calls class to make geocoding request.
* GeoAddress.cs - An address class.
* GeoAddressAPI.cs - Class which calls Yahoo! and parses response.
* web.config - Holds application ID required by Yahoo!

GeoCode.zip - Don't forget to enter your application ID at the end of the querystring in the web.config file. This format supports ASP.NET 2.0. If you are running 1.1, you will need to make some minor adjustments to how you store your API url in the web.config file.

Working Demo

GeoCoding C# Yahoo Demo

Labels: , , ,

 

Digital Colony Copyright © 1999-2008 XHTML   508
This site uses Blogger, which is not 100% XHTML compliant.
Try...Catch Disclaimer: For brevity many examples do not include error handling. That is your responsibility.