Dan is correct. HTML doesn't directly communicate with the server so you'll have to write a CGI script (I suggest PERL since it's part of the installation of most UNIX implementations) and call it through a form tag, link, or even a javascript event.
There's always a better way. The fun is trying to find it!