Developing a newspaper site in Drupal - drupal

I need to develop a newspaper site in Drupal, I've already played around with Drupal a little, and I think I know which modules would best suit my purposes. Naturally, one of the modules I'll be needing to use most is Views, but I have a couple of questions:
Because this is a content-intensive site, I was wondering if using 5-6 views on each page to generate node teaser + thumbnail lists would impact performance adversely?
I am a designer with significant front-end development experience. Like I said I've played around with Drupal quite a bit and other than running into a few hurdles which I eventually overcame, for the most part I was able to get it to do what I needed it to. Having said that, does one also need strong programming skills to fully develop a site in Drupal?
Thank you very much for your help!
Jane

Views offers caching and Drupal also has block caching, which should help you improve performance. The SQL that Views generates is never as good as handwritten SQL, but if you make simple Views, the SQL is actually quite good and not a performance problem (unless you have millions of page views).
If you can create the features you need, with modules from Drupal.org, you don't need strong developer skills. But you do need to know some PHP to make a Drupal theme which is what controls the layout of the site. It will also be a great help, in understanding the Drupal theming system, but not a requirement.

First off, check out openpublishapp.com for a Drupal distro that is made for publishers from the ground up, it's pretty hot.
To answer your questions:
1) As far as performance and views goes, having 5-6 views on a page is a normal requirement for a drupal news site and the performance issues are usually handled by views/panel cache, and using a page cache like Varnish in front of a web server, Object caches like Memcached (for the DB) and opcode caches like APC...if you don't want to learn all that off the bat you should still be fine if your traffic isn't too intense (but go sign up at getpantheon.com for awesome hosting with all of that and the kitchen sink, and check out groups.drupal.org/pantheon)
2) If the functionality exists by way of core/contrib modules, to fully develop a site for the most part one only needs to understand enough PHP to theme, and often with starter themes like Fusion, and some of the others you hardly even need that, just an understanding of how they work and are extended (which is well documented). That said, if you want functionality that doesn't exist, you'll have to code it, or have someone code it for which strong programming skills are desired, but not necessarily required :)

Even I recommend the use of the OPENPUBLISH - https://www.acquia.com/solutions/publishing
On top of to this you can make an efficient usage of
1. APC - PHP byte-code caching
2. Drupal Caching - block/template/view level caching
3. Boost - Caching module which doesn’t need any external tools
4. Varnish - HTTP accelerator
5. Memcache - Data intensive content.
Apart from this you will also need to think effectively on deciding on DEPLOYMENT ARCHITECTURE of the site - preferably Acquia or Amazon environment.
Learning curve may vary depending on your current skills in PHP or Drupal. Usage of already established distribution like OPENPUBLISH may help you to minimize the dependability on too much custom coding.

Related

writing from scratch or using CMS for heavy database use website

we want to build a website that have some forms (including image attachments, info, etc…) online payments, tracking system, and other features that I may add later.
The number of users using the site is estimated to be maybe more than 50,000.
I'm using Wordpress to develop regular websites, but I'm afraid to use it in this project because I don't know how optimized is WordPress for high database usage (and page rendering, bandwidth usage, and …)
My options (those that I know) are:
WordPress
Drupal
Pressflow
Agility CMS
Writing PHP/MySQL code from scratch (or using a framework)
I know it maybe unrelated, but how good is to use ASP.net instead of these options?
Right. If you are most comfortable with PHP (the scripting language behind Wordpress and Drupal), you'll most likely be more comfortable making the step to Drupal. Pressflow is just a fork of Drupal optimized for particular needs (and there are other forks of it -- all of them are really just Drupal and are often the basis for various Drupal distributions).
ASP.NET has a lot of capable options to do this. The most common ones (at least in my world), are Kentico, Umbraco, and DotNetNuke. There are a ton of others.
You'll find lots of capable CMS systems to work with no matter what language you're looking at. Use what you're most comfortable working with.

Should I avoid using a CMS if I want to be able to quickly make good sites with more features/options to customize than Wordpress?

