Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 428365
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T19:40:07+00:00 2026-05-12T19:40:07+00:00

This is related to preventing webform resubmission , however this time the context is

  • 0

This is related to preventing webform resubmission, however this time the context is a web-based RPG. After the player defeats a monster, it would drop an item. So I would want to prevent the user from hitting the back button, or keep refreshing, to ‘dupe’ the item-drop.

As item drop is frequent, using a DB to store a unique ‘drop-transaction-id’ seems infeasible to me. I am entertaining an idea below:

  1. For each combat, creating an unique value based on the current date-time, user’s id and store it into DB and session. It is possible that given a userid, you can fetch the value back

  2. If the value from session exists in the DB, then the ‘combat’ is valid and allow the user to access all pages relevant to combat. If it does not exist in DB, then a new combat state is started

  3. When combat is over, the unique value is cleared from DB.

  4. Values which is 30mins old in the DB are purged.

Any opinions, improvements, or pitfalls to this method are welcomed

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T19:40:07+00:00Added an answer on May 12, 2026 at 7:40 pm

    This question is very subjective, there’s things you can do or can not do, depending on the already existing data / framework around it.

    The solution you’ve provided should work, but it depends on the unique combat/loot/user data you have available.

    I take it this is what you think is best? It’s what I think is best 🙂

    1. Get the userID, along with a unique piece of data from that fight. Something like combat start time, combat end time, etc
    2. Store it in a Database, or what ever storage system you have
    3. Once you collect the loot, delete that record

    That way if the that userID, and that unique fight data exists, they haven’t got their loot.

    And you are right; tracking each piece of loot is too much, you’re better off temporarily storing the data.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I posted this as comments under this related thread . However, they seem to
This question is an extension of this Related question . Taking Derick's advice, I
I found this related question: How do I use composition with inheritance? I would
I have searched here, GooBingHooVista'd the world and read this related question for VS
This is related to this question but with a different take. In Ubuntu, I
This is related to OpenId authentication. I have implemented the google and yahoo openId
This is related to Clang 3.1 and C++11 support status , but I could
This is related to my other question but I am openning a new one
This is related to this question I asked earlier about syntax highlighting user-defined blocks
This is related to my previous question I'm solving UVA's Edit Step Ladders and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.