add javascript enent function blog answer