0

I wondered now with XAMPP (MAC) that why the php.ini file is taking wrong in php cli.

phpinfo(); returning correct version 7.1.

enter image description here

php -v returning like below..

sh-3.2# php -v
PHP 7.0.15 (cli) (built: Jan 22 2017 08:50:55) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies

sh-3.2# which php
/usr/local/bin/php

sh-3.2# php --ini
Configuration File (php.ini) Path: /usr/local/etc/php/7.0
Loaded Configuration File:         /usr/local/etc/php/7.0/php.ini
Scan for additional .ini files in: /usr/local/etc/php/7.0/conf.d
Additional .ini files parsed:      (none)

I want to make the php-cli version as 7.1 to start my development. How can I do that ?

Jishad
  • 2,876
  • 8
  • 33
  • 62
  • Do you have an old php version installed? If so, change the PATH – rndus2r Sep 18 '17 at 07:18
  • i dont know how to change the path. please give an answer – Jishad Sep 18 '17 at 07:19
  • https://stackoverflow.com/questions/7703041/editing-path-variable-on-mac – rndus2r Sep 18 '17 at 07:19
  • should I want to set the path to phpinfo ini file ? – Jishad Sep 18 '17 at 07:20
  • Possible duplicate of [How to override the path of PHP to use the MAMP path?](https://stackoverflow.com/questions/4145667/how-to-override-the-path-of-php-to-use-the-mamp-path) – rndus2r Sep 18 '17 at 07:22
  • @rndus2r It will be better if you are giving a solution other than sharing links. I tried many links and not work this yet. – Jishad Sep 18 '17 at 07:26
  • 1
    the first link answer your question "I don't know how to change path". the second answer the question "how to set pathinfo to phpinfo ini file". ;) – okante Sep 18 '17 at 07:40

0 Answers0