in reply to Re^10: WWW::Mechanize::Chrome Instagram
in thread WWW::Mechanize::Chrome Instagram

From the image, it seems that the website does not use the real <input> fields as input but uses other fields overlaid over these fields. To verify this, I would inspect the HTML elements that get notified when clicking on that location on screen.

Maybe you can even get by with driving the whole thing with the keyboard alone. Count how many times you need to ->sendkeys("\t") to switch the focus to the appropriate field and then send the input. This is much more fragile, but it seems that the "normal" way doesn't work well there.

Replies are listed 'Best First'.
Re^12: WWW::Mechanize::Chrome Instagram
by damian1 (Novice) on Sep 10, 2019 at 11:53 UTC

    when i use

    $mech->sendkeys("\t");

    I get error message

    Odd name/value argument for subroutine at engine.pl line 71.

    I try with string param

     $mech->sendkeys(string => "\t");

    Not work, no effect, no select input

    How use properly sendkeys to tab key?

      Whoops, yes, sorry. The correct usage is

      $mech->sendkeys( string => "Hello World" );

      ... so I think that maybe the following could work:

      $mech->sendkeys( string => "\t" );

      I don't know how many tabs you need to send, so maybe

      $mech->sendkeys( string => "\t\t" );

      ... works better.

        I don't have idea... i try with tab key and the problem still can't be solved, when i save screenshot with browser any element not selected, i try with many combination tab key, I don't know if this sending of the keys works at all

        Maybe have other idea?