douna2633 2011-07-03 08:59
浏览 24
已采纳

为旧的Web应用程序构建开发API

We have a popular web-app developed using CodeIgniter. Now we want to expose our data through a RESTful API.

Once we are done that we will rebuild the front end such that it merely acts as a client of our API.

People suggested that I should use NodeJS (or similar frameworks like SINATRA) for this API. I have few questions regarding this and I am sure experience devs can help.

If I chose NodeJS where do I put the business logic ? In the NodeJs code itself? Or does NodeJS code merely act like an interface between API clients and business logic implemented in more complicated framework ?

I am assuming here that the existing code is not much reusable.

  • 写回答

2条回答 默认 最新

  • doubo1871 2011-07-03 09:09
    关注

    I'm not sure if NodeJS is the right tool to use in this case (sure, it's cool to say "use nodejs" these days, but unless the tool fits the need, don't use it).

    Have you looked at REST frameworks for PHP that are out there? e.g. FAPI

    EDIT: You should also read: https://stackoverflow.com/questions/238125/best-framework-for-php-and-creation-of-restful-based-web-services

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 想问一下树莓派接上显示屏后出现如图所示画面,是什么问题导致的
  • ¥100 嵌入式系统基于PIC16F882和热敏电阻的数字温度计
  • ¥15 cmd cl 0x000007b
  • ¥20 BAPI_PR_CHANGE how to add account assignment information for service line
  • ¥500 火焰左右视图、视差(基于双目相机)
  • ¥100 set_link_state
  • ¥15 虚幻5 UE美术毛发渲染
  • ¥15 CVRP 图论 物流运输优化
  • ¥15 Tableau online 嵌入ppt失败
  • ¥100 支付宝网页转账系统不识别账号