fp_template.php

  1. 4.x themes/classic/fp_template.php
  2. 5.x themes/basic/fp_template.php
  3. 5.x themes/fp5_clean/fp_template.php
  4. 5.x themes/classic/fp_template.php

File

themes/classic/fp_template.php
View source
  1. <?php
  2. /**
  3. *This script expects several variables to be set before it is included.
  4. *
  5. * $page_content The actual content of the page which appears in the
  6. * center.
  7. * $page_on_load If the page performs any javascript onLoad, it goes here.
  8. * Should include the onLoad command. Ex:
  9. * $page_on_load = "setVars()";
  10. * $page_on_unload If the page is supposed to perform something when the user
  11. * closes it, set it here.
  12. * $page_tabs Contains the HTML to draw the correct tabs at the top of the page.
  13. * $page_is_popup Set to either TRUE or FALSE. If TRUE, do not display the header,
  14. * and possibly have different layout parameters. These are booleans
  15. * and not strings.
  16. * $page_title The HTML title of the browser window.
  17. * $page_has_search Either TRUE or FALSE. Is a boolean, not a string. If set to
  18. * TRUE, the page will have a search bar at the top.
  19. * $page_scroll_top If set, the page will automatically scroll to this position (and
  20. * the one below it) on load.
  21. * $page_scroll_left The page will scroll to this position on load. pageScrollTop
  22. * must also be set for this to happen.
  23. * $page_scroll_to If set, the page will automatically scroll to the named anchor
  24. * specified in this variable. For example, if it is set to "bob", then
  25. * on load, the page will scroll to where that anchor is on the page.
  26. * $pageHelpTopic If the page has a help entry associated with it, enter the topic
  27. * in this variable. It will cause the page to present a help icon.
  28. * $page_hide_report_error if set to TRUE, the page will not display the link to report
  29. * an error.
  30. * $page_banner_is_link true or false. If true, the banner at the top will load FP in a
  31. * new window.
  32. *
  33. **/
  34. $theme_location = fp_theme_location();
  35. ?>
  36. <html>
  37. <head>
  38. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  39. <script src="<?php print base_path() ?>/inc/jquery-1.8.3.min.js" type="text/javascript"></script>
  40. <script src="<?php print base_path() ?>/inc/jquery-ui-1.9.2.custom.min.js" type="text/javascript"></script>
  41. <link rel='stylesheet' type='text/css' href='<?php print base_path() ?>/inc/jqueryui-css/ui-lightness/jquery-ui-1.9.2.custom.min.css'>
  42. <script type='text/javascript'>
  43. <?php print $page_extra_js_settings; ?>
  44. // perform any requested actions on page load...
  45. $(document).ready(function() { <?php print $page_on_load; ?> });
  46. </script>
  47. <?php
  48. // Add extra JS files.
  49. print $page_extra_js_files;
  50. // Load this theme's CSS file(s)
  51. print "<link rel='stylesheet' type='text/css' href='$theme_location/style.css'>";
  52. // Load any extra CSS files which addon modules might have added.
  53. print $page_extra_css_files
  54. ?>
  55. <link rel="shortcut icon" href="favicon.ico" type="image/x-icon" />
  56. <title><?php print $page_title; ?></title>
  57. </head>
  58. <body class='<?php print $page_body_classes; ?>'>
  59. <?php
  60. // If the page is a popup, do not display header..
  61. if ($page_is_popup != TRUE)
  62. {
  63. print "<table width='800' cellpadding='0' cellspacing='0' bgcolor='white' align='center'>";
  64. ?>
  65. <tr>
  66. <td align="left" width="28" valign="baseline" bgcolor="#ECECDB" style="background: url('<?php print "$theme_location/images/"; ?>tl.gif') #ECECDB top left no-repeat;" height="17">
  67. <!--<img src="tl.gif" width="28" height="17" style="margin: 0px; padding: 0px;">-->
  68. </td>
  69. <td valign="baseline" style="background: url('<?php print "$theme_location/images/"; ?>top.gif') #ECECDB repeat-x; width: 800px;"></td>
  70. <td align="right" width="33" valign="baseline" bgcolor="#ECECDB" style="background: url('<?php print "$theme_location/images/"; ?>tr.gif') #ECECDB top right no-repeat;">
  71. <!--<img src="tr.gif" width="33" height="17" style="margin: 0px; padding: 0px;">-->
  72. </td>
  73. </tr>
  74. <tr>
  75. <td align="center" colspan="3">
  76. <div style="background: url('<?php print "$theme_location/images/"; ?>left.gif') repeat-y top left;">
  77. <div style="background: url('<?php print "$theme_location/images/"; ?>right.gif') repeat-y top right;">
  78. <table width="90%" cellpadding="0" cellpadding="0" >
  79. <tr>
  80. <td align="left">
  81. <?php
  82. // ***************** Header Content *****************
  83. // ***************** *****************
  84. if ($page_banner_is_link == true)
  85. {
  86. print "<a href='{$GLOBALS["fp_system_settings"]["self_url"]}' target='_blank'>";
  87. }
  88. ?>
  89. <img src='<?php print "$theme_location/images/"; ?>fp_banner_default.png' border='0'>
  90. <?php
  91. if ($page_banner_is_link == true)
  92. {
  93. print "</a>";
  94. }
  95. ?>
  96. </td>
  97. </tr>
  98. </table>
  99. </div>
  100. </div>
  101. </td>
  102. </tr>
  103. <tr>
  104. <td align="left" valign="bottom" style="background: url('<?php print "$theme_location/images/"; ?>bl.gif') #ECECDB no-repeat;">
  105. <img src="<?php print "$theme_location/images/"; ?>spacer.gif" width="33" height="36">
  106. </td>
  107. <td valign="bottom" style="background: url('<?php print "$theme_location/images/"; ?>bottom.gif') #ECECDB repeat-x;"></td>
  108. <td align="right" valign="bottom" style="background: url('<?php print "$theme_location/images/"; ?>br.gif') #ECECDB no-repeat;">
  109. <img src="<?php print "$theme_location/images/"; ?>spacer.gif" width="33" height="36">
  110. </td>
  111. </tr>
  112. </table>
  113. <br>
  114. <?php
  115. } // close if statement (if isPopup)
  116. ?>
  117. <?php
  118. // Set the page width based on whether or not
  119. // we're in a popup window.
  120. if ($page_is_popup == TRUE)
  121. {
  122. print "<table width='100%' cellpadding='0' cellspacing='0' bgcolor='White' align='center'>";
  123. } else {
  124. print "<table width='800' cellpadding='0' cellspacing='0' bgcolor='White' align='center'>";
  125. }
  126. ?>
  127. <tr>
  128. <td colspan="3">
  129. <table width="100%" cellpadding="0" cellspacing="0" align="left" bgcolor="#ECECDB">
  130. <tr>
  131. <!-- ********** The tabs td ************-->
  132. <td>
  133. <table width="100%" cellpadding="0" cellspacing="0" align="left"">
  134. <tr>
  135. <td align="left">
  136. <?php print $page_tabs; ?>
  137. </td>
  138. </tr>
  139. </table>
  140. </td>
  141. <!-- The possible search bar td -->
  142. <td align="right" width="100%" valign='bottom'>
  143. <?php
  144. // Insert a search bar if there is one.
  145. if ($page_has_search == TRUE && function_exists("student_search_menu")) {
  146. print student_search_render_small_search();
  147. }
  148. ?>
  149. </td>
  150. <td align='right' style='padding-left: 30px'>
  151. </td>
  152. </tr>
  153. </table>
  154. </td>
  155. </tr>
  156. <tr>
  157. <td align="left" valign="baseline" bgcolor="#ECECDB" style="background: url('<?php print "$theme_location/images/"; ?>tl.gif') #ECECDB top left no-repeat;" height="17">
  158. <!--<img src="tl.gif" width="28" height="17" style="margin: 0px; padding: 0px;">-->
  159. </td>
  160. <td valign="baseline" style="background: url('<?php print "$theme_location/images/"; ?>top.gif') #ECECDB repeat-x; width: 800px;"></td>
  161. <td align="right" valign="baseline" bgcolor="#ECECDB" style="background: url('<?php print "$theme_location/images/"; ?>tr.gif') #ECECDB top right no-repeat;">
  162. <!--<img src="tr.gif" width="33" height="17" style="margin: 0px; padding: 0px;">-->
  163. </td>
  164. </tr>
  165. <tr>
  166. <td align="center" colspan="3">
  167. <div style="background: url('<?php print "$theme_location/images/"; ?>left.gif') repeat-y top left;">
  168. <div style="background: url('<?php print "$theme_location/images/"; ?>right.gif') repeat-y top right;">
  169. <table width="90%"
  170. <?php
  171. //------------------------------------------------------
  172. // Force height if page is popup...
  173. //------------------------------------------------------
  174. if ($page_is_popup)
  175. {
  176. print " height='250' ";
  177. }
  178. ?>
  179. cellpadding="0" cellpadding="0">
  180. <tr>
  181. <td align="left" valign='top'>
  182. <div class='page-content'>
  183. <?php
  184. // ***************** Page specific content will be in here *****************
  185. print $page_content;
  186. // ***************** Page specific content was in here *****************
  187. ?>
  188. </div>
  189. </td>
  190. <td valign='top' align='right'>
  191. </td>
  192. </tr>
  193. </table>
  194. </div>
  195. </div>
  196. </td>
  197. </tr>
  198. <tr>
  199. <td align="left" valign="bottom" style="background: url('<?php print "$theme_location/images/"; ?>bl.gif') #ECECDB no-repeat;">
  200. <img src="<?php print "$theme_location/images/"; ?>spacer.gif" width="33" height="36">
  201. </td>
  202. <td valign="bottom" style="background: url('<?php print "$theme_location/images/"; ?>bottom.gif') #ECECDB repeat-x;" width="100%"></td>
  203. <td align="right" valign="bottom" style="background: url('<?php print "$theme_location/images/"; ?>br.gif') #ECECDB no-repeat;">
  204. <img src="<?php print "$theme_location/images/"; ?>spacer.gif" width="33" height="36">
  205. </td>
  206. </tr>
  207. </table>
  208. <?php
  209. //------------------------------------------------
  210. // ------- MSG AT BOTTOM -------------------------
  211. //------------------------------------------------
  212. ?>
  213. <table width="<?php
  214. // Set the page width based on whether or not
  215. // we're in a popup window.
  216. if ($page_is_popup == TRUE)
  217. {
  218. print "100%";
  219. } else {
  220. print "800";
  221. }
  222. ?>" cellpadding="0" cellspacing="0" align="center">
  223. <td width='15'>&nbsp; </td>
  224. <td style='font-size: 8pt;'>
  225. <?php
  226. if ($page_hide_report_error != TRUE) {
  227. print "<a class='nounderline' href='javascript: popupreportcontact()'>" . t("Contact the FlightPath production team") . "</a>";
  228. }
  229. ?>
  230. </td>
  231. </table>
  232. <?php
  233. if ($page_is_popup != true)
  234. {
  235. // TODO: Allow for some kind of copyright notice here? Probably in a setting
  236. //print "<div align='center' style='font-size: 8pt;'>&copy; <a href='http://www.ulm.edu'>University of Louisiana at Monroe</a>, all rights reserved</div>";
  237. }
  238. ?>
  239. </body>
  240. </html>