MrMike
V2EX  ›  PHP

用 google chrome 调试报错代码,如何格式化报错代码?

  •  
  •   MrMike · Nov 2, 2017 · 2518 views
    This topic created in 3135 days ago, the information mentioned may be changed or developed.

    用的是 symfony 框架,之前用 firebug,更新 firefox 后,firebug 不工作了,换成 google chrome,但是在不能格式化代码,输出数组之类的,全部在一起的。

    array:35 [ "block_name" => null "disabled" => false "label" => null "label_format" => null "translation_domain" => null "auto_initialize" => true "trim" => true "required" => true "property_path" => null "mapped" => true "by_reference" => true "inherit_data" => false "compound" => true "method" => "POST" "action" => "" "post_max_size_message" => "The uploaded file was too large. Please try to upload a smaller file." "error_mapping" => [] "invalid_message" => "This value is not valid." "invalid_message_parameters" => [] "allow_extra_fields" => false "extra_fields_message" => "This form should not contain extra fields." "csrf_protection" => true "csrf_field_name" => "_token" "csrf_message" => "The CSRF token is invalid. Please try to resubmit the form." "csrf_token_manager" => CsrfTokenManager {#265 -generator: UriSafeTokenGenerator {#304 -entropy: 256 } -storage: SessionTokenStorage {#267 -session: Session {#18 #storage: NativeSessionStorage {#154 #bags: array:2 [ "attributes" => AttributeBag {#171 -name: "attributes" -storageKey: "_sf2_attributes" #attributes: [] } "flashes" => FlashBag {#173 -name: "flashes" -flashes: []

    如何格式化,方便阅读呢?我用的 symfony dump 函数打印的,js 报错也是这样的。

    1 replies    2017-11-03 17:29:31 +08:00
    lyleo2010
        1
    lyleo2010  
       Nov 3, 2017
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   1888 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 16:14 · PVG 00:14 · LAX 09:14 · JFK 12:14
    ♥ Do have faith in what you're doing.