Should I avoid using a CMS if I want to be able to quickly make good sites with more features/options to customize than Wordpress?
I want to become a better webdeveloper and able to quickly make good, fast, secure websites with lots of functionality without being limited so as I'd be with Wordpress. I don't see writing lots of plug-ins to reach the same functionality as a nice solution for doing my own programming.
I have written a few games, quizzes and other scripts I'd like to be able to recycle or easily adapt to work with the CMS.
I currently have a multi-lingual website that works with a /nl/ and /en/ part, that has a few self-written games I wrote in PHP.
CakePHP has a very good CMS called Croogo. It's still quite a young project (still in beta and being actively developed), but the great thing about it is that its a Cake app so it's coded to the well-documented Cake standards.
Whereas customizing/extending Wordpress, Joomla, Drupal et al would mean you'd have to invest a huge amount of time learning about their respective frameworks, all for the sake of one part of any given website (the CMS), if you learn CakePHP, you're learning a much more advanced and flexible framework that can pretty much be used to do anything well beyond the confines of CMSes.
If you learn Cake (or if you already know Cake) you'll find that you already understand Croogo without having to invest much additional time at all. Code you write in Cake can easily be packaged to be a Croogo plugin and even if Croogo doesn't stay around for the long term (I hope it will!), it wouldn't be difficult to re-factor all the plugins you've written to work in any other Cake-based CMS that comes along in the future, or even your own Cake apps.
Croogo is pretty basic, but quite powerful. It has a Wordpress-like feel to it, it supports nice URLs via an amazing reverse-routing system, the /en/ /nl/ language thing you mentioned works out of the box and it's very easy to get any of the huge array of Cake components and plugins working in harmony with the CMS through the use of hooks.
I'm currently working on a project using joomla and there are a ton of custom features that I need to implement. I usually have to create a plugin or module in that case. It's a pain. I'd much prefer doing most of this from scratch instead of hacking at the code. If I had a choice, I would not use a CMS. I hate them.
I think ultimately it's about long term support. When you build a custom CMS in cake or another framework it is much easier and faster for you to customize and build the way you wan too. This works great if this is a project you are planning on supporting (by this I mean bug/user support for when you unleash this CMS on non devs). This can become a headache pretty fast when things need updates and clients are looking for fixes and changes. It's completely manageable, just more of a headache then something with community support.
That being said, if you are comfortable in wordpress the amount of support that exists in that community is huge. So often times you can leave the project knowing updates for the CMS and plugins will come in at a regular speed.
TLDR So if it's a project you know you will be supporting long term (or people with the same comfort and skill level as you) then I would say build it your self for ease of build and customization. If this is a one off or something you plan on handing off to a client with little to no support, building inside of a community supported platform is best.
I really comes down to priorities, if you what to build a site really fast a CSM is hard to beat, but you do not have the same control over the core as you do when you wright it from scratch.
But you can do most any thing with plugins/modules so the control is there if you are willing to work for it. If you wright it your self you will be the only set of eyes most of the time so it will in most cases be slower to implement new standers and security fix's (because you will need to find them first) but with a CMS you will have many people working to make it better and safe at the same time.
If you want to be well rounded I think youe need to be able to do both, you can't control what the customer wants to use some times.
You can make site very quickly with a CMS like Joomla but the problem is even having over 7000 extensions sometimes for your particular purpose you don't find an extension and developing an extension can be real tough. it requires a comprehensive knowledge of Framework. If all you need to do is manage content CMS is the best choice. If it is like a web app and require more interactions go for some framework which provide the basic skeleton of your app. e.g. for CRUD operation many frameworks provide scaffolding feature and make this thing a piece of cake. CakePHP, CodeIgniter, Kohana are some of the best PHP frameworks you can use.
Using Chinese Cms DedeCms or phpcms And developer it more easily !
I like PHPCMS, it works with nginx, fasctcgi, mysql on linux or windows.
I use it to make portal site or enterprise sites group. The multi-site architecture and PHPSSO works well. Template engine is also strong enough.
take a look at big mysite: xinm123.com
Most important thing: it's open source.

Drupal as framework

