Fatal error: eZ publish did not finish its request - need PHP JSON extension? [SOLVED]

Author Message

Lo' F.

Saturday 19 June 2010 9:56:27 am

Hi there.

I've been facing some problems when clicking on "Edit" in both Backend and Frontend sites and it seems it has something to do whith PHP JSON extension.

Here's the big issue:

Whenever an "edit" or "new draft" command is given all I get is a fatal error message:

"

Fatal error: eZ publish did not finish its request.

The execution of eZ publish was abruptly ended, the debug output is present below.

"

I thought it could have had something to do with max_execution_time (which I set to 120) or memory_limit (set to 256M). But despite the high value given to them, I kept having the same problem.

I then turned on display_error in php.ini file and now the fatal error message says:

"

Fatal error: Call to undefined function json_encode() in /var/www/vhosts/sitename.net/httpdocs/extension/ezoe/classes/ezoeserverfunctions.php on line 372

Fatal error: eZ Publish did not finish its request

The execution of eZ Publish was abruptly ended, debug information can be found in the log files normally placed in var/log/*

"

Reading here and there I got to know that ezoe requires ezjscore enabled (which is already) and that PHP 5.1.2 and higher needs a PHP JSON extension.

Since my PHP version is 5.1.6 how can I install JSON extension to make everything work fine?

loredanaebook.it

Lo' F.

Saturday 19 June 2010 2:05:25 pm

Done! Fatal error's gone and the edit functionality works just fine.

Here's how to install json extention:

- Download "php-json-ext-1.2.1" package

wget http://aurore.net/projects/php-json/php-json-ext-1.2.1.tar.bz2

- Unpack the compressed package

- Go into the package folder

cd php-json-ext-1.2.1

- Run ...

./configure
make
make install

- Add extension=json.so line to your [etc/]php.ini file

and finally restart the server and clear ini cache.

loredanaebook.it

Henrik Gren

Friday 08 October 2010 10:02:52 am

Thank you Lo'. I struggled with this problem for days. Your post helped me out.

To make this more accessible to the search engine of this forum I would state:

IF your development environment is running on PHP 5.2.x, you should assure that the production environment is either 5.2.x or that the JSON extension is enabled.

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 29 2025 23:49:47
Script start
Timing: Jan 29 2025 23:49:47
Module start 'layout'
Timing: Jan 29 2025 23:49:47
Module start 'content'
Timing: Jan 29 2025 23:49:47
Module end 'content'
Timing: Jan 29 2025 23:49:47
Script end

Main resources:

Total runtime0.0116 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0040 588.6328151.2734
Module start 'layout' 0.00400.0018 739.906336.8203
Module start 'content' 0.00590.0045 776.726694.5156
Module end 'content' 0.01030.0012 871.242233.9922
Script end 0.0115  905.2344 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002017.1900140.0001
Check MTime0.00098.0785140.0001
Mysql Total
Database connection0.00075.853710.0007
Mysqli_queries0.001815.289030.0006
Looping result0.00000.059810.0000
Template Total0.00108.410.0010
Template load0.00086.633110.0008
Template processing0.00021.727910.0002
Override
Cache load0.00054.453710.0005
General
dbfile0.00087.031180.0001
String conversion0.00000.053640.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs