function showPageHeader($HeaderString) { global $officialDatabaseName; // these variables are defined in 'ini.inc.php' global $hostInstitutionAbbrevName; global $hostInstitutionName; global $hostInstitutionURL; global $helpResourcesURL; global $logoImageURL; global $logoImageWidth; global $logoImageHeight; global $loginWelcomeMsg; // these variables are globally defined in function 'showLogin()' in 'include.inc.php' global $loginStatus; global $loginLinks; global $displayType; global $query; global $queryURL; global $showQuery; global $showLinks; global $showRows; global $citeStyle; global $citeOrder; global $loc; // '$loc' is made globally available in 'core.php' ?> <table class="pageheader" align="center" width="95%" summary="This holds the title logo and info"> <tr> <td rowspan="2" align="left" width="<?php echo $logoImageWidth + 26; ?> "><a href="<?php echo $hostInstitutionURL; ?> "><img src="<?php echo $logoImageURL; ?> " border="0" alt="<?php echo encodeHTML($hostInstitutionAbbrevName); ?> Home" title="<?php echo encodeHTML($hostInstitutionName); ?> " width="<?php echo $logoImageWidth; ?> " height="<?php echo $logoImageHeight; ?> "></a></td> <td width="60%"> <h4><?php echo encodeHTML($officialDatabaseName); ?> </h4> <p><?php echo $HeaderString; ?> </p> <span class="smallup"> <a href="index.php"<?php echo addAccessKey("attribute", "home"); ?> title="<?php echo $loc["LinkTitle_Home"] . addAccessKey("title", "home"); ?> "><?php echo $loc["Home"]; ?> </a> | <a href="show.php?records=all"<?php echo addAccessKey("attribute", "show_all"); ?> title="<?php echo $loc["LinkTitle_ShowAll"] . addAccessKey("title", "show_all"); ?> "><?php echo $loc["ShowAll"]; ?> </a> | <a href="simple_search.php"<?php echo addAccessKey("attribute", "search"); ?> title="<?php echo $loc["LinkTitle_SimpleSearch"] . addAccessKey("title", "search"); ?> "><?php echo $loc["SimpleSearch"]; ?> </a> | <a href="advanced_search.php"<?php echo addAccessKey("attribute", "adv_search"); ?> title="<?php echo $loc["LinkTitle_AdvancedSearch"] . addAccessKey("title", "adv_search"); ?> "><?php echo $loc["AdvancedSearch"]; ?> </a><?php // ------------------------------------------------------- if (isset($_SESSION['user_permissions']) and preg_match("/allow_add/", $_SESSION['user_permissions'])) { // ... include a link to 'record.php?recordAction=add...': ?> | <a href="record.php?recordAction=add"<?php echo addAccessKey("attribute", "add"); ?> title="<?php echo $loc["LinkTitle_AddRecord"] . addAccessKey("title", "add"); ?> "><?php echo $loc["AddRecord"]; ?> </a><?php } // ------------------------------------------------------- if (isset($_SESSION['user_permissions']) and preg_match("/allow_import|allow_batch_import/", $_SESSION['user_permissions'])) { // ... include a link to 'import.php': ?> | <a href="import.php"<?php echo addAccessKey("attribute", "import"); ?> title="<?php echo $loc["LinkTitle_Import"] . addAccessKey("title", "import"); ?> "><?php echo $loc["Import"]; ?> </a><?php } // ------------------------------------------------------- ?> </span> </td> <td class="small" rowspan="2" align="right"> <div id="loginInfo" style="text-align: right"> <div id="loginStatus" style="margin: 5px 0"> <?php echo $loginStatus; ?> <?php echo $loginWelcomeMsg ? ' - ' . $loginWelcomeMsg : ''; ?> </div> <div id="loginLinks" style="margin: 5px 0"> <?php echo $loginLinks; ?> </div> <?php if (!isset($_SESSION['loginEmail'])) { // Display Options: // Get all languages that were setup and enabled by the admin: $languagesArray = getLanguages(""); // function 'getLanguages()' is defined in 'include.inc.php' $languageOptionTags = buildSelectMenuOptions($languagesArray, "/ *; */", "\t\t\t", true); // build properly formatted <option> tag elements from language items returned by function 'getLanguages()' ?> <div id="language" style="margin: 5px 0"> <form action="select_language.php" method="post"> <div class="row collapse"> <div class="small-10 columns"> <select name="language_id"> <option value="">-- Language --</option> <?php echo $languageOptionTags; ?> </select> </div> <div class="small-2 columns"> <button type="submit" class="button secondary tiny">Select</button> </div> </div> </form> </div> <?php } ?> </div> <div id="queryrefs"> <?php echo buildQuickSearchElements($query, $queryURL, $showQuery, $showLinks, $showRows, $citeStyle, $citeOrder, $displayType); ?> </div> </td> </tr> </table> <?php }
function showPageFooter($HeaderString) { global $officialDatabaseName; // usage example: <a href="index.php">[? echo encodeHTML($officialDatabaseName); ?]</a> global $hostInstitutionAbbrevName; // usage example: <a href="[? echo $hostInstitutionURL; ?]">[? echo encodeHTML($hostInstitutionAbbrevName); ?] Home</a> global $hostInstitutionName; // (note: in the examples above, square brackets must be replaced by their respective angle brackets) global $hostInstitutionURL; global $helpResourcesURL; global $loginWelcomeMsg; // these variables are globally defined in function 'showLogin()' in 'include.inc.php' global $loginStatus; global $loginLinks; global $loc; // '$loc' is made globally available in 'core.php' ?> </div></div></div> <div id="column-one"> <div id="p-cactions" class="portlet"> <h5>Views</h5> <ul> <li id="ca-talk" class="selected" ><a href="index.php">References</a></li><li id="search"><a href="simple_search.php" title="search the main fields of the database">Simple Search</a></li> <li><a href="advanced_search.php" title="search all fields of the database">Advanced Search</a></li> <?php // ------------------------------------------------------- if (isset($_SESSION['user_permissions']) and preg_match("/allow_add/", $_SESSION['user_permissions'])) { // ... include a link to 'record.php?recordAction=add...': ?> <LI id="ca-watch"><a href="record.php?recordAction=add" title="add a record to the database">Add Record</a> <?php } else { ?> <LI id="ca-watch"><a href="/refbase-svn/record.php?recordAction=add" title="add a suggested record to the database">Add Record (suggest)</a> <?php } // ------------------------------------------------------- if (isset($_SESSION['user_permissions']) and preg_match("/allow_import|allow_batch_import/", $_SESSION['user_permissions'])) { // ... include a link to 'import.php': ?> <LI><a href="import.php" title="import records">Import</a> <?php } else { ?> <LI><a href="/refbase-svn/import.php" title="import suggested records">Import (suggest)</a> <?php } ?> </ul> </div> <div class="portlet" id="p-personal"> <h5>Personal tools</h5> <div class="pBody"> <ul> <li id="pt-userpage"><?php echo preg_replace('/You\'re logged in as<br>/', '', $loginStatus); ?> </li><li id="pt-mytalk"> <?php echo $loginLinks; ?> </li> </ul> </div> </div> <div class="portlet" id="p-logo"> <a style="background-image: url(../skins/common/images/wiki.png);" href="../index.php/Seidman_Group" title="Seidman Group"></a> </div> <div class='portlet' id='p-Seidman_Group'> <h5>Seidman Group</h5> <div class='pBody'> <ul> <li id="n-Seidman-Group"><a href="/Seidman_Group">Seidman Group</a></li> <li id="n-Research"><a href="/Category:Research">Research</a></li> <li id="n-People"><a href="/Category:People">People</a></li> </ul> </div> </div> <div class='portlet' id='p-NUCAPT'> <h5>NUCAPT</h5> <div class='pBody'> <ul> <li id="n-Instruments"><a href="/Category:Tools">Instruments</a></li> <li id="n-Calendar"><a href="http://arc.nucapt.northwestern.edu/phpicalendar">Calendar</a></li> <li id="n-Visit"><a href="/Visit">Visit</a></li> </ul> </div> </div> <div class='portlet' id='p-Atom-Probe_Tomography'> <h5>Atom-Probe Tomography</h5> <div class='pBody'> <ul> <li id="n-References"><a href="http://arc.nucapt.northwestern.edu/refbase">References</a></li> <li id="n-AtomProbe-mailing-list"><a href="http://arc.nucapt.northwestern.edu/mailman/listinfo/atomprobe">AtomProbe mailing list</a></li> </ul> </div> </div> <div class="portlet" id="p-tb"> <h5>Search</h5> <div class="pBody"> <?php echo buildQuickSearchElements($query, $queryURL, $showQuery, $showLinks, $showRows, $citeStyle, $citeOrder, $displayType); ?> <ul> <li><a href="simple_search.php" title="search the main fields of the database">Simple Search</a> <li><a href="advanced_search.php" title="search all fields of the database">Advanced Search</a> <?php // ------------------------------------------------------- if (isset($_SESSION['user_permissions']) and preg_match("/allow_sql_search/", $_SESSION['user_permissions'])) { // ... include a link to 'sql_search.php': ?> <li><a href="sql_search.php" title="search the database by use of a SQL query">SQL Search</a> <?php } // ------------------------------------------------------- ?> <li><a href="library_search.php" title="search the library of the <?php echo encodeHTML($hostInstitutionAbbrevName); ?> ">Library Search</a> </ul> </div></div> <div class="portlet" id="p-tc"> <h5>Toolbox</h5> <div class="pBody"> <ul> <?php // ------------------------------------------------------- if (isset($_SESSION['user_permissions']) and preg_match("/allow_add/", $_SESSION['user_permissions'])) { // ... include a link to 'record.php?recordAction=add...': ?> <LI><a href="record.php?recordAction=add" title="add a record to the database">Add Record</a> <?php } // ------------------------------------------------------- if (isset($_SESSION['user_permissions']) and preg_match("/allow_import|allow_batch_import/", $_SESSION['user_permissions'])) { // ... include a link to 'import.php': ?> <LI><a href="import.php" title="import records">Import</a> <?php } // ------------------------------------------------------- if (isset($_SESSION['user_permissions']) and preg_match("/allow_details_view/", $_SESSION['user_permissions'])) { // ... include a link to 'show.php': ?> <LI><a href="show.php" title="display details for a particular record by entering its database serial number">Show Record</a> <?php } if (isset($_SESSION['user_permissions']) and preg_match("/allow_cite/", $_SESSION['user_permissions'])) { // ... include a link to 'extract.php': ?> <LI><a href="extract.php" title="extract citations from a text and build an appropriate reference list">Extract Citations</a><?php } // ------------------------------------------------------- ?> </ul> </div></div></div> <div class="visualClear"></div> <div id="footer"> <div id="f-poweredbyico"><a href="http://www.refbase.net/"><img src="img/refbase_credit.gif" alt="refbase"></a></div><ul id="f-list"> <li><?php echo date('j M Y'); ?> </li> <li id="f-about"><a href="/index.php/Seidman_Group" title="Seidman Group">NUCAPT: Northwestern University Center for Atom-Probe Tomography</a></li> </ul> </div> </div> <?php }