exit(0); } if (isset($argv[1])) { $url = $argv[1]; } else { $url = $config->get('geneanet/default-url'); } $grabber = new Grabber($geneanet); $grabber->setDelay($config->get('grabber/delay')); if ($config->get('connexion/proxy') != '') { $grabber->setProxy($config->get('connexion/proxy')); } $test = 'single'; switch ($test) { case 'single': $p = $grabber->grabSingle($url); # print_r($p); echo utf8_decode($p); break; case 'ascendants': $p = $grabber->grabSingle($url); $list = $grabber->grabAscendants($p, $level = 15); break; case 'descendants': $p = $grabber->grabSingle($url); $grabber->grabDescendants($p, $level = 14); break; case 'siblings': $p = $grabber->grabSingle($url); printf("siblings of : %s\n", utf8_decode($p->quickDisplay())); $list = $grabber->grabSiblings($p);