是否可以在jquery上下文菜单中提及多个选择器,如果是,那么任何人都可以告诉我如何操作。
由于
编辑: 以下是代码
$.contextMenu({
selector: '.recur',
className: 'css-title',
callback: function (key, options) {
var vKey = key;
//var vLinkedId = options.$trigger.attr("linkedid");
var vLinkedId = $(this).children().children("div:first").attr('linkedid');
var vmeetingtitle = $(this).children().children("div:first").attr('meetingtitle');
var vurl = '/SitePages/Send%20Email.aspx?linkedid=' + vLinkedId + '&date=' + $("#<%= txtDate.ClientID %>").val() + "&type=" + vKey;
var vtitle = vmeetingtitle + ' - ' + vKey + ' email';
//var Date
OpenDialog(vurl, 600, 300, vtitle);
},
items: {
"Confirmation": {
name: "Confirmation",
accesskey: "Confirmation"
},
"Catering Cancelled": {
name: "Catering Cancelled",
accesskey: "Catering Cancelled"
},
"Catering Requirements Amended": {
name: "Catering Requirements Amended",
accesskey: "Catering Requirements Amended"
},
"Room Changed": {
name: "Room Changed",
accesskey: "Room Changed"
},
"Time Changed": {
name: "Time Changed",
accesskey: "Time Changed"
},
"Room and Time Changed": {
name: "Room and Time Changed",
accesskey: "Room and Time Changed"
},
"Facilities Cancelled": {
name: "Facilities Cancelled",
accesskey: "Facilities Cancelled"
},
"Facilities Changed": {
name: "Facilities Changed",
accesskey: "Facilities Changed"
}
}
});
答案 0 :(得分:3)
与普通的jQuery代码一样,您可以使用多个这样的选择器:
selector: '.recur, #theOtherone, .thisClassToo'