in reply to Re^2: Regex arrow key problem
in thread Regex arrow key problem

if ($input eq "\e[D\n")
and
if ($input eq "\e[C\n")

You obviously removed the lc to get those values. Be careful about re-adding lc. Only lowercase $input after checking for these special keys.

Replies are listed 'Best First'.
Re^4: Regex arrow key problem
by Anonymous Monk on Dec 01, 2010 at 19:52 UTC
    I tried your code, with and without lc, and it didn't work still.

      Impossible. Either you didn't run the code I gave you, you didn't give me the output you got, or you changed something else.

        I ran the Data::Dumper code and it spit out exactly "\e[C\n" for right and "\e[D\n" for left. I then implemented it exactly as follows.
        if ($input eq "\e[C\n")