pid = $pid; } $pid = safe_GET_xref('rootid', ''); if (empty($pid)) $pid = safe_POST_xref('rootid', ''); if (!empty($pid)) { $controller->pid = $pid; } $famid = safe_GET('famid', WT_REGEX_XREF, ''); if (empty($famid)) $famid = safe_POST('famid', WT_REGEX_XREF, ''); if (!empty($famid)) { $controller->famid = $famid; } $sid = safe_GET('sid', WT_REGEX_XREF, ''); if (empty($sid)) $sid = safe_POST('sid', WT_REGEX_XREF, ''); if (!empty($sid)) { $controller->sid = $sid; } if ($sb_action=='loadMods') { $counter = 0; foreach ($sidebarmods as $mod) { if (isset($controller)) $mod->setController($controller); if ($mod->hasSidebarContent()) { ?>

getTitle(); ?>

getSidebarContent(); else { ?>
setController($controller); echo $mod->getSidebarContent(); } exit; } if (isset($sidebarmods[$sb_action])) { $mod = $sidebarmods[$sb_action]; echo $mod->getSidebarAjaxContent(); } exit; } global $controller; $pid=''; $famid=''; if (isset($controller)) { if (isset($controller->pid)) $pid = $controller->pid; if (isset($controller->rootid)) $pid = $controller->rootid; if (isset($controller->famid)) $famid = $controller->famid; if (isset($controller->sid)) $pid = $controller->sid; } else { $pid = safe_GET_xref('pid', ''); if (empty($pid)) $pid = safe_POST_xref('pid', ''); if (empty($pid)) $pid = safe_GET_xref('rootid', ''); if (empty($pid)) $pid = safe_POST_xref('rootid', ''); if (empty($pid)) $pid = safe_POST_xref('sid', ''); if (empty($pid)) $pid = safe_GET_xref('sid', ''); $famid = safe_GET('famid', WT_REGEX_XREF, ''); if (empty($famid)) $famid = safe_POST('famid', WT_REGEX_XREF, ''); } ?> '; echo WT_JS_START; ?> jQuery.noConflict(); // @see http://docs.jquery.com/Using_jQuery_with_Other_Libraries/ var loadedMods = new Array(); function closeCallback() { jQuery('#sidebarAccordion').hide(); jQuery('#sidebar_pin').hide(); if (pinned == false) { jQuery.get('individual.php?pid=pid; ?>&action=ajax&pin=false'); pinned = false; } if (jQuery("#tabs li:eq("+jQuery("#tabs").tabs("option", "selected")+") a").attr("title") == "googlemap") { loadMap(); map.setMapType(); SetMarkersAndBounds(); ResizeMap(); } } function openCallback() { jQuery('#sidebarAccordion').accordion({ /* fillSpace: true, */ autoHeight: false, changestart: function(event, ui) { loadedMods[ui.oldHeader.attr('title')] = true; var active = ui.newHeader.attr('title'); if (!loadedMods[active]) { jQuery('#sb_content_'+active).load('sidebar.php?sb_action=loadmod&mod='+active+'&pid=&famid='); } } }); if (jQuery("#tabs li:eq("+jQuery("#tabs").tabs("option", "selected")+") a").attr("title") == "googlemap") { loadMap(); map.setMapType(); SetMarkersAndBounds(); ResizeMap(); } } jQuery(document).ready(function() { // Sidebar Pin Function jQuery('#sidebar_pin').toggle( function() { jQuery('#sidebar_pin img').attr('src', '').attr('title', ''); jQuery.get('individual.php?pid=pid; ?>&action=ajax&pin=true'); pinned = true; }, function() { jQuery('#sidebar_pin img').attr('src', '').attr('title', ''); jQuery.get('individual.php?pid=pid; ?>&action=ajax&pin=false'); pinned = false; } ); jQuery('#sidebar_pin').click(); // --------------------- var modsLoaded = false; // Sidebar Open/Close Function // Sidebar Open jQuery('#sidebar_open').toggle(function() { jQuery('#sidebar_open img').attr('style', 'margin-left:255px;' ).attr('src', '').attr('title', ''); jQuery('#sidebar').animate({ right: "0px", width: "260px" }, 500); if (!modsLoaded) { jQuery('#sidebarAccordion').load('sidebar.php', 'sb_action=loadMods&pid=&famid=', openCallback); modsLoaded=true; } else { jQuery("#sidebarAccordion").accordion("resize"); openCallback(); } jQuery('#sidebarAccordion').show(); jQuery('#sidebar_pin').show(); // Shift content var newwidth = 310; newwidth = jQuery('#tabs').width() - newwidth; // NOTE: REM next line to avoid the "page shift" when Navigator is opened. (Purely a preference choice) jQuery('#tabs > div').css('width', newwidth+'px'); // jQuery('#sidebar_pin').click(); jQuery.get('individual.php?pid=pid; ?>&action=ajax&pin=true&sb_closed=false'); jQuery.get('individual.php?pid=pid; ?>&action=ajax&pin=true&sb_closed=false'); jQuery.get('individual.php?pid=pid; ?>&action=ajax&pin=false&sb_closed=false'); sb_open=true; // Sidebar Close }, function() { jQuery('#sidebar_open img').attr('style', 'margin-left:0px;' ).attr('src', '').attr('title', ''); jQuery('#sidebar').css('left', ''); jQuery('#sidebar').animate({ right: "4px", width: "0px" }, 500, 'linear', closeCallback); // Shift content back jQuery('#tabs div').css('width', ''); // jQuery('#sidebar_pin').click(); jQuery.get('individual.php?pid=pid; ?>&action=ajax&pin=false&sb_closed=true'); sb_open=false; }); // ----------------------------- jQuery('#sidebar_open').click(); jQuery('#sidebar_controls').show(); if (pinned==false) { jQuery('#sidebar_pin').click(); } jQuery('#sidebar_controls').show(); if (pinned==true) { jQuery('#sidebar_open').click(); } jQuery('#sidebar_controls').show(); }); '; if (isset($_SESSION['WT_pin']) && $_SESSION['WT_pin'] && $sidebar_state == "open") { ?>