Customize Your Managing News
How to customize the news aggregator or use it to build other applications
In Eric's announcement last month, he emphasized that Managing News is both a product and a platform. In this post, I'll explain what this means in concrete terms and how Managing News can be highly customized or used to build something other than a news aggregator. This post assumes some Drupal site building experience and at times some Drupal coding experience. But even if you're new to Drupal, it will give you a useful glimpse of what's possible with Managing News.
Modular architecture
The package that you can download at ManagingNews.com is the fourth iteration of Managing News. This time we paid special attention to keeping it simple and modular. Managing News consists of Drupal core plus about 20 contrib modules, four custom modules, five Features, and a design that is split into a base theme (Tao) with the actual theme on top of it (Jake).
Features
We have written extensively about Features in the past. If you are new to the concept, the quick explanation is that features are special modules that contain configurations for other modules. Use cases of Features are typically higher-level than those of modules. One example would be an "Event section" feature, consisting of configuration for the Calendar and the Date module. Features can be turned on and off just like any other module, and they have full access to the Drupal API.
You can see all the features in Managing News by going to the Admin section (link on the top left when you're logged in) and clicking on "Features":

We can see five features on this page: MN Core is the base feature. Most importantly, it contains the configuration for aggregation functionality. MN Search provides the search page and the configuration for saving searches and highlighting them on the front page. MN Channels offers a way of collecting single news items into custom lists that can be printed or distributed via RSS. MN About is a very simple about section that basically contains a book node and a menu item. Finally MN World contains the configuration for geo tagging map displays.
These features contain mostly configuration and modifications to default behaviors - the actual functionality they expose live in the underlying modules. Take, for instance, MN World. Geo tagging is done by the Extractor module, map displays are rendered by the OpenLayers module, and the maps themselves come from MapBox.
Every feature can be turned on and off by using the checkbox. For instance, let's say I decide that my installation does not need About pages or Channels. All I need to do is check off "MN About" and "MN Channels" and save, and then all functionality pertaining to these Features will be disabled. Note how the menu items disappear:

The nice thing about features is that they cleanly capture the functionality of a logical portion of a Drupal application. If you're thinking about adding functionality to Managing News, I encourage you to do this on the features level.
Customizing the look
Out of the box, Managing News' Jake theme allows for customization of the background image, the logo, and the base colors of the theme (Drupal core's color module at work), and of course the site title can be changed just like on any other Drupal site. Here is a look at the Theme settings in the admin section of a Managing News site with custom colors and name:

So you care more about your block than the World?
The default map settings in Managing News assume that the data in Managing News is of global scope:

The geo term extractor looks for countries and major cities, and the maps used in Managing News are world maps. But you can change this. Just go to "Import locations" in the Admin section to import your own location file:

If you would like to change the actual map being used in Managing News, check out Using MapBox tiles in Managing News on MapBox.com. This will be a good resource for you even if the maps that you'll use won't come from MapBox.
Store additional data
In some cases, you may find the need to store additional data with every aggregated item. Managing News uses the Feeds and Data modules to aggregate and store feed content. These modules allow for a flexible mapping and allocation of storage space for feed elements. Here is a screenshot showing how one would add the author field to the set of aggregated fields:

Once the author field is added, it can be displayed using the Views module:

After adding the author field to jake/templates/mn-feeditem.tpl.php, this is how it displays on the front page:

Performance
We configured the aggregator in Managing News to be easy-going, rather than fast-going and eating up your server resources. Depending on the number and activity of the feeds being aggregated, this configuration may turn out to not be aggressive enough. You can tweak the number of feeds imported per cron run by increasing feeds_schedule_num to more than the default number of five:
// In your settings.php file.
// The number of feeds to be aggregated per cron run.
$conf['feeds_schedule_num'] = 10;If you do that, keep an eye on on admin/reports/dblog to make sure that Feeds Scheduler does not exceed the PHP max execution time nor the time between scheduled cron runs:

For cases with many feeds and very active feeds, or when it is critical to have the system as current as possible, we have back ported the excellent Drupal Queue work that chx and others have contributed to Drupal 7. Drupal Queue essentially allows for parallel feed importing. Take a look at Drupal Queue's README.txt for instructions on how to set it up.
Examples
At Development Seed, we use Managing News as both a product and a platform. We deploy a series of out-of-the-box Managing News instances via Aegir. Here is a screenshot of one that we have turned on for the Knight Foundation, who partly sponsored the development of Managing News. It is a good example of "Managing News as a product:"

During the past couple of weeks, our team has been working with the National Democratic Institute on a project to visualize results from the recent Afghan election. We used Managing News as the base for a site that shows voting results in Afghanistan down to the ballot level. This site is a good example for "Managing News as a platform". Here is a screenshot of the site that is yet to be launched:

