Home > php教程 > php手册 > body text

PHP对话的具体使用技巧分享

WBOY
Release: 2016-06-13 11:06:59
Original
1156 people have browsed it

对于http:///www.yourdomain.com/yourscript.php?count=56给注册变量$count指定一个新值,这一点对于安全很重要:只能在服务器端的脚本中删除一个没有注册的对话变量。

如果要完全删除一个对话变量,首先需要从系统中注销它:

session_unregister('count');

要完全删除一个对话变量的脚本是非常简单,如下所示:

session_destroy();

使用PHP对话变量可以减少访问数据库的频率,使代码更加清晰,而且可以减少对用户发送的cookie的数量,它是最简单的方法了。


Related labels:
source:php.cn
Statement of this Website
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
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!