开发者

New to PHP frameworks, how about this approach?

开发者 https://www.devze.com 2023-04-08 04:13 出处:网络
I\'m about to start a new PHP project of my own, let say is a CRM SaaS. I\'m no PHP expert, I\'ve been developing very simple PHP/MySQL websites for several years. I know CSS, jQUERY, etc. enough to f

I'm about to start a new PHP project of my own, let say is a CRM SaaS. I'm no PHP expert, I've been developing very simple PHP/MySQL websites for several years. I know CSS, jQUERY, etc. enough to figure out how to do specifically what I need at that moment.

Few months a go I found out about the existence of PHP frameworks so I was thinking to check them out. I haven't got into the project yet, and I haven't use a Framework before, I will study OOP and Secure PHP before getting into it.

Now, how about having my project in 2 main stages:

A) For the sake of having the project up and running fast to our (l开发者_C百科ocal first)market, we could use the essential data managing features the Framework already offers. We'll be sticking with its own way of "showing" and "linking" stuff(the "views" I guess).

After all, the Project is mainly logging in and managing good amount of data(contacts, products, blog, messages, purchasing orders, users, etc. etc.) So, our customers having the ability to manage this, is already a good situation as they don´t have used other online applications to compare it. This stage will be solid, secure and promptly delivered.

B) Now, stage A) is NOT the main idea, my plan is to have it the best way possible specially in its interface, for example like how facebook manages every click and option as easy and fast as possible.

So this interface and functionality improvements will be added latter, I'm talking about how the table grid reacts in certain regions or links, a dashboard with certain data, etc... and here is what I don't know how hard is going to be, but, I suppose that because the views and html is customizable, I will be able to do whatever I need to integrate jquery, ajax, css, etc etc. right?

what you guys think?

Or should I even consider to use a Framework at all?

(Yii is on my top option)


A framework simply provides an architecture to help you develop code faster and make it easier to maintain. A framework is not going to restrict what you can do in the general sense; it will simply give you proven tools to build an application.


I have wrote a blog article about UI Frameworks and it seems exactly what you are looking for. If you plan to manipulate with data a lot and you don't mind the framework to do interface for you, then finding a framework which can save you from looking into a HTML / AJAX / CSS / JavaScript / JSON is very realistic.

With the right choice you can focus on the code and when you come to the point when you need dash-board you can add some HTML templates. Implementing all the other base stuff is just reinventing the wheel.

Learning OOP is right choice too.


I strongly recommend a framework or constructing some framework before you start.. Build a true MVC setup, Smarty 3 makes a great view layer and lets you maximize template reuse.. anticipate tasks you'll need to commonly do - like minimize all your js and upload to a CDN and make these as automated as possible. Stay object oriented and try to approach 100% autoloaded code so you don't need to waste time remembering the paths to your files. A little forethought can save you a ton of time and lead to much butter code quality..

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号