Hello and thanks for viewing.
I have the following script that needs some massaging. The goal is to allow only numeric entries with NO spaces and both a min and max of 10 characters. In other words a ten digit phone number only. I have the max but I don't know the rest. Can someone advise please and thanks in advance.
<link href="SpryAssets/SpryValidationTextField.css" rel="stylesheet" type="text/css">
<form action="http://www.realtyalerts.ca/MyAlerts/Home/Index" method="post">
<input name='id_number' type='text' id='id_number' maxlength="10" />
<span class="textfieldRequiredMsg">A 10 digit phone number is required.</span></span>
<input value='Go' type='submit' />
var sprytextfield1 = new Spry.Widget.ValidationTextField("sprytextfield1");
Then, you can do it with behaviors in DW. With your 'input' for number field selected either in code or design view, go to 'Behaviors' panel (if it is now shown already, click Window > Behaviors to show it).
Click the 'Plus' callout button > Validate Form.
Choose the field that you're validating (in your case, id_number). Accept 'Number from' 10 to 10 (min and max 10). Hit OK.
Btw, just so you know, Spry is no longer being officially supported by Adobe. http://blogs.adobe.com/dreamweaver/2012/08/update-on-adobe-spry-framew ork-availability.html
Start moving to/ learning jQuery.