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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T16:45:13+00:00 2026-05-11T16:45:13+00:00

I am trying to add a click event to a LI element but it

  • 0

I am trying to add a click event to a LI element but it is not firing in the page. My page markup looks like:

<div id="Navigation">
<ul>
    <li class="navPrevNext inactive">|&lt; First Page</li>
    <li class="navPrevNext inactive">&lt; Prev Page</li>
    <li class="navIndex selected" title="0 ">1</li>
    <li class="navIndex notselected" title="1 ">2</li>
    <li class="navIndex notselected" title="2 ">3</li>
    <li class="navPrevNext active" title="1">Next Page &gt;</li>
    <li class="navPrevNext active" title="2">Last Page &gt;|</li>
</ul>
</div>

And in my JS code I have:

$("#Navigation li").live('click', function(e) { e.preventDefault; this.blur(); return updateNavigation($(this).attr('title')); });

Any thoughts?

TIA

  • 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-11T16:45:13+00:00Added an answer on May 11, 2026 at 4:45 pm

    You sure you have jquery 1.3 included in your code? The following works fine (direct copy and paste from your question) for me when I click on any of the LIs:

    <html>
    <head>
    <script type="text/javascript" src="jquery-1.3.2.min.js"></script>
    <script type="text/javascript">
    function updateNavigation(title) {
        alert(title);
    }
    
    $("#Navigation li").live('click', function(e) { 
        e.preventDefault; 
        this.blur(); 
        return updateNavigation($(this).attr('title')); 
    });
    
    </script>
    </head>
    <body>
    <div id="Navigation">
    <ul>
        <li class="navPrevNext inactive">|&lt; First Page</li>
        <li class="navPrevNext inactive">&lt; Prev Page</li>
        <li class="navIndex selected" title="0 ">1</li>
        <li class="navIndex notselected" title="1 ">2</li>
        <li class="navIndex notselected" title="2 ">3</li>
        <li class="navPrevNext active" title="1">Next Page &gt;</li>
        <li class="navPrevNext active" title="2">Last Page &gt;|</li>
    </ul>
    </div>
    </body>
    </html>
    

    Are you sure your updateNavigation function is working right? Maybe it’s being triggered but something is wrong within it…

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

Sidebar

Related Questions

I am trying to add a click event on the element that is return
I'm just trying to add a double click event to a HTML5 Canvas element.
I am trying to add click event to one of the widgets that use
I'm trying to add a $('body').live('click') listener after the user clicks on a div.
Trying to add a class object into a List using reflection, but when invoking
I have a div element, that on click event, a link slides in. This
I'm trying to add an function to an a click event to my code.
I have this js code to add (clone) and delete an element. $('#btnAdd1').click(function (event)
Im trying to add click events to shapes within a visio file.. I have
I'm trying to add in a double click on a node in the force

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.