Koha How-To
Why is my News feature duplicating content?
If you have been using the Koha News feature recently you may be noticing that some of your new items are duplicating themselves in some new and unexpected places. Let’s take a look at why that is happening.
As of 19.05 Koha has began the process of moving system preferences that insert HTML (exmaple: OPACNavRight) into Koha to the News tool. The News tool can be accessed by going to Tools > News (/cgi-bin/koha/tools/koha-news.pl).
Why the move? By moving the HTML to the News tool there are several benefits. First is translatability. Adding content via the news feature makes it very easy to define languages and eliminates the need for a convoluted system of CSS hiding/showing based on language.
Second is the ability to define content blocks for specific library branches. If you are a multi-branch library system you can easily define content for each of your branches. This way you can have completely separate content in the OPACNavRight for each branch. This is great if you are adding some like library hours to that area!
Bug 22318 began the process of moving HTML content into the News feature. The first system preference to disappear was OPACNavRight. If you are using Koha v19.05 or v19.11 you have probably seen the new option in News or wondered what happened to your OPACNavRight system preference.
If you are seeing duplicate entries for a single News item, like in the image shown above, it is because the display location is set to ‘All’. When ‘All’ is selected your news item will copy to:
- The OPAC main page, where News has traditionally lived.
- OPACNavRight
- Slips (You can see your content on printed slips like ISSUESLIP)
- The left side of the Staff Client main page.
To prevent your content from displaying in multiple locations you simply need to select a display location other than ‘All’. If you need content to show in two areas but not in others you will want to create multiple news items and individually define where that content will go.
As you update your Koha installation to 20.05 and onward you can expect to see many more HTML system preferences disappear in favor of the News tool. In 20.05 these have already been moved:
- OPACHeader
- OPACMainUserBlock
In subsequent releases you can also expect to see HTML system presences move as well:
With so many system preferences moving into the News tool there is no better time than now to start to familiarize yourself with the Koha News tool!
Read more by Lucas Gass