承接 jemer/session 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

jemer/session

最新稳定版本:v1.0.0

Composer 安装命令:

composer require jemer/session

包简介

Session manager for php projects

README 文档

README

Session manager for Php projects.

Useage

composer require jemer/session

Start a new session by calling the SessionManager::Instance()->Start method. Pass in any session properties that you would want.

use Jemer\Session\SessionManager;

SessionManager::Instance()->Start([
                    "username" => "Bob",
                    "role" => "manager",
                    "yearsOfService" => 15
                ]);
                

To get a property from the session manager just call its Get() and pass in the name of the key. In this case were looking for the "username"

echo SessionManager::Instance()->Get("username");

returns: Bob

To end the session just call the SessionManager::Instance()->End(). This will end the session and remove all values from the $_SESSION array.

统计信息

  • 总下载量: 7
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-12-06