Re: How Best to Maintain Sort Order Field

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2007. 04. 20, péntek keltezéssel 09.45-kor Stephen ezt írta:
> Zoltán Németh wrote: 
> > 2007. 04. 20, péntek keltezéssel 09.31-kor Stephen ezt írta:
> >   
> > > Opps. Sorry
> > > 
> > > I meant when I create the category the category_order field is blank.
> > > 
> > > I need a strategy to update/maintain then.
> > >     
> > 
> > yes. I personally do it like when I insert a new record it gets one
> > bigger than the current max - so it gets to the bottom of the list.
> > and I provide buttons to move it up/down/top/bottom which do nothing but
> > adjust the order fields accordingly
> >   
> That is what I want to do!
> 
> Can you expand on this, please?
> 
> How are the "buttons" set up in the form?

nothing special. just like this:
<button name="moveup" onclick="handler.php?cmd=moveup&id=1">

and then in handler.php do a switch for cmd and update the rows
accordingly, then redirect back to the form

greets
Zoltán Németh


(ps sorry if this went for two times, it seems to me that the first has
not arrived to the list...)

> 
> Thanks
> Stephen

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux