<xvcd:number>の練習1

<xvcd:number>の動作確認。最もシンプルな例。

【result view】

【xfy_sample0012.xml】
<?xml version="1.0"?>

<?com.xfy vocabulary-connection href="xfy_sample0012.xvcd" ?>
<m3:document xmlns:m3="http://www.makoto3.net/xfy">
	<m3:list>
		<m3:name>山田太郎</m3:name>
		<m3:name>鈴木花子</m3:name>
		<m3:name>吉田真一</m3:name>
		<m3:name>井上次郎</m3:name>
		<m3:name>山口美子</m3:name>
	</m3:list>
</m3:document>

【xfy_sample0012.xvcd】
<?xml version="1.0"?>

<xvcd:xvcd
	xmlns:xvcd="http://xmlns.xfy.com/xvcd"
	xmlns="http://www.w3.org/1999/xhtml"
	xmlns:m3="http://www.makoto3.net/xfy"
	version="1.0">

<xvcd:vocabulary name="xfy_sample" match="m3:document" call-template="root"/>
	<xvcd:template name="root">
		<html>
			<head>
				<title>HelloWorld example</title>
			</head>
			<body>
				<h2>名簿</h2>
					<xvcd:apply-templates select="m3:list"/>
			</body>
		</html>
	</xvcd:template>
	<xvcd:template match="m3:name">
		<xvcd:number count="m3:name" />
		<xvcd:value-of select="." /><br/>
	</xvcd:template>

</xvcd:xvcd>