You call yourself a student?
In such situations, I've found that honesty is the best policy. I've told many a teacher that I didn't attend their class because I was asleep, or that I got a great new book and didn't want to interrupt my reading to come to class. Most of them at least appreciate that I don't lie to them. Of course, there are a few that get angry because I am so flippant with what they consider 'important work'. Those I merely ignore.
If you really feel the need to do so, check out some of the old Knights of the Dinner Table - at one point, they wrote a Book of Excuses for Bob, so that he could successfully lie to his parents to leave the house to game. Perhaps you'll find something of use there.
By the way, what manner of odd place are you at where you have to justify a lack of attendance, particularly at a course on HTML?