$("img").click(function() {
var ipath = $(this).attr('src');
$.ajax({ type:'POST', url: 'sample.php',
dataType: 'HTML',
data : {
path: ipath
},
success: function(data)
{
}
});//end of ajax
})//end of click
You can get this value in php script as $_POST['path']