Can we use Drupal as a framework for larger application? Is it suitable for developing big application in its framework, or is there any limitation of it?
I want to use Drupal as a framework in my application. Is it worth?
If you are looking for a development-framework, Drupal is probably not the right choice. If you are looking for a suite to build websites, Drupal is probably the right tool.
People often tell that Drupal is a CMF, where the F stands for Framework, but in reality, Drupal is simply a flexible CMS.
On a high level, web application framework are split into two categories: the MVC and the CMS. Model View Controller being what most people call a framework. CMS being simply a flexible CMS with application-development abilities.
In practice, what Drupal lacks is:
Proper architecture. Most things in Drupal, evolved organically; which causes inconsistency, unexpected behaviour and unexpected barriers. Not saying that Drupal is not build up properly: just saying it has not been architectured: designed as a whole.
Principle of least surprise. Many frameworks allow skilled developers to create sites in a few hours. With Drupal you must gain a lot of experience and best-practices before you can be confident to roll out websites on planning.
MVC. Drupal has a distinct database-layer and a theme(view) layer, but they are unconventional, and often misused. And certainly not after a structural pattern.
unopinionated behaviour: a framework can force certain methodologies, libraries or even encourage certain behaviour, but it should not have hardcoded/none-overridable defaults that dicate your end-product. Or, in English: Drupals core has many defaults that dictate how you are going to set up, layout and structure your website, regardless of your (clients') needs or wishes. Modules or addons come even momre often with behaviour and often looks built-in and/or hardcoded.
DRY, don't repeat yourself: Drupal heavily depends on repeating oneself. Its entire theme-system depends on copying pieces of code into custom files and changing tidbits. Its form-override system requires copying large parts of the default form into custom modules and changing the parts that one wants modified.
Many of these lackings are the main cause for delay and budget-slips, as seen in my +10years Drupal-experience. Where the unopinionated behaviour part has proven the most nasty one to most of the projects I was involved in. Apparent simple features or ideas prove to take up large parts of the entire budget; Tiny details eating away development-weeks; that last 20% taking not just 80% of the effort, but sometimes 300%.
Besides that, Drupal does not follow OO patterns, which (according to the general consensus) is a bad thing. There is no inheritance, not DRY-practice, no object-relation-mapper*) and no unittesting-practice.**).
This might all sound negative, but in reality, people manage to build nice Drupalsites despite all these "downsides". That is because they adhere to the defaults by Drupal mostly (standard where possible, addons where changes wanted, custom development when no other option is left).
*) In fact there is; in Drupal 7, PDO was introduced, but is not (yet?) used as ORM much/at all.
**) In fact: all of core and many contributions have tests, but these are integration tests and a rare unit-test. Integration-tests (DrupalWebTest) install a clean Drupal-codebase+database for each single test. Your average core-testsuite taking over 8 hours to run is not an exception. TDD is simply not (yet) possible.
EDIT Reading into your examples: Drupal is particularly bad in the area of "form wizards", though it has seen improvement in Drupal 7. Another notable lack, in Drupal, is a proper, programmable workflowing system. There are several modules that enhance or replace the simple workflow-system in core, but they are not easy, nor efficient (development-effort-wise) to program against. It sounds like the main features you want, are amoungst the most underdeveloped areas in Drupal
This really depends on the needs of your application. Drupal, while flexible and extensible, is first a CMS and comes loaded with features which may or may not be desired for a web application. But if out-the-box or with additional modules it provide a large matches for the more classic web application features (ie. user management, content management, plugin system, theme layer, etc.), Drupal provides a great framework to avoid re-inventing the wheel (or dependencies on third party/less-mature framework plugins).
Drupal as a steeper learning curve compared to most framework. As a framework, Drupal is build and designed to for the CMS it is. Historically, Drupal puts almost everything in database. The situation is now better with the generalization of exportables and tools like the Features module. Also, unlike most framework Drupal does not use MVC and is mostly not object oriented.
Yes! You can use it as a framework. You'd want to be happy with some of the core APIs like the menu, node and probably the form API. The menu router and access control are quite good.
I've worked on a couple Drupal sites that didn't quite work because the core requirements had little to do with a CMS. Drupal is very flexible but it most suited to content management. You can of course use it as some satellite CMS for some other application. Drupal can also be used for service driven architecture.
If you want to scale up big, you might consider a framework that places more importance on testing and test driven practices. Drupal is a late adopter of these practices and is not mature in this area. It's something that I find frustrating especially on large sites where regression error becomes an issue. Consider something like Ruby on Rails if this is of interest to you.
Good luck!
Note to self: Why would I wish someone luck on a software project? ... interesting.
Drupal 8 change a lot.
- It is OOP
- Using Composer
- Have good cache mechanism in core
- RESTful in core
So now it is easy can be used as framework for any app. At end web all ways have content. E-commerce have content. And so on.

