[Solved] Save position of element with Jquery, PHP and MySQL [closed]


I don’t know what do mean by “saving position of an element” and how can that be useful, but you can try jQuery position() and $.ajax() methods:

Get the current coordinates of the first element in the set of matched elements, relative to the offset parent.

var t = $('a.icon').position().top;
var l = $('a.icon').position().left;

$.ajax({
  type: "POST",
  url: "save.php",
  data: { top: t, left: l}
}).done(function() {
  alert( "Position Saved");
});

solved Save position of element with Jquery, PHP and MySQL [closed]