|
Benny |
.fedelissimo.
Registered: May 2003
Posts: 48 (0.01 al dì)
Location: Milano
Corso: Informatica
Anno: 2
Time Online: 12:49:02: [...]
Status: Offline
Edit | Report | IP: Logged |
l'ordinamento in xsl...
ciao, sono ore che sbatto la testa con il problema dell'ordinamento dei ristoranti per voto medio, ovviamente so che si sarebbe potuto fare nel db, o in php dopo aver preso i dati...ma mi pongo il problema sul farlo con xsl, ci sarebbe il costrutto xsl:sort ma ci fosse stata una volta che avesse dato risultati in una qualche brutta maniera:
vi mostro la struttura dell'xsl...
<xsl:stylesheet version="1.0" xmlnssl="http://www.w3.org/1999/XSL/Transform"
xmlns="http://www.w3.org/1999/xhtml">
<xsl:output method="xml" indent="yes" omit-xml-declaration="yes" media-type="application/xhtml+xml"
encoding="iso-8859-1" doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/>
<xsl:template match="Elenco_Ristoranti">
<html>
<head><title>ciao</title>
</head>
<body>
<xsl:apply-templates/>
</body>
</html>
</xsl:template>
<xsl:template match="Record">
<xsl:apply-templates >
<xsl:sort select="nome"/>
</xsl:apply-templates>
</xsl:template>
<xsl:template match="nome">
<br/>
<b><xsl:apply-templates/></b>
</xsl:template>
</xsl:stylesheet>
se mi potete dare una zampa, senno ci rinuncio e scendo sulla catena o al db o in php...grazie
__________________
Se non credi in te stesso, chi ci crederà?
|