Unfortunately, I think this is a serious weakness of Manakin.

It's realtively easy to change the header, the footer, and the display of 
metadata (collections, communities, items).  But if you need to change anything 
else, you're in for a world of hurt.  

The way dri2xhtml renders the interface is both complex and confusing -- not at 
all the way other interface templating systems (including others that use XSLT) 
are set-up.  

I don't mean to be too critical here -- Manakin is a *big* improvement over 
JSPUI , and it cost me precisely $0, so I'm grateful to the developers, 
regardless.  

But Jose is not the first, nor likely the last, to scratch their head at how 
dri2xhtml is set-up.  It would be great if a future version of Manakin might 
take a different approach.

--Dave

==================
David Walker
Library Web Services Manager
California State University
http://xerxes.calstate.edu
________________________________________
From: Tim Donohue [tdono...@duraspace.org]
Sent: Thursday, September 30, 2010 7:25 AM
To: Blanco, Jose
Cc: dspace-tech@lists.sourceforge.net
Subject: Re: [Dspace-tech] manikin question

Hi Jose,

Actually, that's exactly my point.  There is not a single template that
renders the entire middle of the page.  It's rendered by several
templates working together.

So, if you take a look closely, the middle part of the page is a giant
table (with class="ds-table").  If you dig into the dri2xhtml.xsl file,
you'll see it just loads several other XSLs in the /dri2xhtml/ folder.
In this case, you are looking for templates that generate the structure
of the page -- so, you'd look in /dri2xhtml/structural.xsl  (the
*-Handler.xsl files all deal more with displaying actual metadata values
from the METS files which are generated by Manakin, so you'd look there
if you wanted to customize what metadata values are being displayed on a
particular page).  In the structural.xsl file, there is one main
template that gets called for <dri:table> contents:

<xsl:template match="dri:table">

But, notice that template calls several other XSL templates in the file,
by using the <xsl:apply-templates> or <xsl:call-template> tag.  So,
depending on what you are looking to change, you may need to follow the
logic between the templates.

Sometimes the easiest way to find a very specific template is to looking
closely at the resulting XHTML that you want to change.  Especially
looking at specific @class attributes on HTML elements.  Oftentimes you
can search for those @class attribute values in the XSL templates to
find where they are being generated.  For example, in this case, you are
looking at a big HTML table with a class="ds-table".  If you search for
"ds-table" in the structural.xsl, it will jump you right to the template
that generates that content.  (In some cases that @class attribute may
exist in multiple templates, so you'd have to figure out which one you
really need to change.  But, in this example, it's only one place in the
structural.xsl file)

Hope that helps,

- Tim


On 9/30/2010 9:03 AM, Blanco, Jose wrote:
> Tim,
>
> Thanks for your reply.  I guess what I'm looking for is the xsl within the 
> dri2xhml.xsl file that handles the rendering of the page used when the user 
> confirms he wants to withdraw an item.  I see the code that displays the 
> header and the footer for that page, but I don't see the part that renders 
> the stuff in the middle.
>
> -Jose
> ________________________________________
> From: Tim Donohue [tdono...@duraspace.org]
> Sent: Wednesday, September 29, 2010 5:37 PM
> To: Blanco, Jose
> Cc: dspace-tech@lists.sourceforge.net
> Subject: Re: [Dspace-tech] manikin question
>
> Jose,
>
> I'm not sure I fully understand the question?
>
> Manakin works much differently than JSPUI -- so there is never really a
> "one template" to "one page" relationship.  XSL Templates (in a theme)
> are usually used across many different pages in the system. Also,
> obviously many templates are used to generate a single page.
>
> The template you are looking for should be either in your Theme's XSL
> file or in the main 'dri2xhml.xsl' file (which is where most of the
> default templates reside -- as this file just basically transforms DRI
> into XHTML).
>
> If you are having trouble finding the exact template, sometimes it helps
> to look at the DRI structure of that page (add ?XML to the end of the
> Manakin URL, or&XML if there's other stuff on the querystring already).
>
> You also may find it useful to use a tool like FireBug
> (http://getfirebug.com/) to analyze the structure of the generated
> XHTML, so that you can search through the templates in your Theme's XSL
> to find where that structure is generated.
>
> Hopefully that's helpful.  Let us know if any of this doesn't make sense.
>
> - Tim
>
> On 9/29/2010 3:48 PM, Blanco, Jose wrote:
>> I'm trying to get a better understanding of Manakin, and I've made a change 
>> in the aspect
>>
>> ConfirmItemForm.java
>>
>> And would like now to experiment with the theme that handles the display of 
>> DRIs coming from this aspect, but I can't find the template that is 
>> responsible for displaying the page that goes with this aspect.  By page I 
>> mean the main body, not the header and footer display.
>>
>> Thank you!
>> Jose
>>
>> ------------------------------------------------------------------------------
>> Start uncovering the many advantages of virtual appliances
>> and start using them to simplify application deployment and
>> accelerate your shift to cloud computing.
>> http://p.sf.net/sfu/novell-sfdev2dev
>> _______________________________________________
>> DSpace-tech mailing list
>> DSpace-tech@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/dspace-tech

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech
------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech

Reply via email to