webapp vs. CMS - the same or not - php

I understand the classical definition of a CMS: it's a "webapp" the main purpose of which is to handle "content", probably that's generated by its users (kind of like all of us here at SO and the content we provide is text and code).
I also always got the impression that creating a CMS is supposed to be a Really Tough Thing. But how so? Isn't a CMS just a webapp like any other. I would guess that many webapps are tougher to code than a traditional CMS.
If I were to think of creating a CMS like creating any other webapp, would I be wrong?

I suppose you can consider a CMS as any other kind of web application ; only thing is there are lots of functionalities that are both required, and/or expected by users.
A few of those which come to mind :
authentication / access control
to the application, of course
but also to every kind of data
and even, maybe, each field of each type of content
a bit of ergonomy -- especially if targeting not technical users.
dealing with media (photos, videos, music, flash content, ...) ; both upload, linking, and consultation
if designing a CMS that's not oriented toward a specific website, you have to create something generic, that can work even in cases you didn't think about
extensibility : you will create the core of your CMS ; but users will most likely want to add some additional functionalities
which requires a nice extension/plugin system
internationalization / localization
Well, that's just a really short list, actually ; and there are probably lots of other ideas that could come to mind...
So, yeah, a CMS is a web application -- but it has to be generic, if you want it to work for more than just one (kind of) website.

Read up on CMS and DMS in wikipedia. Then it should get clear that a good CMS is really a big task.
Especially templating, workflow (fixed ones, support for custom ones), user hierarchies and so on... are hard to get right and still make them easily adaptable and customizable.
And don't forget that a CMS doesn't have to be a WebApp, but there are so called WebCM-Systems.
Aside this WebCMS are like every other big complex WebApp.
Content management system
Document management system

Related

PHP is a framework the best choice for basic CMS websites

Having been dong research on codeigniter,kohana and fuel php, they seem excellent for the large scale project I want to create with various sections of code. The system I want to build is to be a core set of code, which can produce a full ecommerce web application with plenty of modules, or can produce a simply few page site, with a news or gallery or whatever.
I have started thinking that I may be looking at the wrong thing for producing basic sites. From my very brief research, it seems (atleast on codeigniter) I need to use the 404 overwrite to point to my pages controller in order to handle basic content pages (from the base url /).
Should I consider a seperate code set for the basic sites, and use these frameworks only for large web apps, or is this the normal way frameworks would handle serving basic content pages.
I personally have a core framework (MVC/CodeIgniter) which I use for even the simplest static sites - Because someone will always say "Oh and can we have a shop" or a contact us form or ...
The overhead of the frameworks themselves is negligible if they're not doing any work - so why not put them in?
Another bonus is that you now know exactly what environment your modules will be in - you don't need to worry about maintaining one versions for sites with the framework and one for those without (One other benefit of using a framework is that it makes if far easier to maintain code in general - especially in multiple-developer environments.)
Th templating engines provided by most frameworks (or easy extensions to them) are often useful even for static sites (custom controls like a news ticker or custom markup/js validation for certain controls)
In short, unless you have extremely limited server resources (mobile device?) use a framework
Edit:
I'd add a note of caution - PHP is a very flexible, powerful language and when used well can create some truly fantastic sites. When used poorly, however, it is easy to make insecure websites.
From your post, you seem relatively new to PHP/Frameworks. Can I suggest you make sure that the framework you pick enforces good behavior (as much as possible)
CodeIgniter removes unsafe $_POST and $_GET variables, replacing them with safe equivalents. It also provides a parameterised mechanism for querying the database which helps avoid SQL inection attacks. These are important things to consider when comparing frameworks.
I personally found CodeIgniter to be a good balance of maintainability, security, extensibility and functionality.
I would consider using a CMS for the basic sites, something like Drupal, they do a lot out of the box and should satisfy your requirements for a basic site.
As for the eCommerce part, from experience its best use something that is separate from the CMS. Largely because projects or frameworks that are designed for that sort of thing are generally an application.
CMSes do what they do they do best, but that all they really do :)
Also have a look at Magento for your eCommerce needs.
Hope this helps.
I think your question is about what to use for "basic websites".
Should I consider a separate code set for the basic sites, and use
these frameworks only for large web apps, or is this the normal way
frameworks would handle serving basic content pages
If by basic sites you mean websites that have little to no dynamically drawn content, I would suggest a CMS such as Wordpress. You mention that you are using PHP and Wordpress is a very popular option. If you are creating a blog and a very static pages, this will be a great option. It can even be modified to do more 'dynamic' things that can be considered "CMS Territory". Once you get the basics of Wordpress down, and if you still feel that you need to modify it a lot, then you should look in to a framework that will allow you to have total control such as Codeigniter, Cakephp, etc.
Hope this helps.
Ben this is an interesting topic and no matter which direction you eventually go it would be nice to know your choice of combination. Depending on your requirements.
For something with medium range functionality OSCOMMERCE might be worth a check on. Also see Zencart, Virtumart and Megento.

