I would like to ask you, now you need to let the second td of each tr in table echo the content at another div when the mouse moves up. I use ajax and mouseover, and then use id to locate the td, code as follows:
$(document).ready(function(){
$("-sharptdid").mouseover(function () {
var $val = $.trim($("-sharptdid").text());
$.ajax({
type: "post",
url: "getinfo.php",
data: {val:$val},
success: function (data,status) {
$("-sharpshowinfo").html(data);
},
error: function () {
alert("error");
}
but this is only the first time that td can successfully call ajax, and no other td sends packets, that is, it does not call ajax. (if you look at the source code, you can see that the second td of each tr has id=tdid.) Why? Or is there a better way to realize this need? Thank you so much!