You would need to do this on the server (using scripting: ASP, PHP, etc.). You can't do this directly in HTML (even with JavaScript). You could do it in JavaScript on the client, but the ansers to the questions would have to be visible in the JavaScript, so anyone could find them out...