<?xml version="1.0" encoding="UTF-8"?>
<!--

  $Author: richard $

  $Revision: 1.5 $

  $Log: 3,v $
  Revision 1.5  2002/04/20 08:07:24  richard
  yesno

  Revision 1.4  2002/03/16 09:39:45  richard
   rewrite test

  Revision 1.3  2001/10/30 16:22:25  gb
  Modified all the test files in the wml2 directory such that it puts the <?xml?> declaration back at the top of the file, before the comment.

  Revision 1.2  2001/10/08 21:56:13  gb
  Added the standard header of Author, Revision and Log at the top of each template file.


-->
<test id="wml2/uabehaviour/attribexplang/wmlvariable/variableref/3" 
	class="A" scope="wml2" testtype="application" type="manual" 
	source="wml2#5.5.1.1" device="both">
  <assertion>When using the WML variable attribute expression language, 
  and 'escape' conversion is used, the user agent must apply URL encoding 
  to the string before using it in the current context.
  </assertion>
  <specnote>Create a card that uses the ENTERFORWARD event to set a variable 
  that contains reserved characters that will be escaped when URL encoding 
  is applied(e.g. 'http://foo.com/'). The card should then display the 
  variable using the '$(Foo:escape)' syntax. Make sure the card applies URL 
  encoding to the string when displaying the variable 
  (e.g. 'http%3A%2F%2Ffoo.com'.
  </specnote>
  <results>
    <result>
      <name>submit</name>
      <value>yes</value>
    </result>
  </results>
  <method>
		<![CDATA[
  		<wml:card newcontext="true" id="main">
    		<wml:onevent type="enterforward">
      		<wml:refresh>
        		<wml:setvar name="x" value="href://card2.wml" />
      		</wml:refresh>
    		</wml:onevent>
    		<p>The variable $$x = $(x:escape)</p>
    		<p>Is the value of $$x variable equal to &quot;http%3A%2F%2Fcard2.wml&quot; ?
    			<br/>
				[[yesno]]
			</p>
  		</wml:card>
		]]>
	</method>
</test>
