Skip to content

PHP Warning", message: "json_encode(): Invalid UTF-8 sequence in argument" #1

@SDKiller

Description

@SDKiller

And no error output in window - is this by design?

111111111111111

Another problem - Invalid UTF-8 sequence in argument was caused by stacktrace of exception happened earlier (because of invalid config) and passed to json_encode() - so stacktrace returned in output is actually useless

0: "#0 [internal function]: yii\base\ErrorHandler->handleError(2, 'json_encode(): ...', 'D:\\WebServers\\O...', 39, Array)"
1: "#1 ...\vendor\yiisoft\yii2\helpers\BaseJson.php(39): json_encode(Array, 320)"
2: "#2 ...\vendor\yiisoft\yii2\web\JsonResponseFormatter.php(53): yii\helpers\BaseJson::encode(Array)"
3: "#3 ...\vendor\yiisoft\yii2\web\JsonResponseFormatter.php(41): yii\web\JsonResponseFormatter->formatJson(Object(yii\web\Response))"
4: "#4 ...\vendor\yiisoft\yii2\web\Response.php(939): yii\web\JsonResponseFormatter->format(Object(yii\web\Response))"
5: "#5 ...\vendor\yiisoft\yii2\web\Response.php(310): yii\web\Response->prepare()"
6: "#6 ...\vendor\yiisoft\yii2\base\Application.php(381): yii\web\Response->send()"
7: "#7 ...\index.php(14): yii\base\Application->run()"
8: "#8 {main}"
type: "yii\base\ErrorException"

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions