<?xml-stylesheet type="text/xsl" href="/xforms-tests/xsltforms/xsltforms.xsl"?>
<html xmlns:my="http://commerce.example.com/payment" xmlns:txs="http://sourceforge.net/projects/txs" xmlns="http://www.w3.org/1999/xhtml" xmlns:req="http://www.agencexml.com/requests" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ev="http://www.w3.org/2001/xml-events" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
	<head>
		<link rel="stylesheet" href="../../driverPages/forms/TestSuite11.css"/>
		<title>11.2.e xforms-submit stops with invalid instance data</title>
		<xforms:model>
			<xforms:instance>
				<root xmlns="">
					<data xsi:type="xsd:integer">ab.cd</data>
				</root>
			</xforms:instance>
			<xforms:instance id="error_holder">
				<root xmlns="">
					<error_name/>
				</root>
			</xforms:instance>
			<xforms:submission id="sub1" method="post" ref="data" action="http://www.agencexml.com/xforms-tests/xsltforms/echo.php" replace="none"/>
		</xforms:model>
	</head>
	<body>
		<xforms:group>
			<xforms:label class="title">11.2.e xforms-submit stops with invalid instance data</xforms:label>
		</xforms:group>
		<xforms:group>
			<xforms:label>
			  After you activate the Submit Here submit control you must see an xforms-submit-error 
			  message and see the value "validation-error" as output from the Error Name output control. 
			</xforms:label>
		</xforms:group>
		<xforms:group>
			<xforms:output ref="instance('error_holder')/error_name">
				<xforms:label>Error Name : </xforms:label>
			</xforms:output>
		</xforms:group>
		<xforms:submit submission="sub1">
			<xforms:label>Submit Here</xforms:label>
		</xforms:submit>
		<xforms:action ev:event="xforms-submit-error" ev:observer="sub1">
			<xforms:message level="modal">xforms-submit-error</xforms:message>
			<xforms:setvalue ref="instance('error_holder')/error_name" value="event('error-type')"/>
		</xforms:action>
		
	</body>
</html>