| Microsoft Popfly is a web-based tool which can be used to create the mashups that are so hot these days. Popfly is centered on the concept of “blocks”, self-contained objects which perform a specific function. Popfly’s Silverlight-based interface allows the user to drag-and-drop these blocks and draw connections between the blocks to specify the flow of data.
For this lab, we were interested in using Popfly to create a map mashup in which we could render a basic KML document. We also thought it would be cool to to add Amazon’s S3 (Simple Storage Service) into the equation. We decided to host our KML document and our map icons on S3. The original KML file which was copied to S3 for purposes of this experiment is a selection of landmarks, cities, and national parks from the Discovery Channel and can be obtained here.
There are several user-submitted KML parsing blocks available in Popfly, but these components do not seem to work for many KML documents (this is probably due to the MIME type often assigned to the .kml extension). To get around this, we created our own Popfly block to accomplish this task. The block is shared in Popfly and its name is “IDV KML Parser” if you would like to reuse it. Those who are interested in developing their own Popfly blocks can obtain the Popfly block sdk here. You can get a .zip file with the .xml and .js files used in our block here.
Once our KML parser block was complete, all that was needed was to drag an instance of that block and Microsoft’s Virtual Earth block onto our workspace and configure a connection between the two blocks.

After pointing the KML URL to the document which we had copied to S3 (https://s3.amazonaws.com/KML/Discover_Networks.kml), our mashup was complete.
We created a second mashup in which we added a User Input block so that any KML file, provided that it only has <Placemark> objects that are points, can be visualized.

Give it a try!
Popfly provides users with a very visual and intuitive method of creating mashups of their data. And with the concept of blocks, users that are less technically inclined can build projects out of existing blocks and the more ambitious users out there can create their own blocks (which they can then share) to accomplish a tasks for which there is not yet a block. So what are you waiting for? Get mashing!
|