..except in the case of PDA, WAP, text-mode, and browsers with Javascript disabled (such as High-Security IE, Mozilla's new Javascript function granularity, etc.)

Javascript solutions are only applicable when you can absolutely, posititively, 100% verify the client configuration.. i.e. locked down intranet usage. Anything else is just a "best-guess" approach.

Rule 1: Never trust the client (config)

Your solution may work, but isn't bulletproof. I'm accustomed to having to code my web-based work against a minimum of 11 browsers (IE, Konqueror, Galeon, Opera, Dillo, Mozilla, Netscape, Lynx, Links, Amaya, and w3m). In my case, pages must validate to XHTML 1.0 Transitional and be 100% CSS1 and CSS2 compliant. Very strict requirements, but the end result is near-perfection (and yes, the pages look good too, and I don't have to use tables or Javascript)

Another approach to this is to take a simple submit form, and send the user to a confirm form, which has an expiration set. If the user clicks Back and tries to resubmit, the confirmation form will fail. Instead of submitting directly from the main entry form, submit the values from a "Are these values correct?" type of page.

TMTOWTDI.


In reply to Re: just disable the button! by hacker
in thread Avoiding a second click by MMilani

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.