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

jsonPHPphpmyadminUbuntu

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?

Best Answer

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
Related Topic