Looking for a theme that displays Details

gjschaller
gjschaller's picture

Joined: 2004-04-19
Posts: 44
Posted: Fri, 2007-04-27 13:38

I have a website that uses Gallery2, and it's been very good to me so far. :-)

Out of the thousands of pics we host, some of them are Awards for folks within our community / game, given out on a monthy basis ("Player of the month," etc.). When we were using Gallery 1, the Captions of the images worked well to show the text for each winner - when I migrated them to G2, the text was truncated, unless I migrated the captions to the "Details" field.

G1: http://www.knightrealms.com/Components/gallery/Awards-2006-12

G2: http://www.knightrealms.com/Components/gallery2/main.php?g2_itemId=9993

(Both galleries were/are actually embedded in Joomla, but the above links are to the direct Galleries for simplicity.)

I'm looking for a theme that will display the Details field in the next column over, to the right of the Picture and Caption / Summary, or advice on how to edit an existing theme to do this. Can anyone point me in the right direction?

Thank you!

--
Geoffrey J. Schaller
http://gallery.knightrealms.com

 
gjschaller
gjschaller's picture

Joined: 2004-04-19
Posts: 44
Posted: Fri, 2007-04-27 21:56

Hopefully a bit more specifics can help...

I'd like to modify the Classic theme (which is the one in use now) so that there is only 1 column, and that the descriptions appear to the right of each photo. I have the /local/ folder set up with the album.tpl in it, but I am unsure how to edit the code to make it do what I want (My PHP coding skills are not very strong... they're actually almost non-existant. -_- )

Thank you for your help!

--
Geoffrey J. Schaller
http://gallery.knightrealms.com

 
drewactual

Joined: 2007-04-23
Posts: 21
Posted: Fri, 2007-04-27 23:08

that theme uses tables....tables are hard to manipulate in my experience, try using matrix which is css based and easier to do what you want...BUUUTTT....

try this little number:

Open ...templates/classic/theme.tpl, then insert link to css's in <head>:

<link rel="stylesheet" type="text/css" href="http://www.knightrealms.com/Components/smf/Themes/Knight Realms Embedded/style.css?rc2" />
<link rel="stylesheet" type="text/css" href="http://www.knightrealms.com/Components/smf/Themes/default/print.css?rc2" media="print" />

then on line 22 of the theme.tpl, or right after the <body> declaration if yours is not the same as mine insert:

<table class="contentpaneopen">

then nearing the end of the tpl (my unaltered version has it at line 62) but right after the php mumbo jumbo about include appropriate content, and before <div id="gsfooter"> insert:

</table>

....if it doesn't work just take it out!!!! Man, you should use stylesheets to control your rendering rather than tables though, it makes life soooo much easier! :-)

 
lvthunder

Joined: 2003-09-12
Posts: 804
Posted: Sat, 2007-04-28 00:57

Those tpl files are not PHP files. They are Smarty template files which is basiclly just HTML with tags that do things like loops and display variables. They are really easy to edit if you know HTML. If you turn on debug mode you can see in a popup all the smarty variables that you can use. Look at the variables to see which field you want to do.

 
gjschaller
gjschaller's picture

Joined: 2004-04-19
Posts: 44
Posted: Sun, 2007-04-29 23:52

I'm going to go with modifying the "classic" theme, since it's closest to what I already want.

I took a poke at editing the Album's Template file, and added a section:

{if !empty($child.summary)}
<p class="giDescription">
{$child.summary|entitytruncate:256|markup}
</p>
{/if}

{if !empty($child.descripton)}
<p class="giDescription">
{$child.description|markup}
</p>
{/if}

I'm thinking that SHOULD add the Details right below the Summary on the Album View page, but it did not seem to work. Can someone direct me what I did wrong?

--
Geoffrey J. Schaller
http://gallery.knightrealms.com

 
lvthunder

Joined: 2003-09-12
Posts: 804
Posted: Mon, 2007-04-30 02:09

If you take out entitytruncate:256 that might do what you want. That tells gallery to only take the first 256 characters of the summery.

 
gjschaller
gjschaller's picture

Joined: 2004-04-19
Posts: 44
Posted: Mon, 2007-04-30 13:41

I'd like to display both the Summary and the Details, not just one or the other.

--
Geoffrey J. Schaller
http://gallery.knightrealms.com

 
gjschaller
gjschaller's picture

Joined: 2004-04-19
Posts: 44
Posted: Fri, 2007-05-04 14:19

Hrm - I may be running into a larger issue.

It seems ANY changes I make to the Classic theme don't stick - I also tried removing the Gallery banner (since it's embedded in Joomla), and this failed, too.

I have the modified files in gallery2/themes/classic/templates/local/ but they don't seem to be working - I'm not seeing any changes I make on the albums that use Classic.

Any ideas what's going wrong?

--
Geoffrey J. Schaller
http://gallery.knightrealms.com

 
lvthunder

Joined: 2003-09-12
Posts: 804
Posted: Fri, 2007-05-04 14:32

It is either your local browser cache or G2's template cache. I can't remember off the top of my head if it's shift or control to have the browser not use the local cache and go load the site again. Try that first. Then if that doesn't work go into Site Admin under Maintenance and click Clear (or is it delete) Template Cache.

 
drewactual

Joined: 2007-04-23
Posts: 21
Posted: Fri, 2007-05-04 17:11

It is hold the shift key while hitting refresh on your browser....

 
gjschaller
gjschaller's picture

Joined: 2004-04-19
Posts: 44
Posted: Fri, 2007-05-04 17:20

Thank you - I got the theme.tpl to work, so the banner is now gone, but the Details are still not appearing.

--
Geoffrey J. Schaller
http://gallery.knightrealms.com