php cookie 阻止对目录的访问

发布于 2024-09-02 05:48:18 字数 174 浏览 2 评论 0原文

我有一个 mysql 用户数据库,可以登录我的网站并查看内容。我想阻止某些用户访问几个目录。最好的方法是什么?

目前,当用户登录时,会使用其客户 ID 创建 Cookie,并使用客户来显示其内容。

我如何阻止我的用户访问整个目录???

编辑:我需要允许数据库中的一个用户登录后访问目录。

I have a mysql database of users that can login to my site and view content. I would like to block a couple of directories from certain users. What is the best way to do this.

Currently when a user logs in a cookie is created with their customer id and the customer is is used to display their content.

How would I block entire directories from my users???

EDIT: I need to allow one user in my database to access the directories once logged in.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文