I have the code below that is working perfectly, that is, whenever I move the images I have the left and top scales of the same ones. But this is appearing with LI and I need it to appear in the VALUE of an INPUT TYPE = TEXT, as I need to send the result to the database via PHP and MYSQL.
If friends can help me, I'll be very grateful.
Hugs to all.
jQuery
$('#img').draggable({
drag: function () {
var offset = $(this).offset();
var xPos = offset.left;
var yPos = offset.top;
$('#posX').text('Hori: ' + xPos);
$('#posY').text('Vert: ' + yPos);
}
});
});
HTML
<li id="posX">Hori: 0</li>
<li id="posY">Vert: 0</li>