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/fp5_clean/fp_template.php
View source
  1. <?php
  2. /**
  3. * @file
  4. * This is the primary page template for FlightPath.
  5. *
  6. * Certain variables are set by the AdvisingScreen class, in its output_to_browser() method, which
  7. * are available here:
  8. *
  9. *
  10. * $page_content The actual content of the page which appears in the
  11. * center.
  12. * $page_on_load If the page performs any javascript onLoad, it goes here.
  13. * $page_tabs Contains the HTML to draw the correct tabs at the top of the page.
  14. * $page_is_popup Set to either TRUE or FALSE. If TRUE, do not display the header,
  15. * and possibly have different layout parameters. These are booleans
  16. * and not strings.
  17. * $page_title The HTML title of the browser window.
  18. * $page_has_search Either TRUE or FALSE. Is a boolean, not a string. If set to
  19. * TRUE, the page will have a search bar at the top.
  20. * $page_scroll_top If set, the page will automatically scroll to this position (and
  21. * the one below it) on load.
  22. * $page_hide_report_error if set to TRUE, the page will not display the link to report
  23. * an error.
  24. * $page_banner_is_link true or false. If true, the banner at the top will load FP in a
  25. * new window.
  26. * $page_extra_js_settings These are variable definitions set by other modules, using the fp_add_js() command.
  27. * $page_extra_css_files These are extra CSS files which other modules wish to include, using fp_add_css().
  28. * $page_extra_js_files Similar to extra_css files, but for extra javascript files.
  29. * $page_body_classes A string containing the CSS classes (space-separated) which should go on the body element.
  30. *
  31. **/
  32. $theme_location = fp_theme_location();
  33. // If this page is a popup, let's add that information to the body_classes.
  34. if ($page_is_popup) {
  35. $page_body_classes .= " page-is-popup ";
  36. }
  37. ?>
  38. <html>
  39. <head>
  40. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  41. <meta name="viewport" content="width=device-width" />
  42. <script src="<?php print base_path() ?>/inc/jquery-1.8.3.min.js" type="text/javascript"></script>
  43. <script src="<?php print base_path() ?>/inc/jquery-ui-1.9.2.custom.min.js" type="text/javascript"></script>
  44. <link rel='stylesheet' type='text/css' href='<?php print base_path() ?>/inc/jqueryui-css/ui-lightness/jquery-ui-1.9.2.custom.min.css' />
  45. <script type='text/javascript'>
  46. <?php print $page_extra_js_settings; ?>
  47. // perform any requested actions on page load...
  48. $(document).ready(function() { <?php print $page_on_load; ?> });
  49. </script>
  50. <?php
  51. // Add extra JS files.
  52. print $page_extra_js_files;
  53. // Load this theme's CSS file(s)
  54. print "<link rel='stylesheet' type='text/css' href='$theme_location/style.css?$page_css_js_query_string' /> \n";
  55. print "<link rel='stylesheet' type='text/css' href='$theme_location/layout.css?$page_css_js_query_string' /> \n";
  56. // Load any extra CSS files which addon modules might have added.
  57. print $page_extra_css_files;
  58. // Load the custom.css file for this theme...
  59. print "<link rel='stylesheet' type='text/css' href='$theme_location/custom.css?$page_css_js_query_string' /> \n";
  60. ?>
  61. <link rel="shortcut icon" href="favicon.ico" type="image/x-icon" />
  62. <title><?php print $page_title; ?></title>
  63. </head>
  64. <body class='<?php print $page_body_classes; ?>'>
  65. <div class='top-banner'>
  66. <?php
  67. // ***************** Header Content *****************
  68. // ***************** *****************
  69. if (@$page_banner_is_link == TRUE) {
  70. print "<a href='{$GLOBALS["fp_system_settings"]["self_url"]}' target='_blank'>";
  71. }
  72. ?><img src='<?php print "$theme_location/images/"; ?>fp_banner_default.png' border='0'><?php
  73. if (@$page_banner_is_link == TRUE) {
  74. print "</a>";
  75. }
  76. ?>
  77. </div>
  78. <!-- Page tabs and search -->
  79. <table class='tabs-search-table'>
  80. <tr>
  81. <!-- ********** The tabs td ************-->
  82. <td class='tabs-td'>
  83. <table class='tabs-table-tabs'>
  84. <tr>
  85. <td align="left">
  86. <?php print $page_tabs; ?>
  87. </td>
  88. </tr>
  89. </table>
  90. </td>
  91. <!-- The possible search bar td -->
  92. <td class='search-td'>
  93. <?php
  94. // Insert a search bar if there is one.
  95. if ($page_has_search == TRUE && function_exists("student_search_menu")) {
  96. print student_search_render_small_search();
  97. }
  98. ?>
  99. </td>
  100. </tr>
  101. </table>
  102. <!-- Page content -->
  103. <div class='page-content'>
  104. <?php
  105. // ***************** Page specific content will be in here *****************
  106. print $page_content;
  107. // ***************** Page specific content was in here *****************
  108. ?>
  109. </div>
  110. <?php
  111. //------------------------------------------------
  112. // ------- MSG AT BOTTOM -------------------------
  113. //------------------------------------------------
  114. ?>
  115. <div class='fp-bottom-message'>
  116. <span class='popup-contact'>
  117. <?php
  118. if ($page_hide_report_error != TRUE) {
  119. print "<a class='nounderline' href='javascript: popupreportcontact()'>" . t("Contact the @FlightPath production team", array("@FlightPath" => variable_get("system_name", "FlightPath"))) . "</a>";
  120. }
  121. ?>
  122. </span>
  123. <!-- Optional copyright message could go here.
  124. <span>&copy; Date, Institution, etc.</span> -->
  125. </div>
  126. </body>
  127. </html>