Drupal (or some other CMS) or a simple MVC-based PHP framework like CakePHP?

We have a dashboard that we'd like to build for our customers. This dashboard displays various statistics about one or more of their (business) Facebook Pages. The statistics are pulled from Facebook using their FQL and Graph APIs, stored locally in a MySQL database, and queried/derived/presented to the user based on dates requested and some other variables. Additionally, users will be able to take action on various items (e.g., reply to wall posts, etc.) using their JavaScript SDK.
One of the external developers we spoke with -- currently don't have any resources within the company with time to work on this -- has proposed building the system around Drupal. Now I'm a fan of CMS systems for web pages, blogs, etc. but using something like Drupal did not come to mind here as much of the functionality seems irrelevant.
Can someone please let me know the advantages and disadvantages of using Drupal for custom development work like this? While we're looking for an elegantly designed system that our developers (as we hire them) can maintain and extend over time, I'm not so sure a CMS is the way to go.
Thanks!
I wouldn't recommend Drupal at all for something like this. You don't really need a full-blown CMS like Drupal, and it would be pushing it to say you should use a framework such as CakePHP.
Personally, I would build this as a standalone app. I see no reason to get a framework involved unless you plan on expanding the APP considerably in the future.
Drupal is often called a content management framework because it's so extensible, and certainly you could implement the dashboard in Drupal. However, I would question the developer thoroughly about their rationale for using Drupal before consenting to it.
Everything you specified sounds like custom development and has nothing to do with content management. You're manipulating data from Facebook, not a database of content produced by an editor. Your data is custom data, not simple Drupal node data (title, body, etc). I would go with a general Web application framework such as CakePHP. That way you get templates and user authentication without all the CMS overhead.
While I don't think that Drupal is really necessary in this case, I think that the final decision lies with what the strengths of the contractors you are using are.
If Drupal will allow them to finish it more quickly, and more securely (due to the fact that Drupal will provide well test user authentication, used by many), then I would say let them go with Drupal.
That said, I do agree that Drupal sounds to be more than what is necessary, and there would probably be far less cruft if you used a simple framework.

CMS design patterns and considerations

