105 |
jpm |
1 |
<?xml version="1.0" encoding="UTF-8"?>
|
|
|
2 |
<!-- Note : enregistrer ce fichier avec l'encodage UTF-8 cookie. -->
|
27 |
jpm |
3 |
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
|
105 |
jpm |
4 |
<xsl:output method="text" version="1.0" encoding="UTF-8" indent="yes"/>
|
|
|
5 |
|
|
|
6 |
<xsl:template match="/groupemacroelement"><?
|
27 |
jpm |
7 |
class <xsl:value-of select="@classe"/> extends groupeMacroElement {
|
|
|
8 |
|
|
|
9 |
function __construct($aConn)
|
|
|
10 |
{
|
|
|
11 |
parent::__construct($aConn);
|
|
|
12 |
}
|
|
|
13 |
|
|
|
14 |
function construire()
|
|
|
15 |
{
|
|
|
16 |
$this->dblock= new blockdedonnees('<xsl:value-of select="@nom"/>');
|
|
|
17 |
<xsl:apply-templates select="parametres" />
|
|
|
18 |
|
|
|
19 |
$this->buildContext();
|
|
|
20 |
$this->addMacroElement();
|
|
|
21 |
}
|
|
|
22 |
|
|
|
23 |
function buildContext()
|
|
|
24 |
{
|
|
|
25 |
|
|
|
26 |
}
|
|
|
27 |
|
|
|
28 |
function addMacroElement()
|
|
|
29 |
{
|
|
|
30 |
<xsl:apply-templates select="macroelement" />
|
|
|
31 |
}
|
|
|
32 |
|
|
|
33 |
}
|
|
|
34 |
?>
|
105 |
jpm |
35 |
</xsl:template>
|
|
|
36 |
|
|
|
37 |
<xsl:template match="parametres" >
|
|
|
38 |
<xsl:apply-templates select="parametre" />
|
|
|
39 |
</xsl:template>
|
|
|
40 |
|
|
|
41 |
<xsl:template match="parametre" >
|
|
|
42 |
if (array_key_exists('<xsl:value-of select="@nom"/>',$_REQUEST)) { $this->dblock->ajouterDonnee('<xsl:value-of select="@nom"/>',$_REQUEST['<xsl:value-of select="@nom"/>']); }
|
|
|
43 |
</xsl:template>
|
|
|
44 |
|
|
|
45 |
<xsl:template match="macroelement" >
|
|
|
46 |
/*balise:<xsl:value-of select="@nom"/>*/
|
|
|
47 |
$aMacroElement = $this->macroElementFactory('<xsl:value-of select="@nom"/>',$this->dblock);
|
|
|
48 |
$aMacroElement->construire();
|
|
|
49 |
</xsl:template>
|
|
|
50 |
|
|
|
51 |
</xsl:stylesheet>
|