It seems that within PHP my shell_exec command is only returning 12 characters max.
The command run from the command line:
This returns the full string of 18 characters, in this case.
When run like this from a php script:
I only get the first 12 characters of the output. Of course, if my output is 12 characters or less, this is no problem, but sometimes it is longer than 12.
Anyone know what gives here?
The command run from the command line:
Code:
ps -ef|grep server-bin|head -1|awk '{print $10}'
This returns the full string of 18 characters, in this case.
When run like this from a php script:
Code:
$mapname = shell_exec("ps -ef|grep server-bin|head -1|awk '{print $10}'");
print $mapname;
I only get the first 12 characters of the output. Of course, if my output is 12 characters or less, this is no problem, but sometimes it is longer than 12.
Anyone know what gives here?