一起学习PHP和Yii

我不是在讨论使用哪个PHP框架,因为我试图了解它是否可行 期望同时学习PHP和Yii。 我已经在ASP Classic,VBA / Access和VB6上做了很多工作,所以我有编程经验但几乎没有经验真正的编程--OOP,PHP或框架。</ p>

我经常看到 在你学习Yii之前,人们建议你有几年的PHP和OOP经验。</ p>

我有一个公平的Web应用程序项目,应该真正用PHP / MySQL构建。 我只是想更好地处理我是否需要雇用某人,接受私人培训,或者我是否应该计划在开发中工作15年或直到破产,以先发生者为准。 : - )</ p>
</ div>

展开原文

原文

I'm not really debating which PHP framework to use as much as I'm trying to understand if it is feasible to expect to learn PHP and Yii simultaneously. I've worked a lot with ASP Classic, VBA/Access, and VB6 so I have programming experience but little to no experience real programming - OOP, PHP, or frameworks.

I often see people recommending that you have several years of experience with PHP and OOP before you learn Yii.

I have a fair-sized web app project coming up which should really be built in PHP/MySQL. I'm just trying to get a better handle on whether I need to hire someone, take private training, or whether I should plan to be in development for 15 years or until bankruptcy, whichever occurs first. :-)

6个回答



不。 我认为你应该先学习PHP。 在考虑使用框架创建应用程序之前,您应该注意很多概念,特别是使用Yii。</ p>

Yii比CodeIgniter和CakePHP具有更高的学习曲线。 虽然您可能最初可以使用它们创建CRUD应用程序,但当您遇到内容抓取,图像处理等“真实世界”问题时,它会成为一个问题。</ p>

学习 PHP,使用vanilla PHP创建一个应用程序(博客/发票应用程序/库存系统),您将能够获得框架并学习框架,而不是语言(可能是某些概念)。 当您从在线获得足够的信息时,PHP书籍很有用。 当您想要了解作者的不同概念时,书籍很好,您会相当确定内容是正确的,因为技术编辑与您在线找到的未经编辑的内容相比,这些内容是正确的。</ p>

我推荐的来源:</ p>


  • php.net </ li>
  • stackoverflow.com </ li>
  • freenode ## php </ h1> </ li>

  • http://www.amazon .com / PHP-MySQL-Web-Development-4th / dp / 0672329166 </ li>
    </ ul>

    一旦你进入框架,你现在就知道为什么 你甚至需要一个框架。 为什么你甚至想在MVC中编码。 为什么MVC适合你。</ p>
    </ div>

展开原文

原文

No. I'd argue that you should learn PHP first. There are tons of concepts you should be aware before you even consider creating applications using a framework, especially with Yii.

Yii has a higher learning curve than say CodeIgniter and CakePHP. While you might be able to create CRUD applications with them at first, it becomes a problem when you are faced with 'real-world' problems like content scraping, image manipulation, etc.

Learn PHP, create an application (blog/invoice app/inventory system) with vanilla PHP, and you'll be able to get on a framework and learn the framework, not much of the language(some concepts probably). PHP books are useful, when you get enough information from online. Books are good when you want to know different concepts from authors and you'll be fairly sure that the content is correct since they are edited by technical editors compared to unedited content you find online.

Sources I recommend:

Once you get on a framework, you'll now know WHY you even need a framework. WHY you even want to code in MVC. WHY MVC fits you.



我认为使用框架不应该是一个巨大的经验。 我有一段时间开发php web应用程序,当开始工作时,必须同时学习php和Symfony上的OOP,这并不难。 我认为这一切都取决于你对OO范例的基本理解,如果你将利用基于MVC的框架。</ p>

根据我的经验,Symfony它非常简单和强大 框架,你应该检查出来。 它还有一个指导教程,以便您可以同时学习和实施:</ p>

展开原文

原文

I think that using a framework should not be a monumental experience. I've some time developing php web applications and when started working had to learn OOP on php and Symfony at the same time and it was not that hard to do. I think that it all depends on wheter you have the basic understanding on the OO paradigm, if you will take advantage of MVC based frameworks.

In my experience, Symfony it's pretty straight forward and robust framework, you should check it out. It also has a guided tutorial so you could learn and implement at the same time:



