为什么我的 Netbeans Xdebug 会话在一段时间不活动后超时

Why does my Netbeans Xdebug session timeout after period of inactivity(为什么我的 Netbeans Xdebug 会话在一段时间不活动后超时)
本文介绍了为什么我的 Netbeans Xdebug 会话在一段时间不活动后超时的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我喜欢 Netbeans 帮助我调试 Magento 应用程序的方式(在 Win 7 64 位的 XAMPP 中),但我注意到连接似乎在一段时间后超时.断点不再被击中,我不得不重新启动调试会话,这很烦人.有关如何延长或禁用调试超时的任何建议?

I love the way the Netbeans helps me to debug my Magento applications (in XAMPP on Win 7 64-bit), but I've noticed that the connection seems to timeout after a period. The breakpoints no longer get hit and I have to restart the debugging session which is annoying. Any suggestions for how to extend or disable the debug timeout?

我在 IDE 或 Xdebug php.ini 配置中看不到任何选项.Xdebug 文档指出:

I can't see any options in the IDE or Xdebug php.ini config. The Xdebug documentation states:

当 URL 变量XDEBUG_SESSION_START=名称已附加到一个 URL,Xdebug 发出一个 cookie名称XDEBUG_SESSION"并作为值XDEBUG_SESSION_START 的值网址参数.期满cookie 是一小时.cookie 是一小时.

When the URL variable XDEBUG_SESSION_START=name is appended to an URL, Xdebug emits a cookie with the name "XDEBUG_SESSION" and as value the value of the XDEBUG_SESSION_START URL parameter. The expiry of the cookie is one hour.cookie is one hour.

但不建议如何更改到期时间.

but doesn't suggest how to change the expiry time.

推荐答案

找到 php.ini 并将以下行添加到 xdebug 部分.

Find php.ini and add the following line to the xdebug section.

xdebug.remote_cookie_expire_time = 3600

该数字是 cookie 保持活动状态的时间(以秒为单位),默认为 3600(1 小时).我将它设置为 36000(10 小时),效果很好,并鼓励我偶尔重新启动该过程以释放内存.如果需要,您可以将其设置为 0(无限制),尽管我发现这会导致奇怪的冻结.

The number is the time in seconds for the cookie to remain active, which defaults to 3600 (1 hour). I set it to 36000 (10 hours), which works fine and encourages me to restart the process occasionally to free memory. You can set it to 0 (unlimited) if you want, although I found that caused odd freezes here and there.

记得重新启动 Apache 以使更改生效.

Remember to restart Apache for the change to kick in.

这篇关于为什么我的 Netbeans Xdebug 会话在一段时间不活动后超时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本站部分内容来源互联网,如果有图片或者内容侵犯您的权益请联系我们删除!

相关文档推荐

Convert JSON integers and floats to strings(将JSON整数和浮点数转换为字符串)
in php how do I use preg replace to turn a url into a tinyurl(在php中,如何使用preg替换将URL转换为TinyURL)
all day appointment for ics calendar file wont work(ICS日历文件的全天约会不起作用)
trim function is giving unexpected values php(Trim函数提供了意外的值php)
Basic PDO connection to MySQL(到MySQL的基本PDO连接)
PHP number_format returns 1.00(Php number_Format返回1.00)