I think this might be the same bug that is currently causing issues for the
validation plugin with 1.1.3a. I hope to find time to fix it tonight.

--
Brandon Aaron

On 6/26/07, Gordon <[EMAIL PROTECTED]> wrote:


Update: Replacing the 1.1.3a jQuery library with 1.1.2 seems to fix
the problem, this would seem to suggest a bug in the new version is
causing my problem.

On Jun 26, 3:16 pm, Gordon <[EMAIL PROTECTED]> wrote:
> I am working on code that will dynamically add some controls to a
> form.  As these controls are meant to be unobtrusive (they add an
> address lookup field to the form that won't work without javascript)
> the HTRML code is to be left out of the form itself and added by the
> script.  A (cut down) versio nof the HTML looks like this:
>
> <form action="#" method="post">
> <fieldset>
> blah blah blah
> </fieldset>
>
> <fieldset class="alt" id="addinfo-address">
> <legend>Address</legend>
> <p>Address</p>
> <input type="hidden" id="address-prefix" value="card." />
>
> <label for="line-1">
>   <span class="label">Address (1): <span>Required</span></span>
>   <input class="fvRequired" type="text" name="card.line-1" id="line-1"
> value="" />
> </label>
>
> <label for="line-2">
>   <span class="label">Address (2):</span>
>   <input class="fvOptional" type="text" name="card.line-2" id="line-2"
> value="" />
> </label>
>
> <label for="line-3">
>   <span class="label">Address (3): </span>
>   <input class="fvOptional" type="text" name="card.line-3" id="line-3"
> value="" />
> </label>
>
> <label for="line-4">
>   <span class="label">Address (4): </span>
>   <input class="fvOptional" type="text" name="card.line-4" id="line-4"
> value="" />
> </label>
>
> <label for="postcode">
>   <span class="label">Postcode: <span>Required</span></span>
>   <input class="fvRequired" type="text" name="card.postcode"
> id="postcode" value="" />
> </label>
>
>  <label><input type="submit" value="Choose Delivery Address &#187;"
> class="button" /></label>
> </fieldset>
> </form>
>
> My Javascript looks like this:
>
> function addLookupFields ()
> {
>         $('#addinfo-address').before ("<fieldset style=\"display:
none;\"
> class=\"highlight\" id=\"address-lookup\"><legend>Address Finder</
> legend><p>Address Finder</p><label for=\"address-info\"><span class=
> \"label\">Postcode: </span><input id=\"address-info\" maxlength=
> \"255\" type=\"text\" /></label><label><input id=\"find-address\" type=
> \"button\" class=\"button\" value=\"Find Address\" /></label></
> fieldset>");
>         return ($('#address-lookup'));
>
> }
>
> $(document).ready (function ()
> {
>         addLookupFields ().slideDown ('slow');
>
> });
>
> This works in FireFox, Opera, Safari but in Internet Explorer it
> causes a script error, Unexpected call to method or property access.
> Can anyone help with this?


Reply via email to