On Thu, August 4, 2016 8:52 am, James B. Byrne wrote:>
> On Wed, August 3, 2016 14:19, Always Learning wrote:
>>
>> On Wed, 2016-08-03 at 13:55 -0400, Jason Welsh wrote:
>>
>>> What I do is create a php.php file on the root of my fileserver
>>> with
>>> the following
>>>
>>> <?php phpinfo() ?>
>>
>> I use a text command: php -i
>>
>>
>>
>
> php -i > php-i.txt
> echo '<?php phpinfo() ?>' | php > php-echo.txt
>
> diff php-i.txt php-echo.txt
> 709,710c709,710
> < _SERVER["PHP_SELF"] =>
> < _SERVER["SCRIPT_NAME"] =>
> ---
>> _SERVER["PHP_SELF"] => -
>> _SERVER["SCRIPT_NAME"] => -
> 714c714
> < _SERVER["REQUEST_TIME"] => 1470317489
> ---
>> _SERVER["REQUEST_TIME"] => 1470317531
> 716a717
>> [0] => -
> 719c720
> < _SERVER["argc"] => 0
> ---
>> _SERVER["argc"] => 1
>
>
> I do not see much to choose between them in terms of output and 'php
> -i' is certainly handier when in a terminal session on the host.
>
You are right as far as your particular case is concerned. Showing
something true in one particular case doesn't prove it is always so. (As
opposed to showing just one case when it is not true which will be a proof
of wrong statement).
I'm not going to make weird example when apache at start changes to custom
php config just to support a point I tried to make. Still, when I
troubleshooting a problem, I like to test something under as close to
reality as possible. Just to avoid potential differences that may affect
what I see in the test. This is sort of philosophy they taught me in
programming classes waaay back. And this is what potentially saved me the
length of troubleshooting in quite a few cases over my life. Again, it is
not I who is this clever, it is just that I had great teachers. And as
softly as I mentioned it ("I like more the way to see it as web server
shows") hopefully didn't hurt anybody's feelings, but those who
decide to
give it their own thought might benefit from it. Hopefully.
But if this doesn't make sense to, whoever reads it, please, just ignore it.
Valeri
++++++++++++++++++++++++++++++++++++++++
Valeri Galtsev
Sr System Administrator
Department of Astronomy and Astrophysics
Kavli Institute for Cosmological Physics
University of Chicago
Phone: 773-702-4247
++++++++++++++++++++++++++++++++++++++++