Composer installing: the json extension is missing

前端 未结 5 1129
梦毁少年i
梦毁少年i 2021-01-18 03:43

I wrote in Linux Terminal: curl -s https://getcomposer.org/installer | php It said:

 #!/usr/bin/env php
Some settings on your machine make Com         


        
5条回答
  •  情书的邮戳
    2021-01-18 04:27

    On ubuntu 14.04 for me, I found that the default permissions for the php.ini file /etc/php5/cli/ restrict the file to Root user only, so if you run:

    php -m
    

    as non-root, you get far fewer modules than if you run sudo php -m

    The fix for this was for me to perform:

    sudo chmod a+rx /etc/php5/cli/* -R 
    

    which grants read and execute permissions for that folder and it's contents to everyone.

提交回复
热议问题