The json extension is missing. Please check your PHP configuration

14,171

Solution 1

It looks like you are install PHP5 from a custom repo. I would remove PHP and remove that repo.

sudo apt-add-repository --remove ppa:ondrej/php5-5.6
sudo apt-get update

now install php

sudo apt-get install php5-common php5-json

Solution 2

Below solution worked for me-

cd /etc/php5/mods-available
vi json.ini

In this file make below changes

priority=20
extension=json.so

Incase if json.ini file is not there, create the file with contents as

priority=20
extension=json.so
Share:
14,171
Yaşar Xavan
Author by

Yaşar Xavan

Yashar Khavan | trying to be a Developer | IT Man @ East Azerbaijan State Registration for Deeds and Property | Master of Engineering in IT

Updated on June 05, 2022

Comments

  • Yaşar Xavan
    Yaşar Xavan almost 2 years

    I install PHP5.6.0 on Ubuntu 13.10 x64 from this

    https://launchpad.net/~ondrej/+archive/php5-5.6a
    

    then I installed phpmyadmin when I am trying to lunch phpmyadmin I got this message

    The json extension is missing. Please check your PHP configuration.
    

    my PHP modules:

    bcmath
    bz2
    calendar
    Core
    ctype
    date
    dba
    dom
    ereg
    exif
    fileinfo
    filter
    ftp
    gd
    gettext
    hash
    iconv
    libxml
    mbstring
    mcrypt
    mhash
    mysql
    mysqli
    openssl
    pcntl
    pcre
    PDO
    pdo_mysql
    Phar
    posix
    readline
    Reflection
    session
    shmop
    SimpleXML
    soap
    sockets
    SPL
    standard
    sysvmsg
    sysvsem
    sysvshm
    tokenizer
    wddx
    xml
    xmlreader
    xmlwriter
    Zend OPcache
    zip
    zlib
    

    [Zend Modules] Zend OPcache

    then when i use this command to install php-json

    sudo apt-get install php5-json
    

    I got this

    The following packages have unmet dependencies:
    php5-json : Depends: phpapi-20121212
    E: Unable to correct problems, you have held broken packages.
    

    How can I fix this problem?