<?xml version="1.0" encoding="ISO-8859-1"?>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:xfm="http://www.w3.org/2002/xforms" xmlns:my="http://my/">
	<head>
		<link rel="stylesheet" type="text/css" href="xformsdemo.css" />
		<link rel="stylesheet" type="text/css" href="itemset.css" />
		<xfm:model id="cone">
			<xfm:submission id="submit1" method="post" action="http://sinex.tml.hut.fi:8080/xforms/request"/>
			<xfm:submission id="submit-file" method2="postxml" localfile="temp2.xml" target2="http://www.hut.fi/"/>
			<xfm:instance id="main" xmlns="" >
				<my:icecream xmlns:my="http://my/">
					<my:flavours />
					<my:flavour />
				</my:icecream>
			</xfm:instance>
			<xfm:instance id="flavours" >
				<my:flavours xmlns:my="http://my/">
					<my:flavour type="v">
						<my:description>Vanilla</my:description>
					</my:flavour>
					<my:flavour type="s">
						<my:description>Strawberry</my:description>
					</my:flavour>
					<my:flavour type="c">
						<my:description>Chocolate</my:description>
					</my:flavour>
				</my:flavours>
			</xfm:instance>
		</xfm:model>
	</head>
	<body>
		<h1>XForms itemset</h1>
		<p>This example reads the items for the select from the other instance, and the user's selection affects the other instance</p>
		<p xmlns:my="http://my/">
			<!-- user interaction markup -->
			<xfm:select ref="instance('main')/my:flavours">
				<xfm:label>Flavors</xfm:label>
				<xfm:itemset  nodeset="instance('flavours')/my:flavour">
					<xfm:label ref="my:description" />
					<xfm:value ref="@type" />
				</xfm:itemset>
			</xfm:select>
			<xfm:select1  ref="instance('main')/my:flavour" style="color:black;">
				<xfm:label >Flavors</xfm:label>
				<xfm:itemset  nodeset="instance('flavours')/my:flavour">
					<xfm:label ref="my:description" />
					<xfm:value ref="@type" />
				</xfm:itemset>
			</xfm:select1>
		</p>
		<p><xfm:submit style="color:black;"><xfm:label>Submit</xfm:label></xfm:submit></p>
	</body>
</html>
