使用MVC方法登录类 [英] login class using MVC approach

查看:71
本文介绍了使用MVC方法登录类的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用MVC方法创建一个登录类。首先我的html表单代码在我的视图文件夹中,然后我想在控制器类中授权代码,查询和连接在我的模型类下,所以

是否可以将一个类的方法调用到另一个类class eg(第二个标签中的第11行对应第三个标签中的第31行)


html表格

展开 | 选择 | Wrap | 行号

解决方案

这通常是OOP的工作方式......问题是什么?


它不起作用。

感谢您详细而富有洞察力的调试过程。我确定它不适用的事实与你永远不会设置你的会话变量这一事实完全无关。


可能只是我。


i want to make a login class using MVC approach. First my html form code is in my view folder then i want authorizing code in controller class and the query and the connection are under my model class so
is it possible to call the method of one class into another class e.g (line no 11 in second tag correspond to line no 31 in third tag)

html form

Expand|Select|Wrap|Line Numbers

解决方案

That''s generally the way OOP works... What is the problem?


It dos''t work.


Thank you for your detailed and insightful debugging process. I''m sure the fact that it "dos''t work" is completed unrelated with the fact that you NEVER SET YOUR SESSION VARIABLES.

Could just be me, though.


这篇关于使用MVC方法登录类的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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