Skip to content
Victor Jonsson edited this page Apr 14, 2014 · 12 revisions

The "Streamer" is what we call a line of text or an image that's positioned above the article image (bullet point 4 in the interface walkthrough).

Adding your own background colors to text streamers

Since version 2.7 you can define your own background colors on the settings page (open up wp-admin and navigate to Arlima -> Settings).

Using filter arlima_streamer_colors

By default you get a wide variety of background colors to choose from. You can how ever add your own colors by using the filter "arlima_streamer_colors" in file functions.php located in the theme directory. Your code might look something like:

<?php
function my_streamer_colors($colors) {
    $colors[] = '007fc2'; // red
    $colors[] = 'b22e2a'; // red
    $colors[] = 'E2E2E2'; // gray
    $colors[] = '894b94'; // purple
    return $colors;
}
add_filter('arlima_streamer_colors', 'my_streamer_colors');

Adding your own streamer classes

As of version 2.7.21 you can add your own streamer classes that the editor can choose from when creating an article. Let's say that you want a special looking streamer for all your sport related articles. First you add the filter:

<?php
function my_arlima_streamers($classes) {
  $classes['sport'] = 'Sport article'; // key being the class name and value being the label in arlima
  return $classes;
}
add_filter('arlima_streamer_classes', 'my_arlima_streamers');

The class name will be prefixed with text-, the CSS for your sport streamers could look something like:

.streamer.text-sport {
    background: #cbeaff;
    border: #b6d2e1 solid 4px;
    color: #4d6983;
    padding: 12px;
}

Here you can read more about how to customize the CSS used in Arlima

Adding your own streamer images

You can use the filter "arlima_streamer_images" if you want to add your own streamer images. The code might look something like:

<?php
function my_streamer_images($streamers) {
    $theme_url = get_stylesheet_directory_uri();
    $streamers[] = $theme_url . '/images/my-cool-streamer.png';
    $streamers[] = $theme_url . '/images/another-cool-streamer.png';
    return $streamers;
}
add_filter('arlima_streamer_images', 'my_streamer_images');

This Wordpress plugin was created by Swedish newspaper Västerbottens-Kuriren to give its editorial staff an easy to use tool for customizing the front pages of their online magazines.

Installing Arlima

  1. Download the latest release from github and unzip the folder in your plugin directory.
  2. Open up wp-admin and activate the plugin.
  3. Go to "Article lists" -> "Edit lists" in wp-admin and create your first article list.
  4. Open up a page (or create it) in wp-admin. Down to the right you will see a meta box labeled "Arlima" where you choose the list that you created on step 2.
  5. Go to "Article lists" -> "Manage lists" and start stuffing your article list with interesting content.

Top links

Clone this wiki locally