reconstruire arbre binaire left right

  • Posts: 2639
  • Thank you received: 66
  • Hikashop Business
12 years 4 months ago #56376

J'ai importe les catégories manuellement de virtuemart pour faire correspondre (+100) les id
mais category_left et right restent bien sur vide

quel code utiliser pour les reconstruire ?

merci

Last edit: 12 years 4 months ago by erickb.

Please Log in or Create an account to join the conversation.

  • Posts: 82867
  • Thank you received: 13373
  • MODERATOR
12 years 4 months ago #56459

Il faut utiliser ce code:

$class=hikashop_get('class.category');
$root = $class->get($class->getRoot());
$class->rebuildTree($root,0,1);

Please Log in or Create an account to join the conversation.

  • Posts: 2639
  • Thank you received: 66
  • Hikashop Business
12 years 4 months ago #56466

super merci

Please Log in or Create an account to join the conversation.

Time to create page: 0.055 seconds
Powered by Kunena Forum