php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #31743 Shell_exec function problem with IIS
Submitted: 2005-01-28 16:09 UTC Modified: 2005-01-29 17:05 UTC
From: tril2632 at hotmail dot com Assigned:
Status: Not a bug Package: IIS related
PHP Version: 5.0.3 OS: Win 2000 Pro
Private report: No CVE-ID: None
 [2005-01-28 16:09 UTC] tril2632 at hotmail dot com
Description:
------------
Hello

It's a mysterious problem.

When I try to execute my code I get the message "error" display so the OR DIE message is printed BUT there is no error, my excel file is open and everything work, so the function shouldn't execute the message in "or die" because everything work !!!

I had to remove the    OR DIE ('error');   in my code because php was stopping the script but he shoul not ! 

Reproduce code:
---------------
shell_exec('cmd /C start c:\remarques.xls') OR DIE ('error');

Expected result:
----------------
My excel file should open.

Actual result:
--------------
The file is open, it's ok but PHP execute the message in the "OR DIE" and he sould not because it works !!! there was no error !!!

And with apache 1.3.33 there is another problem with my code : the page load indefinitely without anny error in the error log etc of apache !!!

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-01-28 16:23 UTC] tril2632 at hotmail dot com
PS : with apache you must enable the service to interact with desktop in order to work !!!
 [2005-01-29 17:05 UTC] pollita@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions. 

Thank you for your interest in PHP.

Ask yourself this question:

"What does that command output?" I'm not referring to the action of the window opening, but to the result returned from running that command at a command prompt.

Now ask yourself:

"Does the data (hint: or lack thereof) evaluate to TRUE or FALSE?"

"Under what conditions does the right-hand side of an OR operator execute?  When the left-hand evaluates to TRUE or FALSE?"
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 08:01:28 2024 UTC