CMS vs PHP Framework vs Hand coding


#1

Hey all, Needing some advice.

I'm wanting to build a personal website for some fantasy sports stuff. I'm I self taught front end developer without extensive backend experience. I'm wanting to get the site up to speed quickly. I need the following 3 features:

login/logout/profile,
forums,
and email functions,

to go along with a bunch of custom pages. I started coding my own authentication services, but why invent the wheel? I'm looking for a CMS or PHP framework that can get the basic site up fast with those 3 features, but also allow me to customize/code everything after that. Pretty much everything I have done has been hand coded.

The path to this post:
a. I've used CMSDragonfly in past. Stuck within the CMS format; not enough customization.
b. Currently looking at Modx. Not a fan of storing pages in the database, you can't just Textpad a file and make an edit. And using the web interface for editing converting file to resources, and turning all my php scripts into snippets.
c. Looking at CodeIgniter but I'm not a fan of the MVC framework (perhaps I'm just not used to it as a javascript coder) It seems like I'm forced to use the MVC system and not allow to do otherwise; a simple html file I uploaded says "page not found" because it assumes my url will be in the class/function/id format.
d. Looking at just grabbing the php classes from codeigniter and other sources and just coding the rest myself. Anyone know of a good place for php scripts.

And so I ended up here, What do you guys think? Can I get the level of customization from a CMS? Should I take the time to learn the MVC architecture? I may learn more by grabbing some php classes and coding myself or it my take me much too long.

Thanks for any advice

[edit:] sry mods. first post. I guess this should go in the PHP application design forum.


#2

Have you looked at drupal? It would have most of the functionality you wanted out of the box leaving you to design the templates. If there's anything you need that isn't covered by drupal's module system (theres a few thousand modules out there - checkout http://drupal.org/project/Modules) you can write your own.


#3

Get used to adhering to MVC. Until you have built a few applications as a series of complete PHP scripts, however, you will not appreciate it. Take the advice of others who have been there, learning MVC is worth the trouble/learning curve, even if it's CodeIgnitor.

CodeIgnitor has drawbacks and design issues that would stop me from using it for personal projects, however if a client requested CI I would have no issues using it, so it can't be that bad smile

ModX...I used it...was nice...similar in GUI to SilverStripe. Both will only take you so far.

Drupal although very flexible, will also make assumptions for you.

Joomla, in terms of complete control and extensibility, IMHO is the best solution. Implementing a component (whether it be a forum, blog, user, etc) is a difficult task but allows almost complete freedom and flexibility which is the most important factor in the long run.


#4

I looked at Drupal but had written it off for it's lack of ability to customize it and because as one of the most popular CMS's, I assumed that because it is targeted at the masses, it may be bloated.

Per your recommendation I tried it out. Not too bad for anyone who wants to put up a complete site quickly. And I was impressed by the number of available modules. But I felt stuck with the application, same as I felt with dragonflyCMS Also performance seemed slow. Not nearly as impressive to me as modx.

I'm leaning toward handcoding and importing my own classes for authentication and such,phpbb,etc. Not closed to php frameworks yet. I'll be making a decision soon.


#5

"Even if it's CodeIgnitor", sounds like you think I made a poor choice. My first framework was cakePHP, but I originally tossed it out because of the mvc framework. I compared a few others codeigniter , kohana, yii, symfony, and landed on kohana for it's php 5 strict approach and seemingly good coding style, but I backtracked to codeigniter for it's good documentation.

I haven't gotten far enough into any framework to prevent me from changing so what are your recommendations? What Which framework has the best classes? (Or does it matter, can't I just use codeigniter's classes in cakephp?)

I think I'll also install Joomla tonight for kicks even though I'm leaning away from CMS's.


#6

I haven't gotten far enough into any framework to prevent me from changing so what are your recommendations? What Which framework has the best classes? (Or does it matter, can't I just use codeigniter's classes in cakephp?)
I thing Yii has many advanteges in comparison with CI.
As I understand your problem was the documentation but having experience with MVC and practicing for while with Yii it while be ok.


#7

"Even if it's CodeIgnitor", sounds like you think I made a poor choice.

Not a poor choice, just not the best choice. Best is subjective and very dependent on perspective. It's no secret that CodeIgnitor is not as well architected as other frameworks, like Zend or Symphony.

CodeIgnitor will get you started quicker than Zend but you lose some control, whereas Zend is more extendable and follows better design practices, etc.

My first framework was cakePHP, but I originally tossed it out because of the mvc framework

CakePHP is very similar CI in it's interpretation of MVC. MVC is not evil it`s the implementation of it that can be.

I haven't gotten far enough into any framework to prevent me from changing so what are your recommendations? What Which framework has the best classes? (Or does it matter, can't I just use codeigniter's classes in cakephp?)

