简体   繁体   中英

Database interaction with codeigniter and backbone.js

I am trying to learn backbone.js to make a web application.This is my first time with a javascript framework and I am fairly confused with some of the stuff.

I have been developing in codeigniter for a while so I do have a understanding of the MVC architecture.

My question is how do I get the data from the backbone.js front end to my codeigniter controller and save it in the database. for example to implement a simple login/register functionality with CI and backbone, how should I proceed. If anyone can guide me step step then that would be great or point me to the right resource. Thank you.

PS: I know that I have to implement a REST api with my codeigniter but I don't know how? so if someone can provide a basic controller example it'd be really helpful.

这是一个使用上面回复中提到的API的教程(由图书馆的作者自己提供) http://net.tutsplus.com/tutorials/php/working-with-restful-services-in-codeigniter-2/

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM