
<xhtml:html xmlns:xhtml="http://www.w3.org/1999/xhtml"
      xmlns:xforms="http://www.w3.org/2002/xforms"
	  xmlns:widget="http://orbeon.org/oxf/xml/widget">
    <xhtml:head>
        <xhtml:title>Call service demo</xhtml:title>
        <xforms:model id="main-model">
            <xforms:instance id="main">
				<instance>
					<days-to-add>0</days-to-add>
				</instance>
            </xforms:instance>
			<xforms:instance id="results">
				<instance>
					<date>not known</date>
				</instance>
			</xforms:instance>

		<xforms:submission id="calc-days" ref="instance('main')" 
                method="post" action="/markku/calc-days" replace="instance" instance="results"/>
		</xforms:model>
		
    </xhtml:head>
    <xhtml:body>
		<xhtml:h1>Hello Markku</xhtml:h1>
        <xhtml:p>
            <xforms:input ref="instance('main')/days-to-add">
                <xforms:label>Enter a number</xforms:label>
            </xforms:input>
        </xhtml:p>
        <xhtml:p>
			Today's date plus <xforms:output value="instance('main')/days-to-add"/> days is 
            <xforms:output value="instance('results')/date"/>
        </xhtml:p>
		<xhtml:p>
			<xforms:submit submission="calc-days">
				<xforms:label>Calculate</xforms:label>
			</xforms:submit>
		</xhtml:p>
				
        <widget:xforms-instance-inspector xmlns:widget="http://orbeon.org/oxf/xml/widget"/>
				
				
    </xhtml:body>
</xhtml:html>
