-3

Does anyone know what is the class name for the "send" button on Facebook messages?

I tried this (javascript) code but it didnt work :

view.evaluateJavascript("javascript: var elements = document.getElementsByTagName('button'); for (var i = 0; i < elements.length; i++) { if (elements[i].getAttribute('aria-label') === 'Send') { elements[i].click(); } }", null);

Expected this code to automatically enter a message and send it to a user.

EDIT :ive already solved it. Instead of class name i use the send "button" compid if you wanted the code just reply :>

1
  • As I'm inspecting the "button," it doesn't seem to be a button at all, but a div with role=button. You can inspect it and copy the class list, but I don't know how it works or how static those classes are.
    – mykaf
    May 12 at 13:15

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.