Text Size
HomeFeaturesCustom Views

Custom Views

The Dominion theme includes 2 custom "Views" to render content on the homepage. Below is a description of the views and how to install and customize them.

A txt file is available with the theme of each custom view, so you can easily import them using the Views import function.

  • showcase_view.txt
  • tabs_view.txt

Showcase View

The Homepage "Showcase Rotator" is a custom views to pull specific content to the SHOWCASE ROTATOR. This view pulls the lastest articles from the "Rotator" term in the taxonomy. The view can be customized as needed to pull from different taxonomies.

If you are using the RocketLauncher installation, all of the Views, taxonomy and blocks are already setup for you.

Setting Up Homepage Showcase Rotator

(make sure the VIEWS module is installed and enabled)
  • Create a vocabulary in Taxonomy
  • Add the term Rotator to an existing vocabulary.
  • Go to the Views admin and import the "View" included with this theme (showcase_view.txt). This will create a new view to gather the info from the articles you create.
  • In the block admin, create a new block and put the following code in the body (make sure input type is php code):
    
    $thisPage = path_to_theme() . '/templates/rotator.php';
    include ($thisPage); 
    
    
  • Move the block to the Showcase region and save.
  • Now, simply create articles and add them to the vocabulary term you created above.
  • Using the File Upload function when creating an article, upload the large image you want on the homepage.

This custom view will pull the latest articles to the homepage and put them in the JQuery rotator on the homepage.



Tabbed Content View

The Tabbed Content view is a simple way to pull specific content to the homepage and place it in a stylish JQuery tabbed area. Any article assigned to the associated taxonomy term will be shown as a tab in the tabbed area.

The setup for this custom view is similar to the Showcase view. Create the taxonomy term "Tabs", then simply import the included view import file (tabs_view.txt) which will create the view. Create a new block and add the following code to the block body:


$thisPage = path_to_theme() . '/templates/tabs.php';
include ($thisPage); 

Then move the block to the MainTop region and add articles for the taxonomy term "Tabs".