I wouldn't be surprised if the fact that you are removing and adding
an element with the same id be the cause of your trouble in IE.

I generally avoid doing this, as it often has some impredictable
effects.



On Mar 6, 10:16 pm, "RobG" <[EMAIL PROTECTED]> wrote:
> On Mar 7, 5:53 am, "Booshan" <[EMAIL PROTECTED]> wrote:
>
> > JS for replace and remove looks like this...
>
> > $('d1').replace( "<div id='d1'>Some Data</div>");
>
> > $('d1').remove();
>
> You'll have to try harder:
>
>   <script type="text/javascript" src="prototype.js"></script>
>
>   <div id="d1">d1</div>
>   <div id="d2">d2</div>
>   <div id="d3">d3</div>
>   <div id="d4">d4</div>
>
>   <button onclick="
>     $('d1').replace( '<div id=d1>Some Data</div>');
>     $('d1').remove();
>   ">Replace & remove d1</button>
>
> Works fine in Prototype.js 1.5.
>
> --
> Rob


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to