按照Yii的文档建立一个form,:
1. create a model class repressenting the data fields to be collected.
2. create a controller action with code that responds to form submission.
3. ctrate a form in the view script file associated with the controller action.
总结了一下,form表单的3种用途:
1、收集保存数据
2、展示数据
3、进行登录验证
建立form后,却发现页面不显示,并提示如图错误。然而,自己在view里面写的表单却可以显示。通过调试,确定是model没有
找到。由于全过程都是由gii生成,并没有考虑其路径问题。在加入Yii::import('application.models.wsdd.*');后,就可以找到
model的路径了。