[greenstone-users] Customization problems

From Jay Clark
DateThu Jul 1 05:51:33 2010
Subject [greenstone-users] Customization problems
In-Reply-To (4C292B3A-9010300-cs-waikato-ac-nz)
Thanks Katherine,
I saw that before, but there seemed to be some other tags being added in another process that I couldn't trace. Right now I've all but forgotten about it because I decided to see what using div tags would look like - and it works marvelously!

For others on the list who may want to use this method, here's a snippet of my code from my collection's config.cfg file that may be useful.

format VList "<div class='vlist_wrapper'>
<div class='vlist_left'>{Or}{[ex.thumbicon],[ex.srcicon]}</div>
<div class='vlist_right'>
<div class='section full_width'>
<span class='row'><label>Title: </label>[srclink]{Or}{[dc.Title],[exp.Title],[ex.Title],Untitled}[/srclink]</span>
<span class='row'><label>Creator/Author: </label>{Or}{[dc.Creator],[ex.Creator],[ex.Author]}</span>
<span class='row last'><label>Contributor: </label>[dc.Contributor]</span>

I then use a custom CSS file to make this look presentable.


On 6/28/10 5:07 PM, "Katherine Don" <kjdon@cs.waikato.ac.nz> wrote:

Hi Jay

This comes from the c++ source code - in runtime-src/src/recpt/vlistbrowserclass.cpp.

In vlistbrowserclass::output_section_group, look for the bit like

if ((item == 1 && use_table) || colnumber > 0 )
textout << outconvert << "<tr valign=top> ";

lines 234/5 for me, but may differ depending on your version of greenstone.


Jay Clark wrote:
Customization problems Hello,
I'm trying to customize the output of a VList Browsing Classifier and I'm having some difficulty.

In the code of the web page that's output, I see this fragment of a table with line numbers added by me:

1 <div class="top" id="CL2">
2 <table id="group_top" class="v_list">
3 <tr valign=top>
4 <td valign='top'><img class="icon" src="/greenstone/web/images/imp3.gif <view-source:> " width="25" height="20" alt="View the MP3 document" title="View the MP3 document"></td> <td valign='top'><label>Title: </label><a href="/greenstone/collect/jaystest/index/assoc/HASH4d91.dir/MjAxMC4wNC4xNCAtIEpheSBDbGFyayAodGVzdGluZyk=.MP3 <view-source:> ">Sample Audio File</a> <br><i>(2010.04.14 - Jay Clark (testing).MP3)</i></td>
5 </tr>

I've been able to identify in the source code where the 2nd line is generated from, and I know that the two table cells (line 4) come from the collect.cfg file for the VList format. What I can't seem to find in the source code anywhere is where the 3rd line comes from (<tr valign=top>). I want to add a class attribute to it - something like class="row" so I can apply CSS more easily.

Thanks in advance for your assistance.

Jay Clark

MAF Learning Technologies
www.maf.org <http://www.maf.org>
www.maflt.org <http://www.maflt.org>


greenstone-users mailing list

-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://list.scms.waikato.ac.nz/mailman/private/greenstone-users/attachments/20100630/c35d2c22/attachment-0001.html