Home  >  Q&A  >  body text

python2.7 - 用户登陆问题(数据库用的mongoDB)

用户在页面输入用户名跟密码跟mongoDB中的匹配页面跳转到登陆成功.那么前端页面跟数据库中的数据怎么匹配?希望会的人,给新手一个提示,不胜感激...

巴扎黑巴扎黑2733 days ago520

reply all(2)I'll reply

  • PHPz

    PHPz2017-04-25 09:03:55

    Use JavaScript to get the content of the front-end page
    And then AJAX POST to the backend?

    reply
    0
  • PHP中文网

    PHP中文网2017-04-25 09:03:55

    Generally, post forms and sessions are used, and cookies are also used in the long term.

    if session[login]=yes. redirect to xx page, xx page needs to be written by yourself, and it will be displayed only after login. If not logged in, it will jump to the login interface.

    All background interfaces must determine whether to log in.
    otherwise. .

    reply
    0
  • Cancelreply