几个瓢虫调试器的功能在symfony2 php应用程序中不起作用 [英] Few function of ladybug debugger not working in symfony2 php app

查看:123
本文介绍了几个瓢虫调试器的功能在symfony2 php应用程序中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用

https:// github .com / raulfraile / LadybugBundle

他们有三个功能

ld($var1[, $var2[, ...]]): shortcut for ladybug_dump

ldd($var1[, $var2[, ...]]): shortcut for ladybug_dump_die

ldr($format, $var1[, $var2[, ...]]): shortcut for ladybug_return

前两个正在工作,但第三个它说未定义的函数

First two are working but for third it says undefined function

此外,我尝试转储json然后我也得到错误

Also i tried this to dump json then i also get error

ld(json_decode($ jsonContent,true));

我得到这个


UndefinedFunctionException:尝试从
命名空间Ladybug\Type调用函数bccomp在
/var/www/html/site/Symfony/vendor/raulfraile/ladybug/src/Ladybug/Type/FloatType.php
第115行

UndefinedFunctionException: Attempted to call function "bccomp" from namespace "Ladybug\Type" in /var/www/html/site/Symfony/vendor/raulfraile/ladybug/src/Ladybug/Type/FloatType.php line 115


推荐答案

bccomp()功能需要php BC Math 扩展名。

The bccomp() function needs the php BC Math extension.


仅当PHP配置为
- enable-bcmath 时,这些功能才可用。

These functions are only available if PHP was configured with --enable-bcmath .

Windows版本的PHP内置了对此扩展的支持

The Windows version of PHP has built-in support for this extension

检查 php -i | grep -i bcmath ...

应该有一行...

BCMath support => enabled

...如果扩展程序已启用。否则,您可能需要使用 - enable-bcmath 重新编译php。

... if the extension is enabled. Otherwise you'll probably need to recompile php with --enable-bcmath.

这篇关于几个瓢虫调试器的功能在symfony2 php应用程序中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