Project

General

Profile

1

    
2
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
3
                xmlns:dri="http://www.driver-repository.eu/namespace/dri"
4
                xmlns:oaf="http://namespace.openaire.eu/oaf"
5
                xmlns:dc="http://purl.org/dc/elements/1.1/">
6

    
7
    <!-- Turn off auto-insertion of <?xml> tag and set indenting on -->
8
    <xsl:output method="html" encoding="utf-8" omit-xml-declaration="yes" media-type="text/html" />
9

    
10
    <!-- strip whitespace from whitespace-only nodes -->
11
    <xsl:strip-space elements="*"/>
12

    
13
    <xsl:template match = "/">
14
        <xsl:apply-templates select="//oaf:result"/>
15
    </xsl:template>
16

    
17
    <!-- Title, Authors, Publication Year, DOI, Download From, Publication Type, Journal, Funder, Project Name (GA Number), Access -->
18

    
19
    <xsl:template match="oaf:result">
20
        <tr>
21
            <!-- Type -->
22
            <td>
23
                <xsl:value-of select="resulttype/@classname"/>
24
            </td>
25

    
26
            <!-- Title -->
27
            <td>
28
                <xsl:value-of select="title"/>
29
            </td>
30

    
31
            <!-- Authors -->
32
            <td>
33
                <xsl:for-each select="rels/rel/to[@class='hasAuthor']">
34
                    <xsl:sort select="field[@name='ranking']/@value"/>
35
                    <xsl:value-of select="../fullname"/>
36
                    <xsl:if test="not(position()=last())">
37
                        <xsl:text>;</xsl:text>
38
                    </xsl:if>
39
                </xsl:for-each>
40
            </td>
41

    
42
            <!-- Publication Year -->
43
            <td>
44
                <xsl:value-of select="dateofacceptance"/>
45
            </td>
46

    
47
            <!-- DOI -->
48
            <td>
49
                <xsl:apply-templates select="pid"/>
50
            </td>
51

    
52
            <!-- Download from -->
53
            <td>
54
                <a target="_blank">
55
                <xsl:attribute name="href">
56
                    <xsl:value-of select="children/instance[1]/webresource[1]"/>
57
                </xsl:attribute>
58
                </a>
59
            </td>
60

    
61
            <!-- Publication Type -->
62
            <td>
63
                <xsl:value-of select="children/instance[1]/instancetype/@classname"/>
64
            </td>
65

    
66
            <!-- Journal -->
67
            <td>
68
                <xsl:value-of select="replace(source, '[&#x007F;-&#x009F;]', ' ')"/>
69
            </td>
70

    
71
            <!-- Funder|Project Name (GA Number) -->
72
            <td>
73
                <xsl:for-each select="rels/rel/to[@class='isProducedBy']">
74
                    <xsl:value-of select="../funding/funder/@shortname"/>
75
                    <xsl:text>|</xsl:text>
76
                    <xsl:choose>
77
                        <xsl:when test="../acronym">
78
                            <xsl:value-of select="../acronym"/>
79
                        </xsl:when>
80
                        <xsl:otherwise>
81
                            <xsl:text>"</xsl:text>
82
                            <xsl:value-of select="../title"/>
83
                            <xsl:text>"</xsl:text>
84
                        </xsl:otherwise>
85
                    </xsl:choose>
86
                    <xsl:text>(</xsl:text>
87
                    <xsl:value-of select="../code"/>
88
                    <xsl:text>)</xsl:text>
89
                    <xsl:if test="not(position()=last())">
90
                        <xsl:text>;</xsl:text>
91
                    </xsl:if>
92
                </xsl:for-each>
93
            </td>
94

    
95
            <!-- Access -->
96
            <td>
97
                <xsl:value-of select="bestaccessright/@classname"/>
98
            </td>
99
        </tr>
100
    </xsl:template>
101

    
102
    <xsl:template match="pid[@classid='doi']">
103
        <xsl:value-of select="."/>
104
    </xsl:template>
105

    
106
</xsl:stylesheet>
(29-29/58)