# Input text up or down event listener

**URL:** <https://forum.kirupa.com/t/input-text-up-or-down-event-listener/315658>\
**Category:** Uncategorized\
**Created:** [November 1, 2010, 4:59am UTC](https://forum.kirupa.com/t/input-text-up-or-down-event-listener/315658 "2010-11-01T04:59:51Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nim](https://avatars.discourse-cdn.com/v4/letter/n/67e7ee/32.png) [@Nim](https://forum.kirupa.com/u/Nim)\
**Post date:** [November 1, 2010, 4:59am UTC](https://forum.kirupa.com/t/input-text-up-or-down-event-listener/315658/1 "2010-11-01T04:59:51Z")

</div>

I’ve got an input text and I want to add an event listener when up(or down) arrow is pressed. How can I make this work? input text has it’s own -by default- listeners on up and down arrows.

What I want to do is when pressing up arrows focused in the input text to get previous messages and vice versa.

thx alot
