Home >Backend Development >PHP Tutorial >Under what circumstances will php variables be destroyed?

Under what circumstances will php variables be destroyed?

WBOY
WBOYOriginal
2016-08-04 09:20:321214browse

For example, the function method will be destroyed after execution. What else are there?

Reply content:

For example, the function method will be destroyed after execution. What else are there?

php uses reference counting to perform garbage collection. It is automatically triggered when certain conditions are met, or it can be triggered manually. Of course, you can also disable garbage collection, because the request will be cleaned up after the request is completed.

For garbage collection, you can read the manual: http://php.net/manual/zh/feat...

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn