Question

I am a web programer and was busy making div windows that could be dragged or resized using jquery ui. I have tested my website in other browsers with positive results.

Here is the html

     <div id="w2">blabalblablaaba</div>

Here is the javascript.

   $(function() {
$( "#w2" ).draggable();
  });

And yes I have linked the jquery ui stylesheet and javascript sheets. Please help that would be great!

Était-ce utile?

La solution

Works fine with JQuery 1.9.1 + JQuery UI 1.9.2 in Opera 12.17 and Opera 20

HTML:

<div id="w2">blabalblablaaba</div>

CSS:

#w2 {
   border:2px solid red;
   width: 150px;
   height: 150px;
   padding: .5em;
   background:yellow
}
#w2:hover {
   cursor:pointer
}

JS:

$(function() {
    $( "#w2" ).draggable();
});

test it at http://jsfiddle.net/q8Thy/2/

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top