[Ask] perbedaan "php -v" dan "/usr/bin/php -v"


Status
Not open for further replies.

priz_

Beginner 1.0
Dear all,

Mau tanya, saya ada problem sedikit dengan menggunaan binary php. Karena ada perbedaan output ketika saya ketik php -v dan /usr/bin/php -v di server yang sama (CentOS release 5.7 (Final).

Berikut infonya.

Code:
[root@mars bin]# pwd
/usr/bin

[root@mars bin]# ls -la /usr/bin/php
-rwxr-xr-x 1 root root 2862064 Nov 30  2010 /usr/bin/php

[root@mars bin]# /usr/bin/php -v
PHP 5.1.6 (cli) (built: Nov 29 2010 16:47:46) 
Copyright (c) 1997-2006 The PHP Group
Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies

[root@mars bin]# ./php -v
PHP 5.1.6 (cli) (built: Nov 29 2010 16:47:46) 
Copyright (c) 1997-2006 The PHP Group
Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies
[root@mars bin]# 

[root@mars bin]# php -v
PHP 5.3.15 (cli) (built: Aug  5 2012 04:48:43) 
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
    with the ionCube PHP Loader v4.0.14, Copyright (c) 2002-2011, by ionCube Ltd., and
    with Zend Guard Loader v3.3, Copyright (c) 1998-2010, by Zend Technologies
[root@mars bin]#


Tolong pencerahannya


Trims,
 
Hehe, Ok sip thanks pak,

Code:
[root@mars bin]# which php
/usr/local/bin/php

[root@mars bin]# mv /usr/bin/php /usr/bin/php-orig
[root@mars bin]# ln -s /usr/local/bin/php /usr/bin/php

[root@mars bin]# /usr/bin/php -v
PHP 5.3.15 (cli) (built: Aug  5 2012 04:48:43) 
Copyright (c) 1997-2012 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies
    with the ionCube PHP Loader v4.0.14, Copyright (c) 2002-2011, by ionCube Ltd., and
    with Zend Guard Loader v3.3, Copyright (c) 1998-2010, by Zend Technologies
[root@mars bin]#
 
Status
Not open for further replies.
Back
Top