[SOLVED] [PATCH] [CUSTOMIZATION] Adding item descriptions to your matrix album

Cry Regarder

Joined: 2010-12-07
Posts: 9
Posted: Mon, 2012-11-26 17:51

NOTE: I AM NOT NECESSARILY SUBMITTING THIS FOR ACTUAL CHANGES TO THE MATRIX THEME, BUT INSTEAD MAKE IT AVAILABLE IF FOLKS WANT TO CUSTOMIZE THEIR INSTALLATION.

You've filled in a nice description on your photo and you'd like it to appear on your album views because you know that no-one actually clicks on the photos. This diff to themes/matrix/templates/album.tpl does this change.


--- album.tpl.orig    2007-04-25 15:36:13.000000000 -0700
+++ album.tpl    2012-11-26 09:44:57.649335005 -0800
@@ -27,10 +27,15 @@
             <tr>
               <td>
                 {if !empty($theme.item.title)}
-                <h2> {$theme.item.title|markup} </h2>
+                <h2>{$theme.item.title|markup} </h2>
                 {/if}
-                {if !empty($theme.item.description)}
+                {if !empty($theme.item.summary)}
                 <p class="giDescription">
+                  {$theme.item.summary|markup}
+                </p>
+                {/if}
+                {if !empty($theme.item.description)}
+                <p class="giDescription"> DESCRIPTION
                   {$theme.item.description|markup}
                 </p>
                 {/if}
@@ -135,6 +140,12 @@
                 </p>
                 {/if}
 
+                {if !empty($child.description)}
+                <p class="giDescription"> 
+                  {$child.description|markup}
+                </p>
+                {/if}
+
                 {if ($child.canContainChildren && $theme.params.showAlbumOwner) ||
                     (!$child.canContainChildren && $theme.params.showImageOwner)}
                 {assign var="showOwner" value=true}

Enjoy!

Cry

 
Cry Regarder

Joined: 2010-12-07
Posts: 9
Posted: Mon, 2012-11-26 17:57

Oops! Remove the all-caps "DESCRIPTION" text from the patch unless you reqlly want the word "DESCRIPTION" prepended to your actual description.