Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^3: /perl5.10/bin and linux

by haukex (Archbishop)
on Jul 23, 2018 at 20:41 UTC ( [id://1219144]=note: print w/replies, xml ) Need Help??


in reply to Re^2: /perl5.10/bin and linux
in thread Reaped: /perl5.10/bin and linux

Visit Nodes You Wrote, Recently Active Threads, Newest Nodes, and/or Message Inbox to keep an eye on your posts. Once you've posted something, don't reload the page (normally, browsers should warn about resubmitting form data anyway). See also PerlMonks for the Absolute Beginner.

Replies are listed 'Best First'.
Re^4: /perl5.10/bin and linux
by afoken (Chancellor) on Jul 24, 2018 at 06:30 UTC
    Once you've posted something, don't reload the page (normally, browsers should warn about resubmitting form data anyway)

    I think this is a bug.

    The usual way to handle a successful HTTP POST request is to redirect to a page that will be fetched via GET (instead of delivering the content directly in reply to the POST request). Reloading that page has no side effects like reposting. See also Post/Redirect/Get.

    Another option that needs more effort and more code is to include a token in the HTTP form that is send via POST, and to invalidate the token once it has been sent.

    Alexander

    --
    Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)

      It's more a worst practice than a bug. The browser does warn when resubmitting a POST. So the user has some control/feedback.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1219144]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having an uproarious good time at the Monastery: (3)
As of 2024-04-19 21:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found