source: trunk/platforms_db.xsl @ 37

Last change on this file since 37 was 33, checked in by pinsard, 17 years ago

add Id in many headers; replace bibrefnemo.xml by biblio.xml

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