Show the 10 most recent news items, not the 20 most recent.

Start showing the 10 most recent items from "FreeBSD in the Press" as well.
This commit is contained in:
Nik Clayton 2001-08-10 10:36:18 +00:00
parent 034cbbf9c7
commit 88c6230a68
Notes: svn2git 2020-12-08 03:00:23 +00:00
svn path=/www/; revision=10290

View file

@ -1,4 +1,4 @@
<!-- $FreeBSD: www/en/index.xsl,v 1.3 2001/08/07 21:30:28 jim Exp $ -->
<!-- $FreeBSD: www/en/index.xsl,v 1.4 2001/08/08 10:07:20 nik Exp $ -->
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
@ -6,7 +6,7 @@
<xsl:import href="news/includes.xsl"/>
<xsl:variable name="base" select="'.'"/>
<xsl:variable name="date" select="'$FreeBSD: www/en/index.xsl,v 1.3 2001/08/07 21:30:28 jim Exp $'"/>
<xsl:variable name="date" select="'$FreeBSD: www/en/index.xsl,v 1.4 2001/08/08 10:07:20 nik Exp $'"/>
<xsl:variable name="title" select="'The FreeBSD Project'"/>
<xsl:output type="html" encoding="iso-8859-1"
@ -337,26 +337,42 @@
&#183; <a href="{$u.rel.notes}">Release Notes</a><br/>
&#183; <a href="{$u.rel.errata}">Errata</a></small></p>
<p><font size="+1" color="#990000"><b>Headlines</b></font><br/>
<font size="-1">
<!-- Code to pull in the most recent four news
items -->
<xsl:for-each select="descendant::event[position() &lt;= 20]">
&#183; <a>
<xsl:attribute name="href">
news/newsflash.html#<xsl:call-template name="generate-event-anchor"/>
</xsl:attribute>
<xsl:choose>
<xsl:when test="count(child::title)">
<xsl:value-of select="title"/><br/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="p"/><br/>
</xsl:otherwise>
</xsl:choose>
</a>
</xsl:for-each>
</font></p>
<p><font size="+1" color="#990000"><b>Project News</b></font><br/>
<font size="-1">
<!-- Pull in the 10 most recent news items -->
<xsl:for-each select="descendant::event[position() &lt;= 10]">
&#183; <a>
<xsl:attribute name="href">
news/newsflash.html#<xsl:call-template name="generate-event-anchor"/>
</xsl:attribute>
<xsl:choose>
<xsl:when test="count(child::title)">
<xsl:value-of select="title"/><br/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="p"/><br/>
</xsl:otherwise>
</xsl:choose>
</a>
</xsl:for-each>
<a href="news/newsflash.html">More...</a>
</font></p>
<p><font size="+1" color="#990000"><b>FreeBSD Press</b></font><br/>
<font size="-1">
<!-- Pull in the 10 most recent press items -->
<xsl:for-each select="document('news/press.xml')/descendant::story[position() &lt; 10]">
&#183; <a>
<xsl:attribute name="href">
news/press.html#<xsl:call-template name="generate-story-anchor"/>
</xsl:attribute>
<xsl:value-of select="name"/>
</a><br/>
</xsl:for-each>
<a href="news/press.html">More...</a>
</font>
</p>
</td>
</tr>
</table>