One way to do this without using javascript:
before you reach your page with the two buttons, generate a token (it can be a random number), store it in a session, and place it as a hidden value in your form.
When the user clicks the first button, get the value from the session and compare it with the hidden value. If they're the same, it means it's the first button that it was clicked.
remove the token from the session.
If the user gets to click the second button, your code will check again the hidden value against the one in the session.
But, since you've removed the token from the session already, the values won't be the same. You can discard this request, since you know it was the second click and not the first.
easy
[ September 09, 2003: Message edited by: Andres Gonzalez ]