Torch`Ok,
<!DOCTYPE HTML>
<html>
<head>
<title></title>
<script src="http://code.jquery.com/jquery-latest.js" type="text/javascript"></script>
<script type="text/javascript">
$(function () {
$('#submit').bind('click',function(e){
e.preventDefault();
var dataString = '';
var divs = $('div.image');
divs.each(function (index, self) {
var img = $(self).children('img') ;
var css = img.css(['width', 'height','top','left'])
var id = $(self).attr("id");
var src = img.attr("src");
var data = {
'id' : id,
'src' : src,
'width' : css['width'],
'height' : css['height'],
'top' : css['top'],
'left' : css['left']
}
dataString += JSON.stringify(data);
});
alert(dataString); //для теста
$('#jsondata').val(dataString);
});
});
</script>
</head>
<body>
<div id="img1" class="image"><img src="image1.png" /></div>
<div id="img2" class="image"><img src="image2.png" /></div>
<div id="img3" class="image"><img src="image3.png" /></div>
<div id="img4" class="image"><img src="image4.png" /></div>
<div id="img5" class="image"><img src="image5.png" /></div>
<a id="submit"><span>click</span></a>
<form id="jsonform" action="merge.php" method="POST">
<input id="jsondata" name="jsondata" value="" autocomplete="off">
</form>
</body>
</html>