简体   繁体   English

我如何使用php PHPSESSID维护会话

[英]How can i maintain a session using php PHPSESSID

I am using Scriptable web browser (simplebrowser) http://www.lastcraft.com/browser_documentation.php and it does not seem to have a way to: 我正在使用可编写脚本的网络浏览器(简单浏览器) http://www.lastcraft.com/browser_documentation.php ,它似乎没有办法:

  1. session_start(); session_start();
  2. set the PHPSESSID value 设置PHPSESSID值
  3. Browse to few pages using simplebrowser 使用simplebrowser浏览到几页
  4. session_destroy(); session_destroy();

so it might be possible to use php functions to setup and maintain a session using PHPSESSID 因此可能可以使用php函数通过PHPSESSID设置和维护会话

The session is started by the script that you request with simplebrowser. 会话由您使用simplebrowser请求的脚本启动。 Lets assume you call example.com/script.php with simplebrowser. 假设您使用simplebrowser调用example.com/script.php。 Then script.php contains session_start() and thus sends a cookie along with the response. 然后script.php包含session_start()并因此发送一个cookie和响应。 You do not have to start and maintain a session for simplebrowser, let alone set the SID yourself. 您不必启动和维护simplebrowser的会话,更不用说自己设置SID了。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM