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 9067323
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T16:54:31+00:00 2026-06-16T16:54:31+00:00

I have a input text box. After the user is idle from typing I

  • 0

I have a input text box. After the user is idle from typing I want it to submit the form(which works in the below code) and a image of a checkmark to popup then fadeout. I was just trying to test the fadeout function so the img is visible but I can’t seem to get it to work.

var timer = null;
$('.form_timer').keyup(function()
{
    if (timer) {
        clearTimeout(timer);
    }

    var test = $(this);
    timer = setTimeout(function() {
        test.next('img').fadeOut('slow');
        test.closest('form').submit();

    }, 700);
});

:EDIT#1 Markup

<div class="accordion">
    <div class="group">
        <form accept-charset="UTF-8" action="/tasks/2" class="simple_form edit_task" data-remote="true" id="edit_task_2" method="post" novalidate="novalidate"><div style="margin:0;padding:0;display:inline"><input name="utf8" type="hidden" value="&#x2713;" /><input name="_method" type="hidden" value="put" /><input name="authenticity_token" type="hidden" value="Fil9PitLB6ZhHtWwBOehbOBkq2yE6qikN5cU0zr4wRQ=" /></div>
            <h3><div class="input string optional"><label class="string optional control-label" for="name_2">Task Name</label><input class="string optional form_timer" id="name_2" name="task[name]" placeholder="New Task" size="50" type="text" value="somethingdd" /></div></h3>
            <div>
                <div class="input string optional" style="display: inline"><label class="string optional control-label" for="description_2">Description</label><input class="string optional form_timer" id="description_2" name="task[description]" size="50" type="text" value="blah123asdfgokkkkkasddadsdd" /></div><img alt="checkmark" class="form_checkmark" height="20px" src="/assets/checkmark.jpg" width="20px" />
            </div>
        </form>
    </div>
</div>        
  • 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-16T16:54:32+00:00Added an answer on June 16, 2026 at 4:54 pm

    Updated my code to use parent then next. Seems .next works differently then I expected. I still don’t like this as a solution because the textfield could possibly be two levels deep in divs or etc…

    var timer = null;
    $('.form_timer').keyup(function()
    {
        if (timer) {
            clearTimeout(timer);
        }
    
        var test = $(this);
        timer = setTimeout(function() {
            test.parent().next('.form_checkmark').fadeOut('slow');
            test.closest('form').submit();
    
        }, 700);
    });
    

    EDIT#1 Did some more digging
    Doesn’t look like there is a easy solution for what I wanted. Found a solution someone else posted after I knew what i was looking for. Found here

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

Sidebar

Related Questions

I have a text box. I want to take user input from there and
I have a text-box into which a user can input a comment. The comment
I have a text input field like text box or text area. I want
At the moment I have a slider and an small input text box which
I have a drop down box and some text input fields below it. Based
I have a login form, which contains simple text box, that shows the text
i have a text input box for entering the currency. it shud allow user
I have created a multi-select list, input text box and a add button. User
I have an input text box for search of input, the id of the
I have a form with the following dynamically added row: <input type=text name=statuseffective id=statuseffective_0

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.