function standardPage($node, $maindiv = false) { if (isset($_GET['frame'])) { switch ($_GET['frame']) { case "top": include dirname(__FILE__) . '/topframe.php'; break; case "bottom": include dirname(__FILE__) . '/bottomframe.php'; break; case "titlebar": include dirname(__FILE__) . '/titlebar.php'; break; } return; } if ($_SESSION['ref_interface'] == $this->name) { parent::standardPage($node, $maindiv); } else { include dirname(__FILE__) . '/main.php'; } }
} // Last thing: we want to draw a standard page, since we did not previously exit. // TODO: check for specialty pages (search,playlistmanager,etc) // Let's count how many of everything we have if (!isset($_SESSION['jz_num_genres'])) { $root =& new jzMediaNode(); $_SESSION['jz_num_genres'] = $root->getSubNodeCount("nodes", distanceTo("genre")); $_SESSION['jz_num_artists'] = $root->getSubNodeCount("nodes", distanceTo("artist")); $_SESSION['jz_num_albums'] = $root->getSubNodeCount("nodes", distanceTo("album")); $_SESSION['jz_num_tracks'] = $root->getSubNodeCount("nodes", distanceTo("track")); } // The header file defines our drawPage function. $maindiv = isset($_GET['maindiv']) || isset($_POST['maindiv']) ? true : false; // Let's check for security $blocks = new jzBlocks(); if ($blocks->checkForSecure()) { $smarty = smartySetup(); $smarty->assign('path', getcwd()); // Now let's include the template $smarty->display(SMARTY_ROOT . 'templates/slick/security-warning.tpl'); exit; } if (isset($_SESSION['current_interface'])) { $_SESSION['ref_interface'] = $_SESSION['current_interface']; } else { $_SESSION['ref_interface'] = ""; } $_SESSION['current_interface'] = $fe->name; $_SESSION['jz_purge_file_cache'] = "false"; $fe->standardPage($node, $maindiv);