You can add as many classes to a html element as you need, you just separate the class names with a space. Let's say you have 2 classes:
You could add these to a single HTML like this:
<p class="coloring yellow_bg">This is some text</p>
To make the script run when the image is clicked you need to put your image WITHIN the <a>nchor tag.
<img class="sideAdvert" src="images/join-free-advert.png" alt="join-free-advert" width="300" height="220" />