Issue Details (XML | Word | Printable)

Key: MDL-16768
Type: Improvement Improvement
Status: Closed Closed
Resolution: Fixed
Priority: Minor Minor
Assignee: Nicolas Connault
Reporter: Nicolas Connault
Votes: 0
Watchers: 0
Operations

Add/Edit UI Mockup to this issue
If you were logged in you would be able to see more operations.
Moodle

Add json_encode and json_decode function definitions for PHP4

Created: 02/Oct/08 03:39 PM   Updated: 06/Oct/08 04:03 PM
Component/s: AJAX
Affects Version/s: 1.7.5, 1.8.6, 1.9.2
Fix Version/s: 1.8.7, 1.9.3

Participants: Dongsheng Cai and Nicolas Connault
Security Level: None
QA Assignee: Dongsheng Cai
Resolved date: 02/Oct/08
Affected Branches: MOODLE_17_STABLE, MOODLE_18_STABLE, MOODLE_19_STABLE
Fixed Branches: MOODLE_18_STABLE, MOODLE_19_STABLE


 Description  « Hide
The PHP5 functions json_encode and json_decode are very useful for writing PHP callback files to use with AJAX requests. The PEAR SERVICES_JSON package has been added to Moodle, but it would be useful to have function calls "faking" the PHP5 functions when a lower PHP version is on the server.

 All   Comments   Change History   Version Control      Sort Order: Ascending order - Click to sort in descending order
Nicolas Connault added a comment - 02/Oct/08 03:59 PM
Added php version-dependent function definitions so that we can use json_encode() and json_decode() no matter what PHP version the server is running.

Dongsheng Cai added a comment - 06/Oct/08 04:03 PM
Thanks, closing.