When you edit the template file, it is not considered hacking in the code (obviously you do have to edit those files to change your template anyway).

The reason why I did not give the specific code because such code can have unexpected behavior on different browsers, so I usually do it using jquery or some other frameworks (which take care of the compatibility issue for me)

Also, after looking closely at your code, you may not even have to put it in the body onload, you can put that whole thing at the bottom of your page as well.

Code:
<a href="http://www.instantssl.com" id="comodoTL">SSL</a>
<script language="JavaScript" type="text/javascript">
COT("images/cornertrust.gif", "SC2", "none");
</script>
Some may argue that it's not good to do so, but if you have GoogleAnalytics or AdSense on your page you do the same thing anyway.