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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T23:35:05+00:00 2026-06-15T23:35:05+00:00

I created code to show jquery dialog on click of a div. Right now

  • 0

I created code to show jquery dialog on click of a div. Right now dialog pops at 5 points after the click position.

I am trying to display dialog from top line of li, it means the top border of li should be aligned with top border of dialog. Could some one point me to right logic to find out how to open dialog by getting li top border position.

  <div class="editionDetailAction">Action for Item 1</div>
<div class="editionDetailAction">Action for Item 2</div>
<div class="editionDetailAction">Action for Item 3</div>
<div class="editionDetailAction">Action for Item 4</div>



<div id="actionsPopup">
    <ul><li><a href="http://www.google.com">Add xyz</a></li></ul>
    <ul><li>Manage xyz</li></ul>
    <ul><li>Show xyz</li></ul>
</div>


.editionDetailAction { width: 130px; height: 30px; border: solid 1px #ddd; }
.actionsPopup .ui-dialog-titlebar { display:none; }



$(document).ready(function () {
    $('.editionDetailAction').click(function (e) {
        $("#actionsPopup").dialog("option", { position: [e.pageX+5, e.pageY+5] });
    });

    $("#actionsPopup").dialog({
            autoOpen: false,  
dialogClass: 'actionsPopup',
        maxWidth:100,
                    maxHeight: 100,
                    width: 100,
        height: 80,
resizable: false,


    });
    $(".editionDetailAction").bind("click", function () {
        $("#actionsPopup").dialog('open'); 
    });
    $(".actionsPopup").bind("mouseover", function () {
        $("#actionsPopup").dialog('open');
    }); $(".actionsPopup").bind("mouseleave", function () {
        $("#actionsPopup").dialog('close');
    });

    $(".editionDetailAction").bind("mouseleave", function () {
        $("#actionsPopup").dialog('close'); 
    });


   });
  • 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-15T23:35:06+00:00Added an answer on June 15, 2026 at 11:35 pm

    Try this:

    $('.editionDetailAction').click(function() {
        var pos = $(this).position();
        $("#actionsPopup").dialog("option", {
            position: [pos.left+5, pos.top+5]
        });
    });
    

    See example: http://jsfiddle.net/Twisty/DZm9d/1/

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

Sidebar

Related Questions

I want to show a JQuery dialog conditionally on click event of an hyperlink
I've created an HtmlHelper that helps me show a jQuery modal dialog: I set
I have created ajax code for my city tabs to display respective city data
I've created a code to change a password. Now it seem contain an error.before
The jquery popup I created using the jquery show function, fades away in few
I'm kinda new to jquery and I have created an hide/show animation for a
i'm trying to create a modal dialog with jquery mobile rc2. This is my
I am currently trying to hook up jQuery UI dialog so that I may
I have the following jQuery code to execute when I click a button $('#substat').click(function()
I created progressbar with help of lib jquery.knobs.js: example this is my code: <script

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.