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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T15:05:33+00:00 2026-06-04T15:05:33+00:00

I have a tag-based search form (just like the tag-based text boxes you see

  • 0

I have a tag-based search form (just like the tag-based text boxes you see on Facebook or S/O where you enter a word and press the corresponding delimiter key on the keyboard)

On my website, you type a word in the text field, and press enter to ‘confirm’ or ‘accept’ that keyword, which enables you to enter another.

The problem with this is, that even though you may have finished entering your search query, pressing enter does not submit the form (obviously), because e.preventDefault() has been enabled so i can use enter button to accept/confirm each tag.

What I want to do is, instead of (albeit, slightly) inconveciencing my users, is to submit the form when they press enter if they have not entered any (or any new) tags.

I’ll try to explain it more clearly with this image:
enter image description here

Would this at all be possible?

  • 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-04T15:05:35+00:00Added an answer on June 4, 2026 at 3:05 pm
    $("#tags").keyup( function(e){
        if ( e.which === 13 ) {
            if ( /*value is not empty*/ ) { //add tag             
            } else {
                $("#formID").submit();
            }
        }
    });
    

    i think that this is what you are looking for

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

Sidebar

Related Questions

Say I have a base form of a word and a tag from the
I working on a tag based search. I have three tables tag(id,name), tagXmedia(id,tag_id,media_id), and
I have a anchor tag like this <a href= class=search gl> <img src=_gfx/cmn/goButton.png class=searchbutton
i have a li tag which was dynamically added. To that based on some
Lets say that i have img tag like this, <img src = myimage.jpg width
I have used fieldset tag in HTML page, whereby i need some text to
I need to do a search based on a term entered into a text
I have a application which allows user to make a search. Based on the
I have a search page which allows users to further filter thier results based
I want to write a tag based search engine in MySQL, but I don't

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.