0

I am working with Internet Information Service (IIS 6.1) and PHP 5.2. I want to screen capture IIS server desktop using PHP on Windows 8. I have searched the Internet and stackoverflow for similar questions, but they almost always deal with Apache Web server. To make this work with Apache, they basically tell the poster to enable, Allow this service to interact with the desktop option within its properties. For my IIS, I did find this option in IIS Admin Service running on Windows 7 not Windows 8, but I am not certain. Is this where you enable this option or else where for IIS to execute the following PHP script successfully?

Following code works, but all I see is black image for a screen shot.

<?php
$im = imagegrabscreen();
imagepng($im, "myscreenshot.png");
imagedestroy($im);
?>

UPDATE: My IIS server is actually running on Windows 8. I just looked through the Services list and I did not find IIS Admin manager running, but on Windows 7 I do see it running.

ThN
  • 3,235
  • 3
  • 57
  • 115
  • When you say 'capture my desktop', do you mean the desktop of the user on the IIS server you are authenticating to, the identity of the app pool that your site is using, or the client's desktop? – Evan OJack Jan 27 '15 at 15:45
  • @EvanOJack desktop of the user on the IIS server – ThN Jan 27 '15 at 15:47
  • Are you using Windows authentication and impersonation? – Evan OJack Jan 27 '15 at 15:51
  • @EvanOJack No I am not – ThN Jan 27 '15 at 16:03
  • What is the identity of the app pool? This would be the user whose desktop you would see, if there is a desktop, which I'm not sure of. – Evan OJack Jan 27 '15 at 16:13
  • @EvanOJack There is a desktop. Application pool identity is named DefautAppPool ???? – ThN Jan 27 '15 at 16:46
  • IIS runs as W3SVC (World Wide Web Publishing Service). The DefaultAppPool will have an identity, such as ApplicationPoolIdentity (IIS7+?), LocalService, or NetworkService. This article, and others linked in it, seem to describe your issue: http://stackoverflow.com/questions/1002064/screen-capture-from-windows-service. It sounds like Windows Vista+ may not support this, but I can't say for sure. I hope this helps you get a little further in your troubleshooting. – Evan OJack Jan 27 '15 at 17:06
  • Do u find any solution? I've the same situation here. Can't find de "IIS Admin Manager" services on windows server 16 – GuiPab Sep 04 '19 at 23:59

0 Answers0