On Wed, Sep 4, 2013 at 3:47 PM, Thomas Ronayne <[email protected]> wrote:
> I have to tell folks how to enter multiple lines in a spread sheet (they're
> mostly going to be using Excel, a few will be using OpenOffice Calc). That's
> the infrastructure and nothing I can do about that (when people volunteer to
> do work at home, you don't want to make it hard for them, you know?). I know
> that, on a Linux/Unix box, you can simply do Ctrl-V followed by Ctrl-L and
> there you go but what do they do in winders? Is <br> an actual pattern they
> can type that will actually do something or would I need to pass the CSV
> though sed to substitute that pattern with an actual Ctrl-L (not too clear
> on this point)? Gotta keep it as simple as possible.

No, you can insert actual linebreaks in a Calc cell by pressing
Ctrl-Enter. I'm not sure about Excel, but it ill be similar (try
shift, alt, ctrl). Calc will do the right thing during CSV export by
wrapping the cell value in quotes, like in the example I posted. I
guess Excel would do the same.

When I was talking about inserting e.g. <br> tags, I meant literally
<br>, a tag that you can process in XSL. It might be possible to do
without it (using actual line breaks), but keep it in mind as an
alternative.

> If fiddling with XSL is needed, where do I do the fiddling? One of these:
>
> cd /opt/dspace
> find . -type f -name '*xsl*' | xargs fgrep -l 'disable-output-escaping'
> ./webapps/xmlui/themes/dri2xhtml-alt/core/page-structure.xsl
> ./webapps/xmlui/themes/dri2xhtml/structural.xsl
> ./webapps/xmlui/themes/Mirage/lib/xsl/core/page-structure.xsl
>
> I'm guessing structural.xsl might be a candidate (probably not though),
> where
>
> <!-- Head metadata in item pages -->
>             <xsl:if
> test="/dri:document/dri:meta/dri:pageMeta/dri:metadata[@element='xhtml_head_item']">
>                 <xsl:value-of
> select="/dri:document/dri:meta/dri:pageMeta/dri:metadata[@element='xhtml_head_item']"
>                               disable-output-escaping="yes"/>
>             </xsl:if>
>
> and change that to "no" or "false" (and do I have to rebuild something after
> editing)?
>
> Sorry, just a little confused about all this.

Keep in mid that XSL requires a different mode of thinking. It's a
templating language (declarative, think functional programming or
regexes), not a programming language (imperative). The unit you work
with are templates. Forget about xsl files, files are good only to
group templates with different priorities (there are also explicit
ways of specifying priority), otherwise they're "aesthetics" like
whitespace. So don't ask which file does what, ask which template
matches the specific part of the input XML.

The metadata values are inserted by the itemSummaryView-DIM template
in the item summary view and by itemDetailView-DIM in the item full
metadata view. These templates and templates they're calling happen to
be grouped nicely in this xsl file:

https://github.com/DSpace/DSpace/blob/dspace-3.2/dspace-xmlui/src/main/webapp/themes/Mirage/lib/xsl/aspect/artifactbrowser/item-view.xsl

For example, look at line 342 which copies actual value of a metadata
field (full metadata view). You'd have to do any processing there.


Regards,
~~helix84

Compulsory reading: DSpace Mailing List Etiquette
https://wiki.duraspace.org/display/DSPACE/Mailing+List+Etiquette

------------------------------------------------------------------------------
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
_______________________________________________
Dspace-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-general

Reply via email to