Inserer feuille css dans page xsl
leSurvivant
-
Ackson Messages postés 10 Date d'inscription Statut Membre Dernière intervention -
Ackson Messages postés 10 Date d'inscription Statut Membre Dernière intervention -
Bonjour à tous,
je souhaterai insérer une feuille de style css dans une page xsl comme cela se fait dans une page html.
Voici mon code:
<?xml version="1.0" encoding="UTF-8" ?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:msxsl="urn:schemas-microsoft-com:xslt"
xmlns:user="urn:user-namespace-here"
version="1.0">
<msxsl:script language="JScript" implements-prefix="user"><![CDATA[
function GetNextValue(value) {
return (value +1);
}
]]></msxsl:script>
<xsl:template match="GetPropertiesResponse">
<TABLE id="parameters" background="#112233" style="font-weight:bold; WIDTH: 60%; POSITION: center; TOP: 0px; " align="left" cellSpacing="0" cellPadding="5" >
<xsl:for-each select="PropertyLists">
<xsl:variable name="itemName" select="@ItemName"/>
<TR border="0">
<xsl:for-each select="./Properties">
<xsl:choose>
<xsl:when test="@Name = 'description'">
<TD border="0">
<xsl:value-of select="Value"/>
</TD>
</xsl:when>
<xsl:when test="@Name = 'euInfo'">
<TD border="0" align="left" >
<xsl:choose>
<xsl:when test="../Properties[@Name = 'euType']/Value = 'enumerated'">
<xsl:choose>
<xsl:when test="../Properties[@Name = 'accessRights']/Value = 'readable'">
<xsl:choose>
<xsl:when test="../Properties[@Name = 'dataType']/Value = '11'">
<xsl:variable name ="value" select="../Properties[@Name = 'value']/Value" />
<xsl:choose>
<xsl:when test="../Properties[@Name = 'value']/Value = 'true'">
<xsl:for-each select="./ArrayOfString/string">
<xsl:if test="position()=2">
<xsl:value-of select="."/>
</xsl:if>
</xsl:for-each>
</xsl:when>
<xsl:otherwise>
<xsl:for-each select="ArrayOfString/string">
<xsl:if test="position()=1">
<xsl:value-of select="."/>
</xsl:if>
</xsl:for-each>
</xsl:otherwise>
</xsl:choose>
</xsl:when>
<xsl:otherwise>
<xsl:for-each select="ArrayOfString/string">
<xsl:if test="../../../Properties[@Name = 'value']/Value = position()- 1">
<xsl:value-of select="."/>
</xsl:if>
</xsl:for-each>
</xsl:otherwise>
</xsl:choose>
</xsl:when>
<xsl:otherwise>
<select onchange="ItemChange(this.id)">
<xsl:attribute name="id">
<xsl:value-of select="../@ItemName"/>
</xsl:attribute>
<xsl:for-each select="ArrayOfString/string">
<option>
<xsl:attribute name="value">
<xsl:value-of select="position() - 1"/>
</xsl:attribute>
<xsl:value-of select="."/>
</option>
</xsl:for-each>
</select>
</xsl:otherwise>
</xsl:choose>
</xsl:when>
<xsl:otherwise>
<xsl:choose>
<xsl:when test = "../Properties[@Name = 'accessRights']/Value = 'readable'">
<xsl:value-of select="../Properties[@Name = 'value']/Value"/>
</xsl:when>
<xsl:otherwise>
<input style="align:center" onchange="ItemChange(this.id)">
<!-- attributes are applied to the current parent element (i.e. 'input') -->
<xsl:attribute name="value">
<xsl:value-of select="../Properties[@Name = 'value']/Value"/>
</xsl:attribute>
<xsl:attribute name="id">
<xsl:value-of select="../@ItemName" />
</xsl:attribute>
</input>
</xsl:otherwise>
</xsl:choose>
</xsl:otherwise>
</xsl:choose>
</TD>
</xsl:when>
<xsl:when test="@Name = 'engineeringUnits'">
<TD border="0">
<xsl:value-of select="Value"/>
</TD>
</xsl:when>
</xsl:choose>
</xsl:for-each>
</TR>
</xsl:for-each>
<TR >
<TD></TD>
</TR>
<TR style="color:#005588">
<TD align="right" colspan="3" >
<Input type ="button" id="buttonApply" value ="Appliquer" onclick="WriteItems()" disabled="true" style="align:center; font-weight:bold; color:blue;" />
<Input type ="button" id="buttonCancel" value ="Annuler" onclick="history.back()" style="align:center; font-weight:bold; color:blue;" />
</TD>
</TR>
</TABLE>
</xsl:template>
</xsl:stylesheet>
J'ai déjà essayé d'ajouter des choses trouvées sur le net mais sans résultats jusqu'à présent. C'est ainsi que je me tourne une nouvelle fois vers vous.
Pourriez vous m'aider?
je souhaterai insérer une feuille de style css dans une page xsl comme cela se fait dans une page html.
Voici mon code:
<?xml version="1.0" encoding="UTF-8" ?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:msxsl="urn:schemas-microsoft-com:xslt"
xmlns:user="urn:user-namespace-here"
version="1.0">
<msxsl:script language="JScript" implements-prefix="user"><![CDATA[
function GetNextValue(value) {
return (value +1);
}
]]></msxsl:script>
<xsl:template match="GetPropertiesResponse">
<TABLE id="parameters" background="#112233" style="font-weight:bold; WIDTH: 60%; POSITION: center; TOP: 0px; " align="left" cellSpacing="0" cellPadding="5" >
<xsl:for-each select="PropertyLists">
<xsl:variable name="itemName" select="@ItemName"/>
<TR border="0">
<xsl:for-each select="./Properties">
<xsl:choose>
<xsl:when test="@Name = 'description'">
<TD border="0">
<xsl:value-of select="Value"/>
</TD>
</xsl:when>
<xsl:when test="@Name = 'euInfo'">
<TD border="0" align="left" >
<xsl:choose>
<xsl:when test="../Properties[@Name = 'euType']/Value = 'enumerated'">
<xsl:choose>
<xsl:when test="../Properties[@Name = 'accessRights']/Value = 'readable'">
<xsl:choose>
<xsl:when test="../Properties[@Name = 'dataType']/Value = '11'">
<xsl:variable name ="value" select="../Properties[@Name = 'value']/Value" />
<xsl:choose>
<xsl:when test="../Properties[@Name = 'value']/Value = 'true'">
<xsl:for-each select="./ArrayOfString/string">
<xsl:if test="position()=2">
<xsl:value-of select="."/>
</xsl:if>
</xsl:for-each>
</xsl:when>
<xsl:otherwise>
<xsl:for-each select="ArrayOfString/string">
<xsl:if test="position()=1">
<xsl:value-of select="."/>
</xsl:if>
</xsl:for-each>
</xsl:otherwise>
</xsl:choose>
</xsl:when>
<xsl:otherwise>
<xsl:for-each select="ArrayOfString/string">
<xsl:if test="../../../Properties[@Name = 'value']/Value = position()- 1">
<xsl:value-of select="."/>
</xsl:if>
</xsl:for-each>
</xsl:otherwise>
</xsl:choose>
</xsl:when>
<xsl:otherwise>
<select onchange="ItemChange(this.id)">
<xsl:attribute name="id">
<xsl:value-of select="../@ItemName"/>
</xsl:attribute>
<xsl:for-each select="ArrayOfString/string">
<option>
<xsl:attribute name="value">
<xsl:value-of select="position() - 1"/>
</xsl:attribute>
<xsl:value-of select="."/>
</option>
</xsl:for-each>
</select>
</xsl:otherwise>
</xsl:choose>
</xsl:when>
<xsl:otherwise>
<xsl:choose>
<xsl:when test = "../Properties[@Name = 'accessRights']/Value = 'readable'">
<xsl:value-of select="../Properties[@Name = 'value']/Value"/>
</xsl:when>
<xsl:otherwise>
<input style="align:center" onchange="ItemChange(this.id)">
<!-- attributes are applied to the current parent element (i.e. 'input') -->
<xsl:attribute name="value">
<xsl:value-of select="../Properties[@Name = 'value']/Value"/>
</xsl:attribute>
<xsl:attribute name="id">
<xsl:value-of select="../@ItemName" />
</xsl:attribute>
</input>
</xsl:otherwise>
</xsl:choose>
</xsl:otherwise>
</xsl:choose>
</TD>
</xsl:when>
<xsl:when test="@Name = 'engineeringUnits'">
<TD border="0">
<xsl:value-of select="Value"/>
</TD>
</xsl:when>
</xsl:choose>
</xsl:for-each>
</TR>
</xsl:for-each>
<TR >
<TD></TD>
</TR>
<TR style="color:#005588">
<TD align="right" colspan="3" >
<Input type ="button" id="buttonApply" value ="Appliquer" onclick="WriteItems()" disabled="true" style="align:center; font-weight:bold; color:blue;" />
<Input type ="button" id="buttonCancel" value ="Annuler" onclick="history.back()" style="align:center; font-weight:bold; color:blue;" />
</TD>
</TR>
</TABLE>
</xsl:template>
</xsl:stylesheet>
J'ai déjà essayé d'ajouter des choses trouvées sur le net mais sans résultats jusqu'à présent. C'est ainsi que je me tourne une nouvelle fois vers vous.
Pourriez vous m'aider?
A voir également:
- Inserer feuille css dans page xsl
- Insérer vidéo dans powerpoint - Guide
- Supprimer une page dans word - Guide
- Insérer signature word - Guide
- Insérer liste déroulante excel - Guide
- Insérer sommaire word - Guide