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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T11:26:15+00:00 2026-05-31T11:26:15+00:00

I have a script which allows to display bing search results: JsFiddle If you

  • 0

I have a script which allows to display bing search results: JsFiddle

If you type a letter you will see the results for this letter. If you then do backspace and then type the same letter you will not get any results, so:

  1. type letter = results
  2. backspace = remove results
  3. typing same (first) letter = NO results

This happens becouse I set a code to take clear the results if the val of input is empty like this:

$('#searchbox').live('keyup', function(){

var teq = $('#searchbox').val();

     doSearch(teq); 


    if (teq == '')
    {
        clearResults();
    }

}); 

So by clearing the results like this I’m actually causing a problem the same time becouse there are no results for the second time a same query is made. So my question is: How can I clear the results in a way that I would still be able to do the same query? Which means:

  1. type letter = results
  2. backspace = remove results
  3. typing same (first) letter = results
  • 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-31T11:26:16+00:00Added an answer on May 31, 2026 at 11:26 am

    You have in your code this comment:

    // if our search is not blank AND is not what we last searched for
    

    therefore I changed the statement

    if ((search!='') && (search!=lastSearch))
    

    to:

    if ((search!=''))
    

    You can see the result: http://jsfiddle.net/F9T7E/10/

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

Sidebar

Related Questions

I have this script which allows to display Bing search results: JsFiddle Demo The
I have a script which allows to display Bing search results: JsFiddle I want
I have script which allows to display Bing search results. I can call for
I have a script which allows to display search results on keyup: JsFiddle I
I have a script which allows to display search results. Given a query there
I have a script which allows to display Google suggestions: JsFiddle I want to
I have a script which allows to display Google suggestions. The problem is that
I have a script which allows to display favicon based on the url over
I have a script which allows to display favicons based on the url: Example
I currently have a script which allows me to output the list of files

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.