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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T22:09:19+00:00 2026-06-09T22:09:19+00:00

My code: http://jsfiddle.net/hayleyeaston/nkfms/4/ I am putting together a postcode lookup where a user inputs

  • 0

My code:
http://jsfiddle.net/hayleyeaston/nkfms/4/

I am putting together a postcode lookup where a user inputs a postcode and then clicks a button to trigger a postcode search. I’ve got an event handler on the click but I also want to add one for blur on the input field, in the case where a user might enter their postcode but not actually click ‘Lookup’. This is to ensure that a postcode search occurs before the user tries to submit the whole form.

My problem is when a user enters a postcode and clicks the ‘Lookup’ button I get both blur and click events running. I see ‘search postcode’ in my console log twice. How can I fix this so that the blur only occurs if the user didn’t click the ‘Lookup’ button.

My code is in the JSFiddle link above. Please can anyone help, its been driving me crazy for the last few days. It has occurred to me to check on form submit if the postcode search has occurred, but ideally if possible I’d like to fix the blur/click issue. Thanks.

  • 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-09T22:09:20+00:00Added an answer on June 9, 2026 at 10:09 pm

    Remove the click() event – you don’t need it.

    My fiddle: http://jsfiddle.net/Grimdotdotdot/UKGYN/

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

Sidebar

Related Questions

here is the code: http://jsfiddle.net/4WyPq/ So basically when I click 'button1' it animates then
Consider the following code ( http://jsfiddle.net/FW36F/1/ ): <input type=checkbox onchange=alert(this.checked)> <button onclick=document.getElementsByTagName('input')[0].checked=!document.getElementsByTagName('input')[0].checked;>toggle</button> If you
Here is my code: http://jsfiddle.net/sZKeM/1/ So basicly it shows box when I hover button
here is the code: http://jsfiddle.net/sxqwp/1/ My question is when I press 'close' then press
This code : http://jsfiddle.net/bYtTG/1/ Works as I want in FF, chrome and opera, but
Here's my code : http://jsfiddle.net/d6j6e/ When you click on the gray little rectangle in
See here for code: http://jsfiddle.net/ecFBK/10/ I'm having a hard time getting this to work
here is the code: http://jsfiddle.net/bfQMD/11/ Im using flip pluging and how to change opacity.
This is my fiddle code http://jsfiddle.net/coderslay/WnC9B/44/ It is successfully plotting the graph. The problem
I have the following code: http://jsfiddle.net/uRCL2/1 At the moment the result is shown in

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.