用于 Web 应用程序的 PHP 或 Lift 框架?

发布于 2024-09-27 05:22:27 字数 1432 浏览 5 评论 0原文

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

孤独陪着我 2024-10-04 05:22:27

PHP 的发明者 Resmus Lerdorf 曾在谈到 foursqaure(使用 scala/lift 构建)时表示,这是长期以来第一个他能找到的没有任何安全漏洞的网站。

Resmus Lerdorf, the inventor of PHP, once said with regards to foursqaure (build with scala/lift) that it's the first site for a long time that doesn't have a single security hole he could find.

妄司 2024-10-04 05:22:27

如果您无法列举使用 scala/lift 而不是 PHP 的原因,您可能会想继续使用 PHP。 PHP 是一个更加成熟和受支持的平台 - 大量的文档、庞大的社区、大量的工具和库。

Scala 是一种很棒的语言,但 Twitter 和 Foursquare 使用它的主要原因是它能够在水平扩展的架构上处理大量数据。对于这些公司来说,这些都是非常具体的问题,因此特意选择了 Scala。

作为最近开始学习 Scala 的人,与 PHP 相比,社区和文档都比较少。尤其是在电梯方面。 IDE 支持之类的事情仍处于早期阶段。

确实没有办法比较这两种技术(非常不同的方法)。如果想使用 Scala,就使用它,但如果您还不够熟练,您可能会投入更多的时间和精力(而且,有一些 Java 背景也无伤大雅)。 PHP 就是 PHP,它非常容易上手和使用。

If you're having trouble enumerating the reasons why you'd use scala/lift over PHP, you'll probably want to stick with PHP. PHP is a far more mature and supported platform - oodles of documentation, huge community, tons of tools and libraries.

Scala is a great language, but the primary reason it's being used by Twitter and Foursquare is it's ability to work with enormous sets of data on a horizontally scaled architecture. These are very specific problems for these companies, and Scala was chosen for this purpose very deliberately.

As someone who has recently begun learning Scala, the community and documentation is minute compared to PHP's. Especially where Lift is concerned. And things like IDE support is still in it's early stages.

There's really no way to compare the two technologies (very different approaches). If want to use Scala, use it, but you'll probably be investing more time and energy if you're not already proficient (also, some background in Java doesn't hurt). PHP is just PHP, it's so easy to just pick up and use.

江湖彼岸 2024-10-04 05:22:27

如果你问这样的问题,你最好还是继续使用 PHP。一旦您的项目变得越来越复杂并且您厌倦了 PHP 的限制,这个问题就会自行消失。

但 Lift 不一定是您选择的框架。

If you ask such a question you'd better stay with PHP. Once your project becomes more and more complex and you are fed up with PHP limitations the question will disappear on its own.

But Lift does not have to be the framework of your choice.

提笔落墨 2024-10-04 05:22:27

除了 PHP 之外,您应该认为任何语言都是 Web 应用程序的好语言,但 Scala 是一种非常优秀的语言,尽管它会改变您对整个编程的看法。有些人无法应对这一点,所以要小心。

PHP 优势:

  • 即使在最便宜的“每月 5 美分”网络托管商上也能安装。

PHP 的缺点:

  • 这些库不稳定,并且经常在没有通知的情况下发生变化。

  • 整个语言都有错误,通常不会像正常人所期望的那样工作。

  • 该文档无法使用,有时是错误的,有时只能通过用户提供的使用示例来理解(这些示例通常是错误的或不是最佳的)。

  • 没有快速的方法来查看某些语言提供的代码的实现。

  • API 是一团糟...这不应该被称为 API,它应该被称为 MCOBRIM:有缺陷、随机和命名不当的方法的混乱集合。

You should consider anything except PHP a good language for web applications, but Scala is a pretty excellent one, although it will change the way you think about programming as a whole. Some people can't handle that, so be warned.

PHP advantages:

  • Is installed even on the cheapest "5¢-a-month" webhoster.

PHP disadvantages:

  • The libraries are not stable and change every now and then, often without notice.

  • The whole language is buggy and generally doesn't work as a sane person would expect.

  • The documentation is unusable, sometimes wrong, sometimes only understandable with the user supplied usage examples (which are often wrong or not optimal, too).

  • No quick way to see the implementation of some language-supplied code.

  • The API is one big mess ... this shouldn't be called API, it should be called MCOBRIM: Messy Collection of Buggy, Random and Ill-named Methods.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文