Adam Docherty - 2006-03-23 03:18:03
hi I noticed that the update function wasn't moving all the sub categories when you changed the parent. I think this was to do with the query to retrieve the sub categories.
around line 157 the query reads as follows:
$sql2 = "UPDATE ".$this->table_name."
SET position = '".$new_sub_position."'
WHERE position RLIKE '".$sub['id']."%>'";
I found that by changing the WHERE line to:
WHERE id =".$sub['id']."";
the problem was solved.
I am not sure if this problem was confined to my setup, but if you are having the same problems try this method.
@Shadi,
I have worked extensively with this class and I must commend the technique used to create infinite categories - it had me stumped!!! Great thinking and power in simplicity, Shadi :)
-Lobos of www.webvida.com