getFullName(); $addname=$person->getAddName(); // -- print html header information print_header(PrintReady($name) . " " . i18n::translate('Compact Chart')); if ($ENABLE_AUTOCOMPLETE) require WT_ROOT.'js/autocomplete.js.htm'; // LBox ===================================================================================== if (WT_USE_LIGHTBOX) { require WT_ROOT.'modules/lightbox/lb_defaultconfig.php'; require WT_ROOT.'modules/lightbox/functions/lb_call_js.php'; } // ========================================================================================== if (strlen($name)<30) $cellwidth="420"; else $cellwidth=(strlen($name)*14); echo "
"; echo "

" . i18n::translate('Compact Chart') . ":"; echo "
".PrintReady($name) ; if ($addname != "") echo "
" . PrintReady($addname); echo "

"; // -- print the form ?>
"; echo ""; echo ""; // NOTE: Root ID echo ""; echo ""; // NOTE: submit echo ""; if ($SHOW_HIGHLIGHT_IMAGES) { echo ""; echo ""; echo ""; } echo "
"; echo i18n::translate('Root Person ID'), help_link('rootid'), ""; echo ""; print_findindi_link("rootid",""); echo ""; echo ""; echo "
"; echo i18n::translate('Show highlight images in people boxes'), help_link('SHOW_HIGHLIGHT_IMAGES'); echo ""; echo "
"; echo "
"; echo "
"; // process the tree $treeid = ancestry_array($rootid, 5); echo "
"; echo ""; // 1 echo ""; print_td_person(16); echo ""; echo ""; echo ""; print_td_person(18); echo ""; print_td_person(24); echo ""; echo ""; echo ""; print_td_person(26); echo ""; // 2 echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; // 3 echo ""; print_td_person(8); echo ""; print_td_person(4); echo ""; print_td_person(9); echo ""; print_td_person(12); echo ""; print_td_person(6); echo ""; print_td_person(13); echo ""; // 4 echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; // 5 echo ""; print_td_person(17); print_td_person(19); echo ""; print_td_person(25); print_td_person(27); echo ""; // 6 echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; // 7 echo ""; echo ""; echo ""; print_td_person(2); echo ""; echo ""; echo ""; print_td_person(3); echo ""; echo ""; echo ""; // 8 echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; // 9 echo ""; print_td_person(20); print_td_person(22); echo ""; print_td_person(28); print_td_person(30); echo ""; // 10 echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; // 11 echo ""; print_td_person(10); echo ""; print_td_person(5); echo ""; print_td_person(11); echo ""; print_td_person(14); echo ""; print_td_person(7); echo ""; print_td_person(15); echo ""; // 12 echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; // 13 echo ""; print_td_person(21); echo ""; echo ""; echo ""; print_td_person(23); echo ""; print_td_person(29); echo ""; echo ""; echo ""; print_td_person(31); echo ""; echo "
"; print_arrow_person(16, "up"); echo ""; print_arrow_person(18, "up"); echo ""; print_arrow_person(24, "up"); echo ""; print_arrow_person(26, "up"); echo "
"; print_arrow_person(8, "left"); echo ""; print_arrow_person(9, "right"); echo ""; print_arrow_person(12, "left"); echo ""; print_arrow_person(13, "right"); echo "
"; print_arrow_person(17, "down"); echo ""; print_arrow_person(4, "up"); echo ""; print_arrow_person(19, "down"); echo ""; print_arrow_person(25, "down"); echo ""; print_arrow_person(6, "up"); echo ""; print_arrow_person(27, "down"); echo "
     
"; echo ""; echo ""; echo ""; print_td_person(1); echo ""; echo "
"; print_arrow_person(2, "left"); echo ""; print_arrow_person(3, "right"); echo "
"; echo "
"; echo "
 "; print_arrow_person(5, "down"); echo ""; print_arrow_person(7, "down"); echo "
