I needed clipboard access for any web application which i designed for my very own experience my local server, and that i emerged with this particular:

First a load file that reads from another file:

clip < %1

after which during my PHP file:

exec("mybatch.cmd $file_with_text_to_be_copied");

no return variable needed, just straight execute...

No error in almost any log, however it just does not work.

I am not surprised it does not work, because of the security around clipboards, however i can't understand why - so how exactly does chrome or Apache or whomever know what is I am doing?

I even attempted something I just read online about altering the Apache service account to being run by another account user (It was the machine account - can't remember - however it was whatever I just read online) but no change...

Home windows machine incidentally - just just in case that got skipped.

Have you use the machine() function ? use system to show the output. You'll be able to try to solve possible errors.

Example with system function:

$response = system('ls -al', $return);
echo $response . "<br />" . $return;

So far as I understand you can't access the clipboard like this. I recommend creating a simple JS script that really reads your clipboard and also the create a simple AJAX call to some back-finish function (passing within the clipboard like a parameter) after which do anything you need by using it.

However, some browsers might limit accessibility clipboard via JS.

The clipboard is really a property from the session, therefore the clipboard you utilize with control-c and buddies in your desktop session isn't the same, because the clipboard your webserver sees.

So with no assistant application (running inside your session) no chance.

BTW: It's good, no chance. Consider that, before you accept is as true.