Set character encoding when saving JSON.