I am creating the cms for a relatively simple site - portfolio, some general content pages, custom blog etc.
What are some of the best patterns to consider before diving into the design.
I want the system to be as flexible as possible without being too complex.
I have looked for some good resources that discus cms and blog design but can't find anything too good.
My language is php but I suppose I am looking for more language independent advice.
Flexibility without complexity... nice program.
Maybe you're a genius and you will make something that feet your needs. But I think the biggest problem you will face is security and robustness. So really, take other advices on this page and have a look at wordpress, drupal, joomla and ezpublish. A lot of security stuff is already done. And not only security...
So, study some of these tools, track their flaws, check their security policy. Study how they handle caching, sessions, bootstrap, absolute & relative url managment, documents (images, videos, etc), ajax, authentification, identification, acl, user interfaces, rich-text editing, migrations, templating, page composition, content filtering (I try to remove the things you won't need, plugins, database abstraction, fine caching, css and js minification, all the extra-complex stuff not needed for a single instance simple CMS). Soon you'll have a 'picture' of the stuff they've done.
By doing this work, you'll certainly notice some big differences, and mistakes. You'll start going on irc and flaming developpers, telling them that others have done better choices. You'll start forgetting to shave. You'll maybe do some contributions. Some will be accepted, others won't. Old core devs doesn't like when someone explain why they made mistakes (and they make mistakes).
Now, comes the day you have a beard. Some of your contributions will start looking like forks. You will have ennemies, and friends, or followers. And you will start feeling the force.
And you will go on irc and tell god that the world is ugly and that you'll make the first CMS which will be flexible without being complex. And people will cry. And birds will run in circles. And you will be able to explain what are the design pattern of a CMS.
I am a user. I know what I want. Doing what I want will make user happy. I'm happy.
You shall not trust code from people with glasses
"MVC MVC MVC" : and the people responds 'that shall be done'
Seriously, There's still a place for a good CMS with disruptive innovation, the fork history has started long time ago with phpNuke (as far as I can remember). But some of the actual products are really fine for most tasks.
I'm probably risking the reputation here, but my experience shows that building your own CMS can be a very justified decision, especially when you get familiar with current opensource systems and understand what exactly they lack in terms of features, security or what not. Open-source often means a lot of backward-compatibility concerns and bad architecture decisions that cannot be easily changed.
I strongly suggest that instead of just taking on MVC you take a look at ideas that make it attractive.
One main problem with CMSes is the range of technologies involved in driving dynamic web-sites: imperative php for logic, declarative SQL for data queries, markup HTML for interface, imperative/functional javascript for dynamic interface, JSON for ajax calls etc. To keep the system manageable you have to keep these technologies in a controlled and understandable environment, but yet allow for smooth integration. Knowledge and best practices are out there. MVC is but one approach to manage this problem.
My choice at the time was to use the following principles:
Object-oriented code with static calling (php is a one-run thing, many instances of code objects are rarely justified), nothing except for one line of init code in global context
100% code-design separation with the use of XSLT and custom content processor
Custom router that can take any http request and reroute it to registered methods
Custom content processor that can take arbitrary method output and convert it into any usable format such as xhtml, xml, json etc. based on the request parameters (i.e. http://local/class/method.xhtml, http://local/class/method.json)
One copy of code for as many virtual web servers as necessary
SQL query builder (chosen for flexibility over ORM) for all database queries
Mandatory filtering of method input with filter_* functions
I believe you can choose a few that you like :) And good luck!
A good pattern to start with is the Model View Controller pattern, or MVC.
This pattern suggests to seperate your application's logic in the following layers: data logic(model), manipulation or business logic (controller) and display logic (view).
This is a good pattern to start with as you'll run into other problems (and thus patterns) along the way.
The following website explains the MVC concept quite well: MVC Principles
There is no point reinventing the wheel unless you are trying to better it in anyway.
THere are a lot of CMS available already. I personally have worked with ezpublish. There are other options such as drupal etc. This is the list of all open source cms avaliable - Click here
If you are just trying to learn then you can perhaps pick any one of the popular opensource and work on them to find its architecture and design.
Besides, I dont think anyone can give you a list of design patterns that would be best for a CMS tool. Because each design pattern solves some particular problem. And, you just have to choose a design pattern depending on a specific problem you want to solve in your project.
These days, writing your own CMS is a horrible waste of time. The usual open source solutions -- these days Joomla, WordPress and Drupal are popular -- are written by thousands of people and while you might loose a little flexibility by using on that's ready made this is by far offset by not needing to redo everything from scratch. If you go with Drupal, you can also enjoy high quality, massively scalable etc code :)
If Your rquiremnt is portfolio, some general content pages, custom blog only, Wordpress will be simple and Better.
In PHP so many CMS available , most popular one is Joomla.

setting up two CMS for one site, best practice

I am currently developing a (somewhat large) site for a magazine, the site mainly consists of sections like : news (for various categories), members, and some 'other stuff' (like shoutbox, polls, previous covers, photo galleries that can be tagged, and ad banners system).
Now, since most part of the site is a typical blog style (single-post page), I'm thinking of using Wordpress as the main engine because of its powerful backend with a good (easy to use ?) WYSIWYG editor, nice page organization, media handling, and lots of other features. Naturally that leaves me with the 'other stuff'. (banner management, photo tags management, etc.)
The easiest way (well, I think) was to set up another CMS (let's call it CMS2), to handle all those things that would be impossible or probably difficult to integrate into WP admin, and then trying to cope everything in the frontend, WP style.
My questions :
Is it good (normal) for a site to have two (or more) CMS behind it ?
What could possibly go wrong ? (or perhaps, is there anything I should know beforehand with this kind of approach ?)
The other alternative would be to look for another good, single way to handle everything. But the main problem now is to find a CMS powerful and flexible enough for those. What framework / CMS is the most appropriate for this (according to you) ?
Other alternative ?
Many thanks in advance.
I think its too complicated and that problems are likely to arise around the fact there are two systems. Its also not great from a usability perspective.
You should look at some of the beefier CMS options. Drupal has a lot of plugins and functionality available, be suprised if it can't do what you need. Joomla is also worth a look, as is CMS Made Simple (CMSMS).
Honestly I think it's a pretty bad idea, at least on the background of my own experience.
The main disadvantages:
doubles the amount of knowledge an admin/editor has to have/develop
doubles the amount of security risks
doubles the amount of updating/patching the CMS installations
lowers the probability of finding a replacement for you
it makes SEO related tasks more difficult
it makes development more difficult if features of the two sites are supposed to interact
it makes interaction between features of the two sites difficult or impossible (due to the restrictions of the CMS)
What would that second CMS be anyways?
If it is a site with the dimensions you described, why not using a real CMS?
Both Drupal and Joomla can handle all of the requirements you describe!
Take some time to evaluate, which one to choose and go for one CMS!
It could be a good idea to use WordPress, depending on the features you want in your blogs. Drupal has a 'blog' feature, but it's a bit limited. (For example, people can't leave comments using OpenID like they can in Word Press - although I haven't used Drupal in 6 months or so, it might have changed. For an example of Drupal blogs, take a look at this drupal site ).
Drupal still has the easy to use WYSIWYG editor you mentioned, and has different types of posts (for example, you could just post an image, post an article, post a blog post, etc. When you create them, you can choose to publish them to the front page, or just to their category (depending on how you configure the site, it's pretty flexible).
So, if that's enough for you it will be alot simpler to manage!

Advice on building a distributed CMS?

I'm in the process of designing a PHP-based content management system for personal use and eventually to be distributed. I know there are a lot of CMS's already out there, but I really haven't found one that meets my all of my needs and I also would like to have the learning experience. Security is a large focus, as are extensibility and ease of use. For those of you out there who have built your own CMS, what advice can you offer? What features are essential for a core? What are must have add-ons? What did you wish you knew before starting? What's the biggest potential roadblock/problem? Any and all advice is welcome.
Edit: Any advice on marketing do's and don't's would also be appreciated.
In building a few iterations of CMSs, some of the key things turned out to be:
Having a good rich text editor - end-users really don't want to do HTML. Consensus seems to be that FCKEditor is the best - there have been a couple of questions on this here recently
Allowing people to add new pages and easily create a menu/tab structure or cross-link between pages
Determining how to fit content into a template and/or allowing users to develop the templates themselves
Figuring out how (and whether) to let people paste content from Microsoft Word - converting magic quotes, emdashes and the weirdish Wordish HTML
Including a spellchecking feature (though Firefox has something built-in and iespell may do the job for IE)
Some less critical but useful capabilities are:
- Ability to dynamically create readable and SEO-friendly URLs (the StackOverflow way is not bad)
- Ability to show earlier versions of content after it's modified
- Ability to have a sandbox for content to let it be proofread or checked before release
- Handling of multiple languages and non-English/non-ASCII characters
Well, building your own CMS actually implies that it is not an enterprise-level product. What this means is that you will not be able to actually implement all features that make CMS users happy. Not even most features. I want to clarify that by CMS I actually mean a platform for creating web applications or web sites, not a blogging platform or a scaled-down version. From personal experience I can tell you the things I want most in a CMS.
1. Extensible - provide a clean and robust API so that a programmer can do most things through code, instead of using the UI
2. Easy page creation and editing - use templates, have several URLs for a single page, provide options for URL rewriting
3. Make it component-based. Allow users to add custom functionality. Make it easy for someone to add his code to do something
4. Make it SEO-friendly. This includes metadata, again URL rewriting, good sitemap, etc.
Now there are these enterprise features that I also like, but i doubt you'll have the desire to dive into their implementation from the beginning. They include workflow (an approval process for content-creation, customizable), Built-in modules for common functionality (blogs, e-commerce, news), ability to write own modules, permissions for different users, built-in syndication, etc.
After all I speak from a developer's point of view and my opinion might not be mainstream, so you have to decide on your own in the end. Just as ahockley said - you have to know why you need to build your own CMS.
If you ask 100 different CMS users about the most important thing about their CMS, you'll probably get 80+ different answers.
The biggest roadblock is probably going to be people asking you why you built a new CMS from scratch.
If you don't know the answer to that question, I'm not sure why you're going down this path.
One thing to keep in mind is that for an internet CMS, folks are going to want integration points with many of the "usual" services. Leverage existing services such as photo sharing sites, Twitter, OpenID and the like before building your own proprietary solutions.
well i wrote a CMS for personal use and released it to the biggest chorus of chirping crickets ever! no biggie, though. i did learn a lot and i encourage you to move forward. my clients use it and like it and it's holding up fine.
but if i were to start over (and i might) here's the advice i would give myself:
scrub everything everything everything entered from the user
user administration is a product differentiator. bonus points for being able to handle someone copy/pasting from WORD.
extensibility. 90% of the comments i get are from developers who want to use the cms to host "some" of the website pages but not others. or they want to embed their custom scripts into the page among the content. my next cms will be as modular as i possibly can handle.
many folks are absolutely fanatic about clean urls.
From marketing point of view:
1) Make it templateable.
2) Make CMS SEF and have SEOed URLs.
If you need to build custom functionality where your CMS is really a window to the rest of your business layers, then use something like PyroCMS or FuelCMS which are based off of CodeIgniter framework.
Developers usually get lost in the weeds with Drupal and Joomla! / Wordpress quickly become spaghetti code-laced doozies over time. Its how much you have already drank from the Kool-aid punch bowl.
I know this isn't a direct answer to what you're looking for but if you haven't looked at it yet I'd recommend checking out CMS made simple. It has much less bloat than other CMS's and is fast and efficient. It's open source so it may be a good reference point for any questions you will run into.
Just use Drupal.
Out of the box it is very light and fast. You add modules for virtually everything, so that can be daunting but it is fantastic.
Its secure (NASA and The White House use it), its modular, its open-source, it is well supported, has a reputation for clean APIs, and has hundreds of modules from SEO to Wysiwyg....

Categories