AutoRemote Bookmarklet

Discussion in 'AutoApps' started by Vyker, Sep 17, 2015.

  1. Vyker

    Vyker New Member

    Joined:
    Sep 17, 2015
    Messages:
    4
    Likes Received:
    0
    Hello, Great apps!

    I have a need to have tasker react to a bookmarklet press.

    I see there being two options 1) the current URL bookmarklet is used as the "event" in tasker, but I can't get it to work as Autoremote plugin in tasker only asks for "matched" words in a message. 2) I find out, or get help from you, on how to write a new bookmarklet that sends a message on press, i.e click bookmarklet on chrome, "xyz" message sent to phone, tasker profile triggers on message received event.

    Does that make sense, can you help?

    I really like your solution, as it appears your app is able to by pass my keyguard on the URL bookmarklet launch.

    Thanks
     
  2. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,477
    Likes Received:
    806
    So, just to be clear, you mean a bookmarklet on your PC?
     
  3. Vyker

    Vyker New Member

    Joined:
    Sep 17, 2015
    Messages:
    4
    Likes Received:
    0
    yes, Chrome on Windows.
     
  4. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,477
    Likes Received:
    806
    To change what the bookmarklet does, right-click it, edit it and you'll have something like this

    Code (Text):
    javascript:(function(){ var img = new Image(1,1); img.src = 'http://autoremotejoaomgcd.appspot.com/sendintent?intent=' + encodeURIComponent(document.URL) + '&key=YOUR_KEY'; })();
    if you want to send the message "xyz" you would change it to

    Code (Text):
    javascript:(function(){ var img = new Image(1,1); img.src = 'http://autoremotejoaomgcd.appspot.com/sendmessage?key=YOUR_KEY&message=xyz'; })();

    Hope this helps :)
     
    Gustavo Coelho likes this.
  5. Vyker

    Vyker New Member

    Joined:
    Sep 17, 2015
    Messages:
    4
    Likes Received:
    0
    That helped yes, thanks.

    However the "Sendmessage=" string doesn't turn on my phone like URL did.

    URL:
    Phone off on desk - URL sent - Phone screen on - Phone Keygaurd removed - browser launched.

    Send Message:
    Phone off on desk - message sent - phone screen stays off.

    AR has Tasker plugin to allow for event on message, not event on URL.

    Aim:
    To send something to my phone from a bookmarklet that will launch a tasker profile.

    Any other suggestions?
    Thanks
     
  6. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,477
    Likes Received:
    806
  7. Vyker

    Vyker New Member

    Joined:
    Sep 17, 2015
    Messages:
    4
    Likes Received:
    0
    I have AutoInput - there isnt a "unlock screen" in the Actions list - is it only in the Beta version?

    Also - how will it work? I want bookmarklet press to start the task. Are you saying I use AutoRemote to send a bookmarklet sendmessge to my phone, and then have tasker run Autoinput to unlock the screen before running the rest of the task?
     
  8. joaomgcd

    joaomgcd Administrator Staff Member

    Joined:
    Feb 3, 2015
    Messages:
    9,477
    Likes Received:
    806
    Yes, exactly :) That's it. And yes, you need to get the beta for now.
     
: bookmarklet

Share This Page