License Gadget

In the last post, I wrote down the reasons for my choice of a Creative Commons By-Nc license. This post is about the details on how I managed to place the license text in the blog.

I checked the Creative Commons site (CC) to look up license types and details and found out - as I was expecting - that the site offers the service to generate the HTML code to be inserted into a web page in order to display a license text and link to the Commons Deed provided by CC.

Once I had the code for the license I chose I googled for instructions on how to publish the license text into a Blogger blog. All the information I found was either staled (talking about setting options which are no longer available) or suggested to manually edit the blog template.

I checked the blog settings provided by Blogger and tried to paste the license HTML code into the text box left for customisation of the 'Attribution' blog footer section.

It turned out that text size limit does not admit to include the whole license code. So after experiencing a slight frustration feeling I figured out there might be a Google Gadget to display the blog license, since Blogger seems to set up the blog layout based on Gadgets.

I found none and thought that it might not be too hard to create one that just displayed the copy/pasted license HTML code. So I decided to create my first Google Gadget. I found all the information I needed at the Google gadgets.* API Developer's Guide.

My knowledge on HTML, CSS and Javascript was quite forgotten. It's never been too much anyway, I just learned the basics in college. So I had to check out a couple of online tutorials.

First and more surprising issue I encountered was that I couldn't get the Google Gadget Editor (GGE) to work properly on the Chromium browser! Somehow, weird invisible characters were being inserted/removed when I saved changes so the Gadget's XML code failed to be parsed. So after a while trying to figure out what was going on, I gave up and assuming my perplexity, I tried out Firefox and it worked perfect.

Then I had issues dealing with Javascript code errors, which are annoyingly silent for someone like me, since I'm used to work with compiled languages and have that really nice help that are compiler errors.

But after struggling with the new development environment (GGE), languages with which I'm not familiar, and a tough testing environment (Google Gadget Checker helped), I finally managed to get a basic Google Gadget that displayed a Creative Commons license text and links. The Gadget allows the user to chose the kind of CC license to display. You can see how it looks at the bottom of this page.

I have submitted it to the Google Gadgets directory and it might be available there at some point. Meanwhile, it can be included in any Blogger blog using this URL: http://hosting.gmodules.com/ig/gadgets/file/115386175924349751853/cc.xml.

You can also include it in any webpage (not necessarily a Blogger blog) clicking here.

No comments:

Post a Comment