我正在寻找以下jQuery equivellent。请帮忙。
var request = document.getElementById('request_' + id1)
var response = document.getElementById('response_' + id1);
modifyText(request.firstChild.nodeValue,response.firstChild.nodeValue);
答案 0 :(得分:4)
尝试
var request = $('#request_' + id1)
var response = $('#response_' + id1);
modifyText(request.find(':first-child').text(),response.find(':first-child').text());
答案 1 :(得分:1)
var request = $('#request_' + id1);
var response = $('#response_' + id1);