"; print_arrow_person(20, "up"); echo ""; print_arrow_person(22, "up"); echo ""; print_arrow_person(28, "up"); echo ""; print_arrow_person(30, "up"); echo "
"; print_arrow_person(10, "left"); echo ""; print_arrow_person(11, "right"); echo ""; print_arrow_person(14, "left"); echo ""; print_arrow_person(15, "right"); echo "
"; print_arrow_person(21, "down"); echo ""; print_arrow_person(23, "down"); echo ""; print_arrow_person(29, "down"); echo ""; print_arrow_person(31, "down"); echo "
"; echo "
"; print_footer(); function print_td_person($n) { global $treeid, $WT_IMAGES; global $TEXT_DIRECTION, $MULTI_MEDIA, $SHOW_HIGHLIGHT_IMAGES, $USE_SILHOUETTE, $WT_IMAGES; global $showthumbs; $text = ""; $pid = $treeid[$n]; if ($TEXT_DIRECTION=="ltr") { $title = i18n::translate('Individual information').": ".$pid; } else { $title = $pid." :".i18n::translate('Individual information'); } if ($pid) { $indi=Person::getInstance($pid); $name=$indi->getFullName(); $addname=$indi->getAddName(); if ($showthumbs && $MULTI_MEDIA && $SHOW_HIGHLIGHT_IMAGES) { $object = find_highlighted_object($pid, WT_GED_ID, $indi->getGedcomRecord()); if (!empty($object)) { $whichFile = thumb_or_main($object); // Do we send the main image or a thumbnail? $size = findImageSize($whichFile); $class = "pedigree_image_portrait"; if ($size[0]>$size[1]) $class = "pedigree_image_landscape"; if ($TEXT_DIRECTION == "rtl") $class .= "_rtl"; // NOTE: IMG ID $imgsize = findImageSize($object["file"]); $imgwidth = $imgsize[0]+50; $imgheight = $imgsize[1]+150; if (WT_USE_LIGHTBOX) { $text .= ""; } else { $text .= ""; } $birth_date=$indi->getBirthDate(); $death_date=$indi->getDeathDate(); $text .= "\"\"Display(false)." - ".$death_date->Display(false)))."\""; if ($imgsize) $text .= " />"; else $text .= " />"; } else if ($USE_SILHOUETTE && isset($WT_IMAGES["default_image_U"])) { $class = "pedigree_image_portrait"; if ($TEXT_DIRECTION == "rtl") $class .= "_rtl"; $sex = $indi->getSex(); $text = "\"\""; } } $text .= "getHtmlUrl()."\" title=\"$title\"> "; $text .= PrintReady(htmlspecialchars(strip_tags($name))); if ($addname) $text .= "
" . PrintReady($addname); $text .= "
"; $text .= "
"; if ($indi->canDisplayDetails()) { $text.=""; $text.=$indi->getBirthYear().'-'.$indi->getDeathYear(); $age=GedcomDate::GetAgeYears($indi->getBirthDate(), $indi->getDeathDate()); if ($age) { $text.=" ".PrintReady("({$age})").""; } $text.=""; } } //Removed by BH causing problems with nicknames not printing //$text = unhtmlentities($text); // -- empty box if (empty($text)) { $text = " 
 
"; } // -- box color $isF=""; if ($n==1) { if ($indi->getSex()=='F') { $isF="F"; } } elseif ($n%2) { $isF="F"; } // -- box size if ($n==1) { echo ""; echo $text; echo ""; } function print_arrow_person($n, $arrow_dir) { global $treeid, $showthumbs, $TEXT_DIRECTION, $WT_IMAGES; $pid = $treeid[$n]; $arrow_swap = array("l"=>"0", "r"=>"1", "u"=>"2", "d"=>"3"); $arrow_dir = substr($arrow_dir,0,1); if ($TEXT_DIRECTION=="rtl") { if ($arrow_dir=="l") { $arrow_dir="r"; } elseif ($arrow_dir=="r") { $arrow_dir="l"; } } if ($TEXT_DIRECTION=="ltr") { $title = i18n::translate('Compact Chart').": ".$pid; } else { $title = $pid." :".i18n::translate('Compact Chart'); } $arrow_img = "$title"; $hideArrow = ""; $text = ""; if ($pid) { $text .= ""; $text .= $arrow_img.""; } // -- arrow to empty box does not have a url attached. else $text = $hideArrow; echo $text; }