21 Replies Latest reply on Nov 4, 2011 2:55 PM by BenPleysier

    Why doesn't this Spry work?

    greenber2 Level 1

      as a simple test case, I created a new VBScript/ASP file and in it I created a form with a text field, a Spry confirm text field and another text field for a blur-field. When I smack F12 for a run I get an immediate "fields don't match"-Error before entering even a single character. Source code below. What is wrong?



      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

      <html xmlns="http://www.w3.org/1999/xhtml">


      <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

      <title>Untitled Document</title>

      <script src="/SpryAssets/SpryValidationConfirm.js" type="text/javascript"></script>

      <link href="/SpryAssets/SpryValidationConfirm.css" rel="stylesheet" type="text/css" />




      <p> </p>

      <form id="form1" name="form1" method="post" action="">

        <label for="pwd1">pwd1</label>

        <input type="text" name="pwd1" id="pwd1" />

        <span id="spryconfirm1">

        <label for="pwd2">pwd2</label>

        <input type="text" name="pwd2" id="pwd2" />

      <span class="confirmInvalidMsg">The values don't match.</span></span>

        <label for="blur">blur</label>

        <input type="text" name="blur" id="blur" />


      <p> </p>

      <script type="text/javascript">

      var spryconfirm1 = new Spry.Widget.ValidationConfirm("spryconfirm1", "pwd1", {isRequired:false, validateOn:["blur"]});