This Views plugin makes unformatted styles, field row styles and other output more readily configurable without needing to override template files. Instead of overriding row style templates for views where you want to specify different HTML elements (tags) and class attributes, you can specify these inside the Views UI and avoid overriding templates for each view.

Example

Semantic Views is best understood when you compare the HTML of Views 2 output.

Before

<div class="views-row views-row-1 views-row-odd views-row-first">
<div class="views-field-title">
<span class="field-content"><a href="/node/1">Augue Magna Cui Conventio Valetudo</a></span>
</div>
<div class="views-field-type">
<span class="field-content">Story</span>
</div>
<div class="views-field-teaser">
<div class="field-content">
<p>
node (story) - Abigo bene feugiat loquor neo lenis qui imputo. Suscipere molior obruo typicus jus euismod ille illum meus. Acsi populus pecus populus lobortis metuo voco. Aptent plaga incassum. Iriure cui cui commoveo eum hos dolor ex consectetuer. Typicus eros vulputate defui comis nobis humo. Ulciscor abigo occuro. Sagaciter tego dolore. Voco iusto jus. Abdo dolor verto gilvus mos iaceo vel loquor.
</p>
</div>
</div>
<div class="views-field-delete-node">
<label class="views-label-delete-node">Delete link:</label> <span class="field-content"><a href="/node/1/delete&amp;destination=semantic-views-demo">delete</a></span>
</div>
<div class="views-field-edit-node">
<label class="views-label-edit-node">Edit link:</label> <span class="field-content"><a href="/node/1/edit&amp;destination=semantic-views-demo">edit</a></span>
</div>
</div>

After

<div class="first odd">
<h2 class="title"><a href="/node/1">Augue Magna Cui Conventio Valetudo</a></h2>
<div class="node-type">
Story
</div>
<p>
node (story) - Abigo bene feugiat loquor neo lenis qui imputo. Suscipere molior obruo typicus jus euismod ille illum meus. Acsi populus pecus populus lobortis metuo voco. Aptent plaga incassum. Iriure cui cui commoveo eum hos dolor ex consectetuer. Typicus eros vulputate defui comis nobis humo. Ulciscor abigo occuro. Sagaciter tego dolore. Voco iusto jus. Abdo dolor verto gilvus mos iaceo vel loquor.
</p>
<div>
<label>Delete link:</label> <a href="/node/1/delete&amp;destination=semantic-views-demo%2Funformatted-semantic">delete</a>
</div>
<div>
<label>Edit link:</label> <a href="/node/1/edit&amp;destination=semantic-views-demo%2Funformatted-semantic">edit</a>
</div>
</div>

Usage

To use this module, select the Semantic Views style and row style for your view. HTML elements and class attributes are revealed in the settings for those two plugins.

Jeff Burnz has produced a brief video that demonstrates the usage and output of this module.

Project Information

Downloads