Skip to content

Instantly share code, notes, and snippets.

@vgrish
Created October 23, 2014 06:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vgrish/86bd9891ea027d0c56e7 to your computer and use it in GitHub Desktop.
Save vgrish/86bd9891ea027d0c56e7 to your computer and use it in GitHub Desktop.
<?php
if (!$Referral = $modx->getService('referral', 'Referral', $modx->getOption('referral_core_path', null, $modx->getOption('core_path') . 'components/referral/') . 'model/referral/')) {
return 'Could not load Referral class!';
}
$start = microtime(true);
//$Referral->GeneratePaths();
$res= $Referral->GetChildrenCount(17);
echo "\n";
$res2= $Referral->GetChildren(17);
$res3= $Referral->GetPath(17);
print_r($res);
print_r($res2);
print_r($res3);
$end = microtime(true);
$runtime = $end - $start;
echo "\n";
echo "Время: ". $runtime;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment