The following code works perfectly in FF of course, but I also need it to work in (IE) Internet Explorer) I was using the built-in validation
IE Error I'm getting is:
Message: Object doesn't support this property or method
Line: 82
Char: 19
Code: 0
URI: http://joomla.mowlman.com/components/com_chronocontact/js/livevalidation_standalone.js
CODE that is working in FF:
<?php
$script = "
var length_tx1 = new LiveValidation('length_tx1');
length_tx1.add( Validate.Numericality, {
minimum: 1,
maximum: 96
});
";
$script = "
window.addEvent('domready', function() {
$script
});
";
$doc =& JFactory::getDocument();
$doc->addScriptDeclaration($script);
?>
I am using the built in validation for some of my fields, I then needed to further validate length_txt1 to only be numeric 1-96.
My HTML Formcode is:
Any ideas?
Thank you for any help you can provide
-Mowlman
IE Error I'm getting is:
Message: Object doesn't support this property or method
Line: 82
Char: 19
Code: 0
URI: http://joomla.mowlman.com/components/com_chronocontact/js/livevalidation_standalone.js
CODE that is working in FF:
<?php
$script = "
var length_tx1 = new LiveValidation('length_tx1');
length_tx1.add( Validate.Numericality, {
minimum: 1,
maximum: 96
});
";
$script = "
window.addEvent('domready', function() {
$script
});
";
$doc =& JFactory::getDocument();
$doc->addScriptDeclaration($script);
?>
I am using the built in validation for some of my fields, I then needed to further validate length_txt1 to only be numeric 1-96.
My HTML Formcode is:
<div class="form_item">
<div class="form_element cf_textbox">
<label class="cf_label" style="width: 150px;">Length</label>
<input class="cf_inputbox required validate-number" maxlength="2" size="2" title="Enter whole number 1-96 for custom cut length" id="length_tx1" name="length_tx1" type="text";" />
<a class="tooltiplink" onclick="return false;"><img height="16" border="0" width="16" class="tooltipimg" alt="" src="components/com_chronocontact/css/images/tooltip.png"/></a>
<div class="tooltipdiv">Length :: Enter inches 1-96</div>
</div>
<div class="cfclear"> </div>
</div>
<div class="form_item">
<div class="form_element cf_radiobutton" id='fraction_tx1'>
<label class="cf_label" style="width: 150px;">Select Fraction</label>
<div class="float_left">
<input value="1/16" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio00" name="radio0" type="radio" />
<label for="radio00" class="radio_label">1/16</label>
<br />
<input value="1/8" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio01" name="radio0" type="radio" />
<label for="radio01" class="radio_label">1/8</label>
<br />
<input value="3/16" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio02" name="radio0" type="radio" />
<label for="radio02" class="radio_label">3/16</label>
<br />
<input value="3/8" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio03" name="radio0" type="radio" />
<label for="radio03" class="radio_label">3/8</label>
<br />
<input value="5/16" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio04" name="radio0" type="radio" />
<label for="radio04" class="radio_label">5/16</label>
<br />
<input value="1/4" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio05" name="radio0" type="radio" />
<label for="radio05" class="radio_label">1/4</label>
<br />
<input value="7/16" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio06" name="radio0" type="radio" />
<label for="radio06" class="radio_label">7/16</label>
<br />
<input value="1/2" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio07" name="radio0" type="radio" />
<label for="radio07" class="radio_label">1/2</label>
<br />
<input value="9/16" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio08" name="radio0" type="radio" />
<label for="radio08" class="radio_label">9/16</label>
<br />
<input value="5/8" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio09" name="radio0" type="radio" />
<label for="radio09" class="radio_label">5/8</label>
<br />
<input value="11/16" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio010" name="radio0" type="radio" />
<label for="radio010" class="radio_label">11/16</label>
<br />
<input value="3/4" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio" id="radio011" name="radio0" type="radio" />
<label for="radio011" class="radio_label">3/4</label>
<br />
<input value="13/16" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio012" name="radio0" type="radio" />
<label for="radio012" class="radio_label">13/16</label>
<br />
<input value="7/8" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio013" name="radio0" type="radio" />
<label for="radio013" class="radio_label">7/8</label>
<br />
<input value="15/16" title="Select Fraction for custom cut (if Needed) Default is 0" class="radio fraction" id="radio014" name="radio0" type="radio" />
<label for="radio014" class="radio_label">15/16</label>
<br />
</div>
<a class="tooltiplink" onclick="return false;"><img height="16" border="0" width="16" class="tooltipimg" alt="" src="components/com_chronocontact/css/images/tooltip.png"/></a>
<div class="tooltipdiv">Select Fraction :: Select Fraction for custom cut (if Needed) Default is 0</div>
</div>
<div class="cfclear"> </div>
</div>
<div class="form_item">
<div class="form_element cf_textbox">
<label class="cf_label" style="width: 150px;">Quantity</label>
<input class="cf_inputbox required validate-number" maxlength="2"
size="2" title="Please enter a valid number" id="form_qty"
name="quantity" type="text" onchange="processform()" value="1" />
</div>
<div class="cfclear"> </div>
</div>
<?php
$script = "
var length_tx1 = new LiveValidation('length_tx1');
length_tx1.add( Validate.Numericality, {
minimum: 1,
maximum: 96
});
";
$script = "
window.addEvent('domready', function() {
$script
});
";
$doc =& JFactory::getDocument();
$doc->addScriptDeclaration($script);
?>
<input value="" id="hidden_length_combined" name="hidden_length_combined" type="hidden" />
<input value="" id="hidden_length_in_feet" name="hidden_length_in_feet" type="hidden" />
<input value="" id="hidden_price" name="hidden_price" type="hidden" />
<input value="" id="Cut_Length" name="Cut_Length" type="hidden" />
<input value="" id="adjust_price" name="adjust_price" type="hidden" />
<input value="" id="formkey" name="formkey" type="hidden" />
<div class="form_item">
<div class="form_element cf_button">
<input value="Submit" name="button_5" type="submit" /><input type="reset" name="reset" value="Reset"/>
</div>
<div class="cfclear"> </div>
</div>
Any ideas?
Thank you for any help you can provide
-Mowlman