We don’t allow questions seeking recommendations for software libraries, tutorials, tools, books, or other off-site resources. You can edit the question so it can be answered with facts and citations.
Closed 8 years ago.
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(5)
我建议您查看MVC 设计模式,以便在开始使用它之前了解它。
理想情况下,你应该已经完成了一些让你遭受了一些痛苦的项目,因为当你的项目至少完成一半时你想改变一些东西。(这是许多这样的项目背后的主要动机之一) -称为高级编程技术。易于修改、灵活性等)。
这就是你提到的东西(OO、MVC,我会添加 TDD、设计模式)的全部用武之地)。
我为自己做的并建议其他人做的事情如下。研究您想要的任何内容,无论是 TDD、MVC 还是任何其他高级技术。但等到你需要它们的时候。
在我个人看来,当一个人经历过一个幼稚的项目并遭受这些技术提供的功能缺乏的困扰时,可以更好地理解 OO 和 MVC 的价值......
黄金法则是......< strong>只有在理解新技术并看到它能带来什么好处后才开始使用它。
我这么说是因为我在现实生活中看到很多人使用诸如 OO、MVC 甚至设计模式之类的东西不明白为什么 在后面。我认为这根本没有帮助。
祝你好运。
I would suggest you look at the MVC Design Pattern so that you understand it before you start using it.
Ideally, you should already have made some projects where you suffered a little bit because you wanted to change stuff when your project was at least halfway done.(This is one of the main motivators behind a lot of so-called advanced programming techniques. Ease of modification, flexibility and so on).
This is where stuff like what you mentioned (OO,MVC, and I would add TDD, Design Patterns) all come in).
What I do for myself and suggest others do is the following. Look into whatever you want, be it TDD, MVC or any other advanced technique. But wait until you need them.
In my personal opinion, one can much better appreciate the value of OO and MVC when one has gone through a naïve project and suffered from lack of functionality these techniques provide...
The golden rule is.. only start using a new technique when you've understood it and seen what benefits it can bring.
I say that because what I see in real life is that many people use stuff like OO, MVC and even Design Patterns without understanding the why's behind. I don't think that helps at all.
Good luck.
我强烈建议您查看 Kohana 框架。它是一个 HMVC 框架,具有级联目录结构。如果您正在寻找有关高级主题的书籍,“PHP 对象”,
Matt Zandstra 的模式和实践”很好地描述了 PHP 中的设计模式。“
I strongly suggest you to take a look into Kohana framework. Its an HMVC framework, with cascading directory structure. If you are looking for books on advanced topics, "PHP Objects,
Patterns, and Practice" by Matt Zandstra describes very well about Design patterns in PHP. "Pro PHP Patterns, Frameworks, Testing and More" is also an excellent book which discuss about many advanced topics.
该教程讨论了实现自己的MVC框架。您可以使用现有框架来实现使用 MVC 范例的应用程序。为此我碰巧更喜欢 Zend。以下是使用 Zend MVC 框架的教程:
http://framework.zend .com/manual/en/learning.quickstart.intro.html
That tutorial discusses implementing one's own MVC framework. You can use an existing framework to implement applications using the MVC paradigm. I happen to prefer Zend for this. Here is a tutorial on using Zend MVC Framework:
http://framework.zend.com/manual/en/learning.quickstart.intro.html
您可以尝试从 Yii 开始,它易于学习和使用:
http://www.yiiframework.com/tour/
You can try to start with Yii it easy to lear and use:
http://www.yiiframework.com/tour/
为了理解这个概念,我发现大量阅读以及从头开始实施它都很有帮助。一些资源:
书籍资源:PHP In Action,MVC 页面。 (很棒,因为提到了应用程序和 Web MVC 之间的区别)。
理解概念:http://www.cs .cmu.edu/~pattis/15-1XX/15-200/lectures/modelinmvc/
构建您自己的教程:http://net.tutsplus.com/ tutorials/php/create-your-first-tiny-mvc-boilerplate-with-php/
构建您自己的教程,更复杂:http://www.nathandavison.com/posts /view/11/custom-php-mvc-tutorial-part-1-introduction
To get my mind around the concept, I found a lot of reading to be helpful as well as seeing it implemented from scratch. Several resources:
Book Resource: PHP In Action, pages on MVC. (Great because mentions the difference between application and web MVC).
Understanding the Concept: http://www.cs.cmu.edu/~pattis/15-1XX/15-200/lectures/modelinmvc/
Build Your Own Tutorial: http://net.tutsplus.com/tutorials/php/create-your-first-tiny-mvc-boilerplate-with-php/
Build Your Own Tutorial, more complex: http://www.nathandavison.com/posts/view/11/custom-php-mvc-tutorial-part-1-introduction