CFormModel is used where the model data doesn't come from an active record.
That is: it doesn't have a related record in the database.
That's basically it.
CFormModel ใช้สำหรับเรียก model โดยตรง โดยไม่ได้เรียก active record
คือมันไม่เกี่ยวข้องกับ record ใน database
คล้ายๆ กับว่า CFormModel คนใช้ ต้องมาเขียนโค้ดเอง ส่วนมากเห็น CFormModel เช่นพวก login เพราะว่ามีอิสระในการ config มากกว่า
แต่ CActiveRecord จะมี action กำหนดค่าให้เราง่ายกว่า
ที่มา http://www.yiiframework.com/forum/index.php/topic/18467-what-is-the-purpose-of-cformmodel/
Thursday, September 5, 2013
Subscribe to:
Post Comments (Atom)
Blog Archive
-
▼
2013
(27)
-
▼
September
(27)
- แนะนำเวป http://yiiextensionthai.zz.mu/
- http://cksc.co.th/site/ ขอแนะนำเวปกันหน่อย
- http://tuktuk.tapquo.com/ css framwork อีกเช่นกั...
- เจาะลึก css ของ yii และ bootstrap
- แค่ใช้ gii ตัวเดียว สามารถสร้างให้เราได้อย่างรวดเร็ว
- $this->renderPartial
- การเปลี่ยน Template ใหม่ โดยเราจะไม่ใช้ File main....
- วัตถุประสงค์ของ CFormmodel คืออะไร?
- การใส่ attribute ลง cgridview ใน 1 cell มากกว่า 1 ...
- รวมคำสั่งที่เกี่ยวข้องกับ label
- CDetailView
- CPagination หรือคำสั่งในการแบ่งหน้า
- http://purecss.io/ pure css framework ที่น่าสนใจ ส...
- ตำแหน่งของ Folder Yii (Path, Location)
- MVC คืออะไร มันต่างกับแบบเดิมยังไง
- การสร้าง Title แต่ละ Page ด้วย yii ใน controller
- การใช้ Flash Message
- ยกตัวอย่างการดึงข้อมูล การค้นหาข้อมูลจาก DB http:...
- 03 เริ่มต้น Yii กับ Demo ที่ให้มากับไฟล์ และการติด...
- 02 อย่าลืมเช็ค requirement นะ
- เริ่มต้นกับ primefaces
- bootstrap
- yiibooster ไว้ทำอะไรกันนะ?
- แหล่งข้อมูล Yii จากเว็บไซต์ ทั้งประเทศไทยและต่างปร...
- แนะนำเว็บ it-ebooks.info
- 01 ติดตั้ง Yii framework
- เริ่มต้นก้าวสู่อาชีพโปรแกรมเมอร์ด้วย Framework
-
▼
September
(27)
No comments:
Post a Comment