How much of using Drupal involves programming?

I would like to ask those who are experienced with building a website with Drupal. I got a job like this, but I'm more interested in programming. I got also another job offer and cannot decide!!
How often do I get to programming/changing code in Drupal, when building a site in it? Isn't it just about clicking around and downloading modules?
the other job is different but i didn't want to write long descriptions here. This job with drupal got all the positives, but im afraid that its less programming, more clicking and im trying to learn more programming. the other job is classic php programming with company internal framework.
thanks guys
I work in a company where I mostly do Drupal development. Now it's hard to say anything concrete about your job offer, since we don't really know the company etc. There's not really a reason why doing development with Drupal should be any less coding than doing development with some other PHP framework.
You get a lot for free with Drupal, the whole CMS part, all the modules on drupal.org, and yes there will be some AI configuration, but it's usually not that much. All the configuration part of a Drupal and modules is pretty easy if you know what you're doing. For me I spend around 5% of my time for a project doing configuration, making views (a drupal module you can use to create displays) etc, the rest of my time, I use hacking away in my code editor.
As a drupal developer, you mainly do two things.
Write code to add functionality
Write code to alter existing functionality.
Drupal is run is procedural, so there's not much classic OO, instead you write code that gets executed when something happens. Fx a user logs in, then you get a chance to modify the user, do some things like counting how many times the user has logged in.
An important part of Drupal is also presentation. In Drupal we call this theming. Theming is also very code heavy. Drupal is very flexible, so you can overwrite functions used to generate the markup in your theme. These are classic PHP functions. Then there is the whole css, html js part as well.
If you have the chance to do Drupal development, I think you should take it. There is a massive demand for good Drupal developers, that know how Drupal work, and how to use the APIs. It will be something you can use to find your next good job. Knowing some random in house PHP framework, will probably not help you as much in terms of finding your next job.
It's going to depend on how much you want to customize Drupal. You'll typically get to spend some time altering code to change the layout or whatever other UI-related requirements your employer/client would like.
As far as altering the core of Drupal, you wouldn't want to do that anyway or you could run into trouble when a new version becomes available and you want to upgrade. Any custom coding would instead be done in the form of writing Drupal modules or plug-ins.
Comparing your two brief job descriptions, the "classic php programming" option sounds more like what you want to do. There simply wouldn't be a comparison between doing development in Drupal vs. doing development on some company's internal framework, but either way you would get some experience.
Don't let this answer guide your decision on the offers. Pick the one that feels right and works best with your lifestyle. You can always do your own research and development outside of work if you wish to gain experience or knowledge.
It heavily depends on the project. I work as a professional Drupal developer for 2 years.
Normally making a Drupal site consits the following steps:
the site builder gets the spec
the site builder makes a research what modules to use
the themer makes a wireframe
client accepts the wireframe
the designer makes the actual design
the themer starts implementing the design
the site builder starts installing and configuring the modules
if there are problems which can't be solved with the available modules, then the developer gets a specification
the site builder finishes site functionality and applies the theme
testing
deploying
As you can see, your job will be depend on which role do you work. If you apply for a site builder, then you don't have to code much. If you get hired as a developer, you will most likely end up writing bigger or smaller modules for different projects (this is what I do most of the time). At smaller companies, the site builder and the developer (sometimes even the themer) are often the same person.
However if you want to make sure that you will write code all day (and you don't know what roles will you fulfill at the Drupal company), I rather recommend the second job.

Web application integration with Drupal

We want to build a web application, that is specific to our domain, but also includes forums, blogs, etc in this application. Some integration points to Twitter and Facebook are also required.
There will also be a desktop application that connects to our web application for uploading data and downloading configuration and reports.
The question is, can we extend Drupal to host both the regular modules and our web application? (There will be business entities and their properties and daily data uploaded from the desktop application)
Or can Drupal be integrated with external applications? As an example, users and roles need to be the same and consistent across both. We may also want data from the web application searchable in Drupal.
I know this is a bit vague, but I cannot reveal more. I am very new to content management and I just wanted to know if someone has built this kind of application.
I try to rephrase what you wrote, just for you to check that I got your question right. You basically need to create a web application that:
Implements some of the standard functionality of Drupal
Have some custom functionality that should "blend into" the Drupal one (same users, same permissions, etc...)
Be able to upload/download content (or data) from desktop applications.
If I got you right, the short answer is: yes, you can do that with Drupal.
Now for the extensive one:
- Drupal has literally thousands of modules, so I expect you to get most of the things you want by simply installing the right combination of readily available modules.
- Of course, any custom functionality can easily be implemented in form of a module too (quite standard thing these days).
- The interaction with a desktop application is normally implemented via webservices rather than querying the DB directly. Drupal comes natively with a xmlrpc server and client, but you can scale up to SOAP - if you wish - via a couple of contrib modules.
Some additional thoughts:
If you choose to use Drupal, and you start from scratch, then you have to be aware you and your team will need to dedicate some time and effort to understand how Drupal works. Although - differently than Palantir - I stuck with Drupal, I agree with her/him on the fact that Drupal gets complicated complex right off the bat. This is the trade-off you have to pay in order to have a platform that - rest assured - is very flexible, extremely pluggable and rock-solid (otherwise it wouldn't have been used to redesign the whitehouse, nor Drupal would have got for the second year in a row the "best PHP CMS" award, I suppose).
The good news is: there are some excellent books out there, and I would certainly recommend "Pro Drupal Development" for an in-depth and all-around explanation of the system. Just be sure to get the 2nd edition, as the first deals with the now obsolete 5 seres. That said...
A very good thing about Drupal, at least in my opinion, is that most of the tweaks you might need to do to an existing functionality can be implemented by hooking into the original code from a custom module too. This IMO is the biggest advantage of Drupal: you never have to touch other developers' code to achieve your goals, and this means - for example - that you will be able to keep your core and contrib modules up-to-date without breaking any customisation you might have done.
Drupal is heavy. Compared to other CMS it sucks plenty of processing power and RAM from your server, and - unless you are going to have a very small site - I recommend to deploy it in conjunction with nginx, rather than Apache.
Drupal scales well, thanks to a good mechanism of caching and "throttling up" mechanisms. Strange as it might sound, Drupal scales very well on large traffic websites, so that big increases in traffic do not necessarily imply big increases in resource usage.
The user experience out-of-the-box on a Drupal site is quite poor. There is a massive work being done on this at the moment (here and here (video)), but improvements won't be available until D7 is released [soon, but then you will have to wait for the modules to be ported], so it is advisable to allocate some time to create an administrative theme, if the admins of your website won't be of the technical type.
At the end of the day, my advice is: if your site is going to go big / complex / with complicated business logic and lots of functionality, then Drupal is probably a good candidate. If your site is contrarily a small-scale one with standard functionality plus a few custom bits, maybe Wordpress / Joomla could fit your needs better [not because they are 'less powerful' but because Drupal strengths would be unused in this case, while Wordpress/Joomla simpler architecture would probably represent an advantage in this scenario]
Other options would certainly be frameworks like CakePHP or Django, for example, but that - IMO - is a totally different approach to the matter, I would say.
Short answer: Drupal is well suited to build something like that, especially if you are willing to integrate your app/logic into Drupal as a suite of custom modules. The other way, integrating Drupal into an external application, can also be done, but will give you more friction, as Drupals architecture is pretty much geared towards being a framework in its own right.
Longer answer: I have a pretty much opposite opinion/experience compared to Palantirs. I've been working almost exclusively with Drupal for a year now, in the context of two fairly complex/'enterprisy' projects (after several years of 'on the side' usage for smaller things). While I agree that it imposes some rigid rules (but not limits!), I consider this to be an advantage, as those rules give a clear guidance and provide proven ways on how to do things. The three parts Palantir mentions are good examples for this:
Menu system - Provides a well structured and effective dispatching mechanism that is easy to extend with your own stuff, while giving huge flexibility to tweak/manipulate existing/default paths. (Note that 'menu system' in Drupal denotes the whole topic of managing your URL space, not just the subset of 'visible' menus that is usually associated with the term)
Forms API - A declarative approach to web forms, with a well designed processing workflow and a whole lot of built in security features that you would otherwise have to take care of yourself. Also highly extensible, with straight options to adjust/extend already existing forms on demand, add new validation rules to any field or whole forms, multi step forms, javascript based form adjustments, etc.
Translation system - This is pretty complex, simply because internationalization is fricking hard to do. But it is built in, again giving clear guidance on how to do things in order to work in a generic way (though there are problems with quite some contributed modules that are not using/supporting it the way they should).
I could give more examples for parts where I appreciate the 'rules', but this post is getting long already, and I still have to cover some downsides ;)
So to sum up the positive part - if I where given the rough specs you posted, I'd say 'no problem' and go with Drupal, being confident that it would be a solid foundation for the custom parts, while providing all the 'standards' like forum, blogs, twitter/facebook integration and many, many others in the form of already existing solutions (even though those might need some adaption/tweaking).
Downsides: As always, there are flaws, and some of them are substantial, depending on requirements/circumstances.
Learning curve - Drupal is quite complex, and 'grokking' its concepts takes time. 'Playing with it for a week', as Palantir suggests, will certainly give you a general feeling/broad impression, but it is in no way enough to allow for a serious judgement of its pros and cons, as those will only surface while coding in/for it. So if you are already deeply familiar with an established web development framework, this might be an issue. If you have to learn one anyways, this should be less of a problem.
Database restrictions - As of Drupal 6, database support is MySQL or PostgreSQL only, using a Drupal specific 'abstraction layer' (which obviously isn't one ;)
Drupal 7 will move to PDO, which should (finally) end this questionable state.
Test/Stage/Production migrations - Parts of Drupals 'out of the box' flexibility are due to many things being configurable in the administrative backend, which implies that many important configuration settings are stored in the database. This makes migration of data and/or configuration between several instances pretty difficult/tedious, once you left the (early) stages of development where you can get away with complete dump/restore operations (see e.g. this question & answers)
These are the main ones for me, but you'll probably find more :)
I worked for over a year using drupal extensively, but I ended up abandoning it. Drupal, and other CMS systems out there, have very rigid limits and rules. I'd use Drupal for projects where you have simple requirements and few or no business rules. Drupal gets complicated almost immediately when you want to do complex things (especially pay attention at the menu system, forms, and the translation system if you need to be multilingual).
If your system will really be large, with all the things you mentioned, then I'd rather use a PHP framework to implement your business logic, and integrate external products as they fit (a forum, a blog, a twitter client, etc...).
But the advice is: don't trust anyone :) Download it, and play with it for a week. You'll be able to make your mind and be more confident about your choice!
As Drupal is open source, you can pretty much do as you wish with it. A couple of points though:
Changing Drupal's user/role structure would be tedious and unnecessary. You would need to have your desktop application authenticate from Drupal's MySQL database.
Drupal has hundreds of plugins for just about everything, so Drupal could no doubt run the whole "web" side of things including visitor stats etc. You would just need, again, to connect your desktop application to the correct MySQL tables and show the data as desired.
Don't forget to check other content management systems such as Joomla! (and many others). Each has its pros and cons. www.opensourcecms.com allows you to easily test CMSs and I've used it extensively in the past.
Just be sure to map out all the components first. Every hour planning up front saves many hours of headaches later.

Resources