Simple lightweight translation in js and php