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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T04:22:18+00:00 2026-05-28T04:22:18+00:00

I have 3 columns. <div id=catalog> <ul id=author> <li>Different Author names</li> …. </ul> <ul

  • 0

I have 3 columns.

<div id="catalog">
    <ul id="author">
        <li>Different Author names</li>
        ....
    </ul>
    <ul id="genre">
       <li>Different Genres</li>
    </ul>
    <ul id="publish">
       <li>Different Publishers<li>
    </ul>
</div>

I use jquery to drag and drop the items from these list to different list cart like this

    $(function() {
        $( "#catalog li" ).draggable({
            appendTo: "body",
            helper: function( event ) {
                    return $( "<li class='bit-box'>" + $(this).text() + "</li>" );
            },
      cursorAt: { cursor: "move", top: 5, left: 5 }
        });
        $( "#cart ul" ).droppable({
            accept: ":not(.ui-sortable-helper)",
            drop: function( event, ui ) {
                $( this ).find( ".placeholder" ).remove();
        $( this ).find( "li:contains('" + ui.draggable.text()  + "')" ).remove();
                $( "<li class='bit-box'></li>" ).text(ui.draggable.text()).append("<a class='closebutton' href='#' onclick='$(this).parent().remove();'></a>").appendTo( this );
            }
        });

Is there any any way to figure out which list the are dropped item belongs to.

I appreciate any help.

  • 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-28T04:22:19+00:00Added an answer on May 28, 2026 at 4:22 am

    Try using this in the drop handler:

    ui.draggable.closest('ul').attr('id')
    

    It should give you an id of the list that dropped item belongs to.

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

Sidebar

Related Questions

I have an issue with two adjacent div columns. It is a common use
I have these div blocks called columns where each column div contains separate two
I have a fixed width DIV containing a table with many columns, and need
I have this gridview: <div class=content> <asp:GridView ID=DocumentGrid runat=server AutoGenerateColumns=False OnRowCommand=DocumentGrid_RowCommand > <Columns> <asp:BoundField
I have two div columns sidebar(left) and page-content(right). I toggle removing and adding 'sidebar'
Hi here's what I'm trying to accomplish. I have a div with ID=columns, in
I have 3 columns that look something like this: <div style=width:900px;margin:0 auto id=container> <div
Im searching for a way to have 2 divs as columns where div on
I have the following aspx : <div id=columns runat=server> <ul id=column1 class=column > <!--
I have a website with two columns, within a wrapper div. The wrapper has

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.