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

  • Home
  • SEARCH
  • 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 7884693
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T04:52:09+00:00 2026-06-03T04:52:09+00:00

For instance, if a user submits a post, there should be a delay period

  • 0

For instance, if a user submits a post, there should be a delay period of maybe 10 minutes in which he or she cannot submit another post.

Could someone point me to a good gem/tutorial/method? For reference, I’m on Rails 3.

  • 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-06-03T04:52:10+00:00Added an answer on June 3, 2026 at 4:52 am

    If your tracking by user, you can keep a column called last_active which is a datetime field, and update it when the user submits the form. (Assuming there aren’t a lot of form,s, then maybe think about giving these timestamps their own model).

    Then, just perform date math to see if ten minutes has gone by.

    user.last_active + 10.minutes > Time.now ? "User can post" : "User cannot post"

    Note: Not in front of a console, that might be 10.minute

    Then your form logic:

    def form_stuff
      //Form Logic
      @user.last_active = Time.now
    end
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

When using SQL Server Express 2005's User Instance feature with a connection string like
Most web applications depend on some kind of session with the user (for instance,
Documentation states: Adds a user-defined custom member to an instance of a Windows PowerShell
For instance, let's say I have a User model. Users have things like logins,
From the perspective of an API end-user who needs to get an the instance
Alright all you wonderful people out there; In my user interface I am building
I am try to have a forum submits more then once when a user
I implemented a page to create an instance of an entity and a user
My website needs to have a form that automatically submits, sending the user (with
I am doing the following: <script type=text/javascript> $(function(){ $(#ipad).submit(function() { $.post(ipadcheck.php, $(#ipad).serialize(), function(data) {

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.