.
*/
namespace Fisharebest\Webtrees;
use Fisharebest\Webtrees\Controller\TimelineController;
use Fisharebest\Webtrees\Functions\Functions;
use Fisharebest\Webtrees\Functions\FunctionsPrint;
global $WT_TREE;
$basexoffset = 0;
$baseyoffset = 0;
define('WT_SCRIPT_NAME', 'timeline.php');
require './includes/session.php';
$controller = new TimelineController;
$controller
->restrictAccess(Module::isActiveChart($WT_TREE, 'timeline_chart'))
->pageHeader()
->addExternalJavascript(WT_AUTOCOMPLETE_JS_URL)
->addInlineJavascript('autocomplete();');
?>
px; top: px;">
baseyear . '—'; ?>
scale;
if ($mod < 1) {
$mod = 1;
}
for ($i = $controller->baseyear + 1; $i < $controller->topyear; $i++) {
if ($i % $mod === 0) {
echo '
';
echo $i . '—';
echo '
';
}
}
echo '
';
echo $controller->topyear . '—';
echo '
';
Functions::sortFacts($controller->indifacts);
$factcount = 0;
foreach ($controller->indifacts as $fact) {
$controller->printTimeFact($fact);
$factcount++;
}
// print the age boxes
foreach ($controller->people as $p => $indi) {
$pid = $indi->getXref();
$ageyoffset = $baseyoffset + ($controller->bheight * $p);
$col = $p % 6;
?>
|
bheight / 2)) / $controller->scale) + $controller->baseyear;
if (!empty($controller->birthyears[$pid])) {
$tage = $tyear - $controller->birthyears[$pid];
?>
|