我也来自ASP / ASP.Net世界,我正在学习PHP和Yii。 这不是那么难。 Yii只是一个功能库和一种做事方式。 去找自己的Yii书,你能找到的最好的PHP 5书,以及MySQL和Apache上的书,你将在几周内启动并运行。 O'Reilly的书籍写得很好而且简短。 </ p>

此外,获得一个好的(免费)IDE(如NetBeans或Eclipse)和调试器(如xdebug),然后逐步查看代码以更好地理解它。 </ p>
</ div>

展开原文

原文

I am from the ASP/ASP.Net world as well, and am learning PHP and Yii at the same time. It's not so tough. Yii is just a library of functions, and a way of doing things. Go and get yourself that Yii book, the best PHP 5 book you can find, as well as ones on MySQL and Apache and you'll be up and running in a few weeks. O'Reilly books are well written and short.

Also, get a good (free) IDE such as NetBeans or Eclipse, and a debugger, such as xdebug, and step through to the code to understand it better.

douwang4374
douwang4374 显然你可以把Notepad ++挂钩到xdebug,但我从来没有这样做过。 我使用Notepad ++进行快速文件查看和编辑,但我更喜欢Eclipse进行调试以逐步执行代码和查看变量等。使用Eclipse设置xdebug有一点学习曲线,但它并不坏。
接近 10 年之前 回复
dua27031
dua27031 是的,关于这本书
接近 10 年之前 回复
dongnuo6310
dongnuo6310 我没有尝试过Notepad ++,所以不能肯定地告诉你,但NetBeans w xdebug对我来说一直很好用。 Eclipse更易于定制,但Netbeans更容易上手。
接近 10 年之前 回复
dtxpz8785
dtxpz8785 我还假设你在谈论这本书:使用Yii 1.1和PHP5进行敏捷Web应用程序开发
接近 10 年之前 回复
ds0678
ds0678 我用Notepad ++。 我认为NetBeans或Eclipse与xdebug一起会比这更好吗?
接近 10 年之前 回复



在同时学习PHP和框架时可能遇到的唯一问题是对特定类/函数是否为本机PHP的一些疑惑 或框架的一部分。 </ p>

就书籍而言,当网上有如此多的资源(索引和可搜索)时,我真的觉得很难证明花钱。 我在PHP中自学,主要使用PHP在线手册,用户提供了关于该手册的注释和一些开源库。 这同样适用于MySQL和Yii。 我在早期的几本书上花了一些钱,而且我没有发现它们有用作为参考 - 实际上他们除了支持我的显示器在过去几年里什么也没做。</ p>
< / DIV>

展开原文

原文

The only issue you might run into when simultaneously learning PHP and a framework, is some confusion over whether a particular class/function is native PHP or part of the framework.

As far as books go, I really find it hard to justify spending money on them when there are so many resources (indexed and searchable) on the web. I am self-taught in PHP using mainly the PHP online manual, the user contributed notes on that manual and some open source libraries. The same applies for MySQL and Yii. I have spent some money on a couple of books in the early days, and I have not found them useful as a reference - in fact they have done nothing but prop up my monitor for the last few years.



我会说“去吧!”。 当我学习CodeIgniter时,我做了同样的事情。 如果您了解ASP或其他语言,PHP必须快速提取。 Peple说PHP是最容易学习的语言。 我不太了解Yii,但如果您认为这是您的项目所需的框架,我认为即使您外包,您也应该至少知道某些级别的PHP / Yii。</ p>

我会花更多时间找出适合您项目的框架。

谁是最终用户? 谁将成为网站管理员? </ p>

祝你好运!</ p>
</ div>

展开原文

原文

I would say "Go for it!". I did the same thing when I learned CodeIgniter. If you know ASP or other language, PHP must be quick to pick up. Peple says that PHP is the easiest language to learn. I don't know Yii well, but if you think it is the framework you need for your project, I think you should know at least PHP/Yii both in some level even if you are outsourcing.

I would spend more time to find out which framework suits to your project. Who is the enduser? And who is going to be a webmaster?

Good luck!



我首先学习PHP,然后学习PHP OOP,然后学习MVC。</ p>

我认为这是 最好的路线。 因为MVC需要OOP,你应该在尝试MVC之前先学习OOP。</ p>
</ div>

展开原文

原文

I learned PHP first, then PHP OOP, then a MVC.

I think this is the best route. Because MVC is requires OOP and you should learn OOP first before trying MVC.

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问