Creative Commons provides a guide to licensing your work, and the guide includes code generation. The WordPress.com FAQ on Creative Commons gives instructions about stripping out some of the code generated. Even so, it took me longer than it should have to get the linked image into a sidebar text widget, since WordPress.com kept on taking a dislike to the code and stripping out some of it.
There is a Creative Commons widget for WordPress. Nathan Yergler, who wrote the widget, also wrote the following:
My thanks and support go to Nathan.