Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

142
Views
Draggable items position mismatched

When dragging an element and dropping the droppable div. This drag element is also cloned and resizable into droppable div.

But each element dragged into a droppable div position overlapping on the top of the box, not set a current position when the element clone and dragged to drop into the droppable div.

Is any way to solve the dragging item drop to a fixed position?

HTML

<div class="fields mb-md-1 pb-1" id="item1"> 
//drag item
  <div class="item-info"> 
    <input type="text" class="w-100 h-100 form-control" 
placeholder="Name"> 
  </div> 

  //droppable div
  <div class="file-viewer
position-relative" style="order: 2"></div>

jQuery

 $(".item-info").draggable({
     helper: 'clone',
     cursor: "move",
 });
 
 $(".file-viewer").droppable({
     accept: ".item-info",
     drop: function(e, ui) {
         $(this).append($(ui.draggable).clone());
         $("#myList1 .item-info").addClass("new_item");
         $(".new_item").removeClass("ui-draggable item-info");
         $(".new_item").resizable({
             handles: "all",
             autoHide: true
         });
         $(".new_item").draggable({});
     }
 });
about 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!