source: trunk/compilers_db.xsl @ 76

Last change on this file since 76 was 55, checked in by pinsard, 16 years ago

migration to docbook5 except biblio.xml; improvement of makefile

  • Property svn:keywords set to Id
File size: 2.8 KB
Line 
1<?xml version="1.0" encoding="iso-8859-1"?>
2<xsl:stylesheet
3version="1.0"
4xmlns:html="http://www.w3.org/1999/xhtml"
5xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
6
7<!--
8module :
9creation des élements compilers de formulaire
10
11update :
12$Id$
13fplod 2008-04-29T09:03:58Z aedon.locean-ipsl.upmc.fr (Darwin)
14chgt for dbk5
15fplod 2007-05-18T10:25:06Z aedon.locean-ipsl.upmc.fr (Darwin)
16correction pour cause de dysfonctionnement sous firefox (mais ok sous safari) :
17Le 1er choix est modifi<E9> si on clique sur un des choix suivant
18fplod 2007-04-26T10:13:37Z aedon.locean-ipsl.upmc.fr (Darwin)
19creation
20-->
21
22<xsl:template name="compilers">
23 <xsl:param name="user"/>
24 <xsl:param name="author_id"/>
25 <xsl:param name="visu_modif"/>
26
27  <xsl:text>&#xA;</xsl:text>
28  <xsl:element name="html:fieldset">
29   <xsl:attribute name="xml:id">compilers_<xsl:value-of select="$author_id"/></xsl:attribute>
30   <xsl:text>&#xA;</xsl:text>
31   <xsl:text>&#xA;</xsl:text>
32   <xsl:element name="html:legend">
33    Used compilers
34   </xsl:element>
35   <xsl:text>&#xA;</xsl:text>
36   <xsl:text>&#xA;</xsl:text>
37   <!-- ne plait pas à firefox ++
38   <xsl:element name="html:label">
39   -->
40    <xsl:for-each select="$user/compilers/compiler">
41     <xsl:sort order="ascending" data-type="text" select="@code"/>
42     <xsl:text>&#xA;</xsl:text>
43     <xsl:comment><xsl:value-of select="./value"/></xsl:comment>
44     <xsl:choose>
45      <xsl:when test="@code != 'zzz_other'">
46      <xsl:text>&#xA;</xsl:text>
47       <xsl:element name="html:input">
48        <xsl:attribute name="name">
49         <xsl:value-of select="name()"/><xsl:text>_</xsl:text><xsl:value-of select="@code"/>
50        </xsl:attribute>
51        <xsl:attribute name="type">checkbox</xsl:attribute>
52        <xsl:attribute name="value"><xsl:value-of select="./name"/></xsl:attribute>
53        <xsl:if test="$visu_modif= 'visu'">
54         <xsl:attribute name="readonly">1</xsl:attribute>
55        </xsl:if>
56        <xsl:if test="./value = 'yes'">
57         <xsl:attribute name="checked">1</xsl:attribute>
58        </xsl:if>
59        <xsl:value-of select="./name"/>
60       </xsl:element>
61      </xsl:when>
62      <xsl:when  test="@code = 'zzz_other'">
63       <xsl:text>&#xA;</xsl:text>
64       <xsl:element name="html:label">
65        Other :
66        <xsl:text>&#xA;</xsl:text>
67        <xsl:element name="html:input">
68         <xsl:attribute name="name">
69          <xsl:value-of select="name()"/><xsl:text>_</xsl:text><xsl:value-of select="@code"/>
70         </xsl:attribute>
71         <xsl:attribute name="type">text</xsl:attribute>
72         <xsl:attribute name="value"><xsl:value-of select="./value"/></xsl:attribute>
73        </xsl:element>
74       </xsl:element>
75      </xsl:when>
76     </xsl:choose>
77    </xsl:for-each>
78   <!-- ne plait pas à firefox ++
79   </xsl:element>
80   -->
81   <xsl:text>&#xA;</xsl:text>
82  </xsl:element>
83  <xsl:text>&#xA;</xsl:text>
84</xsl:template>
85</xsl:stylesheet>
Note: See TracBrowser for help on using the repository browser.