在所有网页上维护此类用户. [英] maintain such user on all web pages.

查看:71
本文介绍了在所有网页上维护此类用户.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,
我参与了一个Web项目的开发,我的登录页面可以让新用户登录我的网页.用户如何在他导航到的所有页面中维护的问题.任何帮助,请参见.

问候

Hi All,
I involved in developing a web project, I do login page to new users can registered on my web page. the problem how I can user maintain in all pages he navigate to. any help plz.

Regards

推荐答案

会话变量是使用它的最佳选择.此外,您还可以使用一些数据库来记录每一个的详细信息用户.

Session variables are the best option to use it.Also you can use some database for logging the details of every user.


正如其他人所提到的,请使用会话变量.确保在完成对用户会话变量的处理后,将其删除.否则,您最终(因为这可能需要很长时间)会耗尽保存值的服务器上的内存.

As the others have mentioned, use session variables. Do make sure when you are done with the user''s session variable to delete it when finished. Otherwise, you will eventually (as this may take a very long time to have happen) run out of memory on the server where the values are kept.


一个没有提到的步骤是创建一个新的基础页面,如果用户尚未登录,该页面将重定向到登录页面.在那里,它可以正常工作.

The one step no-one else mentioned, is to create a new base page, which redirects to the login page if the user is not already logged in. From there, it just works.


这篇关于在所有网页上维护此类用户.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