json_encode options in Editor->json method

json_encode options in Editor->json method

milan.kratochvilmilan.kratochvil Posts: 5Questions: 3Answers: 0

Could you please extend the json method of Editor class to accept standard json_encode options?
I would really appreciate especially the JSON_NUMERIC_CHECK option...
Thank you.

This question has an accepted answers - jump to answer

Answers

  • allanallan Posts: 61,446Questions: 1Answers: 10,054 Site admin
    Answer ✓

    Thanks for suggesting this. The change would be here.

    We'll put this in for 1.9.4.

    Allan

  • allanallan Posts: 61,446Questions: 1Answers: 10,054 Site admin

    We've had a bit of feedback on this change which points out that it means it is possible for valid information to be dropped.

    As such, as of Editor 1.9.6 the JSON_NUMERIC_CHECK will be removed by default, but you can now pass it in as an optional second parameter to the Editor->json() method:

    ->json(true, JSON_NUMERIC_CHECK);
    

    Apologies for the confusion with this option.

    Allan

  • LapointeLapointe Posts: 430Questions: 81Answers: 4

    B)

This discussion has been closed.