不使用PHP框架的原因? [英] Reasons to NOT use a PHP Framework?

查看:161
本文介绍了不使用PHP框架的原因?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直使用框架开发网络软件( Agile Toolkit ),这对我在所有情况下都有帮助,但有一个问题总是与我有关:

在哪种情况下使用框架是不可取的?



所以对其他资深框架开发人员提出问题 - 您将在何时编写原始良好PHP 而不是您选择的框架?

解决方案

人们会建议不要使用框架的原因很多。


  • 通过编写自己的书,你会学到很多东西。我一直在自己的工作,我已经学到了很多关于PHP的不同的事情,我以前不知道。总的来说,这是一个很好的学习体验,可以在面试或简历中使用。它表明,您对语言以及最重要的背后理论非常感兴趣,而不仅仅是无意识的实现。

  • 框架中有很多您不需要的东西,通过自己创造你只能得到你想要的东西。该框架专门针对您自己的需求量身定制。我一个人不喜欢这些框架如何处理模板,这是我自己制作模板的最大触发器。

  • 另外,我不确定这个,但是想到它在逻辑上...你自己的框架只适合你的需求,比任何其他框架要快得多。考虑加载和涉及的数据库查询时其他框架必须经历的所有设置。您可以节省自己的所有负载。

  • 如果您打算制作一个不需要扩展的小项目,比如简单的投资组合网站,那么框架就会做更多的工作。



这里还有一篇非常好的文章进入其他细节。这篇文章的作者首先谈论他如何一直是框架的大支持者。

http://jpst.it/jiYX



除非我开始做,否则我总是会努力制作自己的框架一些自由职业的工作。我不断更新我的框架并越来越多地学习。你永远不会听到任何人说绝对使用或绝对不使用框架,因为这一切都取决于使用。



编辑:还有在程序员站点上的一个问题是: https://softwareengineering.stackexchange。 com / questions / 49488 / when-not-use-a-framework



编辑#2:最后一篇文章关于为什么框架没有必要: http://www.amberweinberg.com/you-dont-need-a-framework-if-you-have-a-good-developer/


I have always developed web software using a framework (Agile Toolkit) and it was helpful to me in all situations, but one question always concerned me:

In which circumstances it's NOT advisable to use a framework?

So a question to other veteran framework developers - when would you code in a raw good PHP instead of your framework of choice?

解决方案

There are many reasons that people will suggest not to use a framework.

  • You will learn a lot by writing your own. I have been working on my own and I have learned a lot of different things about PHP that I did not know before. Overall it is a great learning experience that can be used in an interview or on your resume. It shows that you have a big interest in the language and most importantly the theory behind it rather than just the mindless implementation.
  • There are a lot of things in frameworks that you do not need and by making your own you can get only whatever you want. The framework is tailored to your own needs specifically. I for one did not like how any of the frameworks handled templates which was the biggest trigger for me to make my own.
  • Also, I am not positively sure about this one, but thinking of it logically...your own framework that is tailored to only your needs will be much faster than any of the other frameworks. Think about all of the settings that the other frameworks have to go through when loading and the database queries that involves. You save yourself all of that loading.
  • If you are going to be making a small project that will not need to be expanded on, such as a simple portfolio website, then a framework would just be more work than necessary.

There is also a very good article here that goes into other details. The author of this article starts out by talking about how he always was such a big proponent of frameworks.

http://jpst.it/jiYX

I am always going to push towards making my own frameworks unless I start doing some freelance work. I am constantly updating my framework and learning more and more. You will never hear anybody say definitely use or definitely do not use a framework because it all depends on the use.

Edit: There is also a question over at the Programmers site on this: https://softwareengineering.stackexchange.com/questions/49488/when-not-to-use-a-framework

Edit #2: One last article about why frameworks are not necessary: http://www.amberweinberg.com/you-dont-need-a-framework-if-you-have-a-good-developer/

这篇关于不使用PHP框架的原因?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