If I had to choose for a commercial project (one which wasn`t my own) I would use Zend, although it requires you to be somewhat OO savvy with best practices, etc. You get less bang for your buck and what might take you 20 lines in CI might take 50 in Zend you get total control over every aspect.

Thats not to say you can`t have total control using CodeIgnitor or CakePHP but when you want something different than the way CI or CakePHP do it you basically have to re-implement the entire module you are trying to override. Whereas Zend supports inversion of control, so switching from say one URI router to the next is a simple matter of implementing the provider class and changing the class instantiated.

This is a difficult concept to explain in a few lines and without showing code, but suffice to say it reulsts in more flexible design, easier to change, maintain, etc.

This is the main reason design (as in architecture not visual) conscious developers usually prefer Zend over CodeIgnitor.

You should be able to use CI classes in Zend and visa-versa but CI classes might have strange dependencies which are initialized during its bootstrap, which would make using the CI class in a Zend application a serious PITA. Zend does not suffer from this problem, but you will need to remember to download the whole framework as its classes have dependencies on other classes as well...

I think I'll also install Joomla tonight for kicks even though I'm leaning away from CMS's.

Joomla of all CMS is by far the best design-architecture. Its extremely modular and its concepts for components, modules and plugins are very clear. It doesnt use the termmodule` to describe all of the various extension points of the system which makes the learning curve much lower than say Drupal.

Joomla makes some really annoying assumptions and its difficult to build a component to be very portable and compatible with other components, modules, etc, but all in all its an excellent system with a lot of little caveats which could be improved that when added up would make for a much nicer system, but thats just my opinion. stuck_out_tongue

Lots of addon functionalities thuogh, probably more than Drupal, just about anything you can imagine.

If I had a cheap client and they expected complete backend admin interfaces with basic content management facilities, etc. I would use Joomla before WordPress, Drupal, ModX, etc. The biggest issue with Joomla is the management of artciles (which by default is fixed to being organized by section and categories) and linking to pages when adding links manually in the WYSIWYG editor -- very unintuitive and confusing to most new users.

HTH

Cheers,
Alex


#8

Thanks all for your recommendations. I will do a little more research before I make my decision.


#9

I tried Joomla and like it much better than Drupal in both features, admin, and performance, however I now officially think a phpframework will be better suited to my needs. Now I can focus my research more and select one.


#10

Well, I took a hard look at cakephp,zend,symphany, and codeigniter. As someone who is new to the MVC architecture, I wanted to keep it simple. zend and symphany seem a little more complex. I setup cake and ci and ci just felt better. Perhaps because it's not as strict on it's adherance to MVC. I think ci might be right right for me, giving me enough freedom, and enough helper classes and libraries so I'm not reinventing the wheel. This will be a good intro to mvc for me. I may try another framework on my next project. Thanks again.


#11

There are also newer small frameworks, maybe some of them would be enough for you:
http://jeez.eu/2009/09/12/damn-small-php-frameworks-because-size-does-matter/


#12

This will be a good intro to mvc for me. I may try another framework on my next project. Thanks again.

Any framework is likely to be better than something you roll on your own. Just because many developers find writing frameworks boring, when all they want is their application up and running ASAP. You would probably skip on small important details that will impact the overall architecture of your application.

CodeIgnitor is somewhere between this and design geek.

What I mean by that is, some developers really fancy OO best practices and architecture. They read a lot of books on design patterns, etc. If your a hardcore design geek, the little bit of extra 'wiring code' that Zend or Symphony require is worth the trouble, for a cleaner more flexible solution.

They will increase your learning curve though, because ithey designed by more experienced developers than the crew over at EllisLabs/CI.

CI is a decent solution for many developers, as it seems to find the delicate balance good design and "just get it done" mentality.

However, that being said, once you develop the boiler plate code for a Zend application, your pretty much at the same point you would be as CI, but not as limited. It's that boiler plate code that Zend seems to lack or at least not make very clear it's available in their docs, like CI does.

I'm pretty sure there is a bootstrap class, etc. smile

Have fun smile

Cheers,
Alex


#13

Instead of making my own thread on the same category I thought I'd hijack an old thread instead.

The thing is, I'm going to build a website for a client soon. The client requires a fairly simple website (text and images, the only interactivity being a contact form) and wants to be able to maintain it himself. So far all the websites I've made have been either hand coded or (more recently) built on top of a framework. Due to the limited size an complexity of the clients website I've been wondering if I should use a CMS to save myself a lot of trouble.

I don't have any experiences with CMS and I'm not quite sure how powerful/good they are. Due to the basic needs of my client and the fact that he is not really computer savvy I've been thinking about just building the website in Joomla. But I'm not sure how customizable it is, how high learning curve is (for me and him) and if it will fit my needs.

So what do you think? Should I build this site the way I always do, by hand and hand code some kind of an administrator panel for the client. Or learn some kind of CMS and build it from there?


#14

I had over 200 non-technical customers using Joomla and most were confused by the UI. I'd give Wordpress a look. It's easy to install, most people get it and is pretty straightforward to update. As long as they don't want to change the CSS you should be fine. It's what I recommend to the non-technical people now.


#15

@paulk13

If you haven't used a CMS before, I'd highly recommend it. It's worth it for the learning experience. It very quick to get a site up quickly it you don't need too much customization. The downside is that it has a template feel to it and is difficult to make it your own. Sounds like your client needs the basics though so I'd agree with @PHPKick and also recommend taking a look a Wordpress. It's simple, easy, and has a clean look.


#16

You know most frameworks let you set up custom routing, so you aren't locked into the site.com/controller/action/params URL scheme. That's not what MVC is about - that's just a default configuration to get people developing faster.

If you want to throw up a quick website I'd go with CakePHP or CodeIgniter. Zend and Symfony are geared towards application development... they are usually overkill for basic sites, making them very inefficient tools unless you have the experience with them.


#17

+1

@paulk: For the requirements you are looking for WordPress is perfect. Very easy interface on the admin side. Many plugins to extend it if needed. Plenty of support for yourself as the developer as well as for the client on how to update their content.

Use the right tool for the job. ZF is great if your doing something that is completely customized application but WordPress is perfect for the kind of project/site your client is asking for.


#18

Hmmm, I don't know a lot about wordpress, but is it really capable of letting me create a full site? I always thought it's use was strictly limited to blogs?


#19

Thats what I thought too. WordPress has come a long way from it's blog origins.

Check this out: http://www.noupe.com/wordpress/powerful-cms-using-wordpress.html


#20

Interesting link, I'll give it a go, thanks.