Note that there are some explanatory texts on larger screens.

plurals
  1. POJQuery Jquery-UI Drag Drop Issue
    primarykey
    data
    text
    <p>This is my first introduction to JQuery.</p> <p>This page is under development <a href="http://www.guygar.com/eXistenZ/index.html" rel="nofollow noreferrer">here</a>.</p> <p>The issue: although the first element of the menu on the right side performs the drag and drop well:</p> <p>dragging it to the content area runs with success.</p> <p>As an side-effect all the images/icons on the page somehow became draggable also!</p> <p>The working of correct icons behaves the correct way; but the other icons can be dragged to any page of the page.</p> <p>Why is this happening please and how do I avoid it?</p> <pre><code>$( init ); function init() { $('#artOfBeing').draggable( {containment: '#dataFrame', cursor: 'pointer', snap: '#dataFrame'}); $('#sadWorld').draggable( {containment: '#dataFrame', cursor: 'pointer', snap: '#dataFrame'}); $('#dataFrame').droppable( { drop: handleDropEvent } ); } </code></pre> <p>Thank you for your insigtes and excuse the newbie question.</p> <p>Best regards.</p> <pre><code>function handleDropEvent( event, ui ) { var draggable = ui.draggable; alert( 'The square with ID "' + draggable.attr('id') + '" was dropped onto me!' ); } </code></pre> <p>Just tried Safari and Google Chrome and they are behaving with this issue as well.</p> <p>EDIT: <a href="https://stackoverflow.com/questions/3873595/how-to-disable-firefoxs-default-drag-and-drop-on-all-images-behavior-with-jquer">How to disable Firefox&#39;s default drag and drop on all images behavior with jQuery?</a> deals with this issue. it is the default behaviour of the browsers!</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload