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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T10:19:46+00:00 2026-05-24T10:19:46+00:00

So i am using ajax jquery .load() function to retrieve books using their ISBN

  • 0

So i am using ajax jquery .load() function to retrieve books using their ISBN the id in a jquery dialog. I am trying to return the value to a input box on the page the dialog is being opened on with no luck. When i click the links, nothing happens. Below is my jquery code.

      <script type="text/javascript">
$(document).ready(function(){

     // dialog init
    $('.choosebookbox').dialog({
        autoOpen: false,
        resizable: false,
        modal: true,
        width: 600,
        height:600,
        title: 'Choose a book',
        overlay: { backgroundColor: "#000", opacity: 0.5 }
    });
    // click event
     $('a#booksearch_lnk').click(function(){
            $('.choosebookbox').dialog('open').css('display','block');
                $('#tab2').load('post/topsellers.php');
                $('#tab1').load('post/newbooks.php');

                 $('a.choosebook').click(function(){
                    // alert($(this).attr('id'));
                    $("#isbn").val($(this).attr('id'));
                    $('.choosebookbox').dialog("close");
                });
        });
});
    </script>

and a sample book link that appears in the modal/dialog…

<a id="0439064864" class="choosebook" href="#">Harry Potter and the Chamber of Secrets (Book 2)</a>
  • 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-24T10:19:47+00:00Added an answer on May 24, 2026 at 10:19 am

    A guess is that your links are loaded with your ajax and so do not belong to the DOM initially. In this case try the live
    function.

    $('a.choosebook').live("click", function() {
      //do stuff
    });
    

    Did your commented out alert display anything?

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

Sidebar

Related Questions

I'm writing an app that loads in content via ajax using the jQuery.load function.
I am trying to load images through ajax call in jquery using This here
I am using jQuery to load a page by AJAX using $.ajax (suppose test.html).
I am using the jquery ajax api so load in some content, the code
I am using jquery-ui tabs and ajax to load the content of the tabs.
Greetings, Is there a different between using Ajax and jquery to do input valuation
How to pass multiple checkboxes using jQuery ajax post this is the ajax function
I'm using Jquery UI Tabs loading ajax content and I'm wondering how to retrieve:
I'm using the jQuery .load() function to pull in data to populate a div
I am preparing a script. I am using AJAX(load()) with jQuery. I am getting

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.