From a technical standpoint, the most interesting aspect of this site is that it doesn't aggregate news at all. The data is imported from CSV format once, and the main mode of viewing data is via maps and tables. Still, Managing News proved to be a worthwhile starting point for this build, as core configurations of Managing News could be reused. On both the Knight instance of Managing News and the Afghanistan election website, Feeds, Data, OpenLayers, Tao and Search play together in a similar way.
Modularity makes it possible
Taking a very modular approach with Drupal modules, themes, and Features results in a Managing News application that makes sense both as a product and as a platform. Further, keeping Managing News specific configurations and UI separate in Features and themes allows us to focus the underlying modules on their general use cases. This has the double advantage that these modules have a potentially larger contributor base while, at the same time, they are more flexible for ever-changing use cases.
This post is based on Managing News version 1.0 beta 6
nodes
hi there,
Managing News is ace, but I was wondering why the decision to storing the data from each feed as Data rather than using nodes. Would it be easy to adjust an install of Managing News so that each piece of feed data being brought in was stored as a node rather than just Data?
thanks again for making something so easy to install and use
thomas
Hi Thomas
Data is much faster while maintaining a good level of flexibility. Data is also better suited for large one dimensional data items as it does not bring the CCK overhead.
The infrastructure Managing News is building on (in this case most importantly Feeds and Views) supports nodes as well. So you could switch the storage model to nodes. It would take some building patience though and in the end you will have forked Managing News to an extent where it will be hard to upgrade to subsequent versions.
Hope this helps.
Alex
Adding a feed source
Under mapping a new syndication there is a list of sources – how can we modify this list?
Have a look at this issue on d. o.:
http://drupal.org/node/662504
mapping whole regions?
Hello, first off, this is absolutely wonderful. Thank you.
I was wondering if it would be possible to map entire regions on the map, not just specific cities or a specific lat/long. For instance in the landscaping and horticulture industry it would be ideal to be able to map regions where there are plant disease outbreaks, or map regions where plant materials are native and can grow. Would this be possible?
thanks, Jen
Sure, in a way
Hey Jen,
Sure – this isn’t something that’s obvious in the stock Managing News installation, but the locations it knows about are hierachial: cities to countries, etc. And the tree of locations in Managing News is completely customizable – if you’re tracking really local things or non-standard names for things (like industry names for regions), you can add those in. With some Drupal expertise, you could build navigation that lets you drill down the hierarchy.
freedback
Hello,
Managing News seems to be a great application but it lacks some documentation to customize it.
In my opinion It seems i have to be a drupal expert to customize it :(. I’m used to work with PHP framework, and it is really hard to figure out where the things are done with managing news.
For example, here are a few features that i would like to add, but i have no idea yet on how this could be done:
- can we put feeds into categories and changes the views so that we would have a list of categories and feeds inside, rather than a very ( very very ) long list of feeds ?
- can we mark each article as read/ not read and then filter them and keep only unread articles.
- Could we easily bookmarked each article and keep them on a place ?
- Concerning about openCalais web service , i can’t figure out how to attach the extracted data to a feed.
I know i have to read the drupal documentation and look deeply in some modules but i think we need more example.
thanks you for this beautiful application.
rccc
Level of expertise depends on level of customization
rccc,
You’re right, while some of the customization tasks (like theme, locations etc.) are easy, others (like those you bring up) are actual site building tasks and as such require the same level of expertise as in building any other Drupal application.
Most of these tasks are documented in the Drupal handbook: http://drupal.org/handbook – missing pieces can be flagged and/or contributed through the issue queues of Managing News or the respective modules in use.
Alex
ManagingNews -> OpenAtrium
Is it possible to encapsulate as features the functionality of ManagingNews and incorporate it into OpenAtrium? Just curious.
Kind of. We have a light news
Kind of. We have a light news aggregator for Open Atrium that we hope to release in the coming months. I just posted a screenshot that you can see here:
We have worked on some custom mapping features for project mapping within Open Atrium, like the mapping innovation project over at the Bank. More work is happening on OpenLayers 2, and there are sure to be more mapping features built for Open Atrium.
Hope that helps!
Bonnie
Cron job setup to automatically import feed with managing news
Hi All,
Is it possible to use a cron job that can be setup to automatically import feeds with ‘managing news’.
If yes, please guide me.
Warm Regards, Ashwani Dher
Of course. Managing News
Of course.
Managing News imports all feeds on cron, you will need to set up Drupal cron to make this work: http://drupal.org/cron
Alex
the election stuff looks
the election stuff looks wicked. I’ve been using MN for news stuff and its great, but this really stretches the boundaries.
Was there a huge amount of customizing to get the election results into shape?
There was a fair amount of
There was a fair amount of customization. Think of the election results site as a custom build that got a headstart by using Managing News instead of starting from scratch.
Introduction to Managing news for french readers
Hi all,
French speakers can read an article about Managing News here on my blog : http://www.pmoutet.fr/wordpress/produits-open-source/managing-news-la-no...
Hope this helps !
Pascal
Tattler at
Tattler at http://tattlerapp.com allows for quick channel creation, then it creates feeds. Does the managing news platform do this automatically?
Thanks, Chris
I think you refer to the bulk
I think you refer to the bulk feed subscription creation by keyword that Tattler offers – Managing News does not support this out of the box.