<td class="td1">
<input name="CheckBox" id="c1" type="checkbox" CHECKED="" value="on"/>
<a class="a_c" id="a1">
</td>
Run Code Online (Sandbox Code Playgroud)
如果我知道复选框的ID,$(#c1)那么如何获取Anchor标签的文本?
struct node
{
int data;
struct node *next;
};
Run Code Online (Sandbox Code Playgroud)
以下两个功能有什么区别:
void traverse(struct node *q)
{ }
Run Code Online (Sandbox Code Playgroud)
和
void traverse(struct node **q)
{ }
Run Code Online (Sandbox Code Playgroud)
如何从主程序中调用上述函数?
$(oTrPlanning).prev().children('td').each(function () {
this.onclick = setCountClick;
});
Run Code Online (Sandbox Code Playgroud)
点击TD setCountClick()被称为但是TD还包含Textbox:
<td>
<input class="Input-InlineFilter" id="TextFirst" type="text" value="">
</td>
Run Code Online (Sandbox Code Playgroud)
所以,当我开始输入内容时Textbox,setCountClick()再次调用.我想在setCountClick()点击TD时打电话,但不是Textbox.
我正在使用这样的承诺:
var restClient = {
serveRequest: function(rUrl, type, body, rHeaders, rAsync, callback) {
var promise = jQuery.ajax({
url: rUrl,
type: type,
data: body,
headers: rHeaders,
async: rAsync,
contentType: "text/plain",
dataType: "json"
});
promise.then(onSuccess, onError);
},
onSuccess: function(data) {
callback(data);
},
onError: function(msg) {
console.log(msg.responseText);
}
}
Run Code Online (Sandbox Code Playgroud)
如何在promise.then onSuccess中传递参数(回调)?我想稍后在onSuccess方法中使用它.