S
S
Sergey2014-12-11 13:44:41
PHP
Sergey, 2014-12-11 13:44:41

How to get text from server clipboard in PHP?

On the local machine, you need to get the text from the clipboard. Let's say on the site X copied the text, then went to another tab localhost pressed F5 and got the already processed text at the output.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
E
Evervess, 2014-12-11
@Evervess

PHP COM Automation: Taming the Clipboard

B
Boris Benkovsky, 2014-12-11
@benbor

Try exec('system command here');
You can read how to take this system command here:
stackoverflow.com/questions/749544/pipe-to-from-cl...
For example, for macos, take from the clipboard pbpaste
php -r "echo exec('pbpaste');"

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question