puphpeteer
puphpeteer copied to clipboard
Copy text from textarea to variable
Good afternoon, for several days I have been trying to find a solution on how to implement copying text from a text area to a variable, I will be very grateful to you for a hint on how this can be implemented, I tried this code, but it does not work for me
$text = $page->evaluate(JsFunction::createWithParameters(['document'])
->body('return document.getElementById("tText").value;'));
$page->evaluate(JsFunction::createWithParameters("document") ->body('return document.getElementById("Text").value;'));