"but I just get objects"

Are you expecting something else?  the ".clone()" method, like most of
the whole jQuery API returns a jQuery wrapped object

to get the HTML of a cloned item, you'll need to use the ".html()"
method.....  and you also need to be very aware, that ".clone()" will
bring the id of the object to the new object as well, which could
cause issues on future selectors strings

And last note, why would you make copies of objects just to reorder
them?  that doesn't make much sense



On Nov 28, 4:54 am, Vaskerville <[EMAIL PROTECTED]> wrote:
> I'm having the worst time working with clone(). It returns an object...still
> can't access it.
>
> What I'm doing is looping through a list of divs (same class) and trying to
> clone each one. I want to clone them so that I can reorder them.
>
> var html;
>
> // in the loop
> html += $('#myDiv-' + id).clone();
>
> Is what I think should work...but I just get objects.
>
> Any tips here on this one?
>
> Thanks
> --
> View this message in 
> context:http://www.nabble.com/How-does-clone%28%29-work--tp20731606s27240p207...
> Sent from the jQuery General Discussion mailing list archive at Nabble.com.

Reply via email to