Abrar, I am just cloning the set of elements not generating anything
on the fly, it works fine till the time I don't reset ids/strings in
given below code:

        moveUpDown : function (that, traversOrder, noOfCharts){
                Order = traversOrder || 'down'; //Provides fallback value which 
is
'down'
                if (Order === "up") {
                        var prevElem = 
$(that).closest("[id*='"+conTblHolderId+"']").prev
();
                        if (prevElem.is("[id*='"+conTblHolderId+"']")) {
                                //$.log("Inside up");
                                
$(that).closest("[id*='"+conTblHolderId+"']").insertBefore
(prevElem).css('background','green');
                                
//$.log($(that).closest("[id*='"+conTblHolderId+"']").html())
                        }
                } else if (Order === "down") {
                        var nextElem = 
$(that).closest("[id*='"+conTblHolderId+"']").next
();
                        if (nextElem.is("[id*='"+conTblHolderId+"']")) {
                                
$(that).closest("[id*='"+conTblHolderId+"']").insertAfter
(nextElem);
                        }
                }
                ContentTable.resetElemsIdsOrder(noOfCharts);
        },

You could ee the last line ContentTable.resetElemsIdsOrder
(noOfCharts); which reset the order as well ids/string.

If I comment out this line of code, it works fine in FF also but then
my ordering get lost which is a project requirement.

And last point, live() is equal to bind() so there is no need to use
it in the current scenarios.

Thanks
Mohammed Arif

On Jun 1, 11:48 am, Abrar Arshad <abrar.apt...@gmail.com> wrote:
> hi arif,
>           what i understood from your sample page and explanation that is
> you cannot get the values of those elements which were generated dynamically
> after the page is loaded. If that is the case , you can use jQuery live()
> event to solve this problem, google it
>
> I hope it will help you.
>
> On Mon, Jun 1, 2009 at 9:07 AM, Mohammed Arif <arif.moham...@gmail.com>wrote:
>
>
>
> > I am attaching the sample code to debug the issue:
>
> >http://www.mohammedarif.com/test/index.html
>
> > Steps to reproduce in FF 2/3:
>
> > 1. Click on "Add" button, this will clone the entire piece of code and
> > append in DOM
> > 2. Put some values in form fields in both the tables/divs
> > 3. Click on "Move up" button, entire current table shifted to top but
> > form values get lost
> > 4. Same behavior is coming on "Move down" and "Move to top" also.
>
> > But the entire piece of code is working fine in IE 6/7
>
> > Would appreciate some quick help to retain form values.
>
> > Thanks in advance
> > Mohammed Arif
>
> > On May 29, 1:59 pm, Arif <arif.moham...@gmail.com> wrote:
> > > Hi,
>
> > > Unexpectedly it's not happening in IE 6/7 :)
>
> > > So looking for form jQuery plugin which can save and deserialize form
> > > values on a event.
>
> > > Already using form plugin which saves form values in an Array but it
> > > doesn't write back the values, need to write back those values after
> > > some manipulation to the individual form.
>
> > > But the case is bit different here; we have been using multiple forms
> > > on a single page.
>
> > > Looking for quick reply.
>
> > > Thanks
> > > Mohammed Arif

Reply via email to