jQuery event.resultคุณสมบัติ

❮ วิธีการจัดกิจกรรม jQuery

ตัวอย่าง

ส่งคืนค่าของเหตุการณ์การคลิกก่อนหน้า:

$("button").click(function(){
  return "Hello world!";
});
$("button").click(function(event){
  $("p").html(event.result);
});

ความหมายและการใช้งาน

คุณสมบัติ event.result มีค่าสุดท้าย/ก่อนหน้าที่ส่งคืนโดยตัวจัดการเหตุการณ์ที่ทริกเกอร์โดยเหตุการณ์ที่ระบุ


ไวยากรณ์

event.result

Parameter Description
event Required. The event parameter comes from the event binding function

❮ วิธีการจัดกิจกรรม jQuery