Changeset - a569f5a9e624
[Not reviewed]
default
0 4 0
Nathan Brink (binki) - 14 years ago 2011-04-06 00:23:09
ohnobinki@ohnopublishing.net
Add support for displaying a warning at the top of input.php.
4 files changed with 28 insertions and 0 deletions:
0 comments (0 inline, 0 general)
inc/class.page.php
Show inline comments
 
@@ -47,6 +47,7 @@ set_include_path(get_include_path() . PA
 
$use_captcha = FALSE;
 
$admin_enable_purge = FALSE;
 
$qtips_always = FALSE;
 
$input_warning_banner = FALSE;
 

	
 
$config_inc = dirname(__FILE__) . DIRECTORY_SEPARATOR . 'config.inc';
 
if (file_exists($config_inc)) {
inc/config.inc.example
Show inline comments
 
@@ -134,3 +134,17 @@
 
 */
 
/* $feedback_disk_log = TRUE; */
 
/* $feedback_disk_log_file = "/var/log/sp-feedback.log"; */
 

	
 

	
 
/**
 
 * \brief
 
 *   A banner to display to users on input.php for temporary warnings.
 
 *
 
 * Used to inform users about known data problems, etc.
 
 *
 
 * Set to a string to display a banner. Otherwise, set to FALSE to
 
 * hide the banner. Must be a valid XHTML fragment which may be placed
 
 * into a <div /> verbatim.
 
 */
 
/* $input_warning_banner = FALSE; */
 
/* $input_warning_banner = '<p>Warning: BIOL-111\'s autocomplete data does not include all sections. Please use <a href="http://csx.calvin.edu/sp/input.php?s=7578">schedule 7578</a> to get a correct BIOL-111 entry.</p>'; */
input.php
Show inline comments
 
@@ -156,6 +156,13 @@ if (!empty($_REQUEST['selectsemester']))
 

	
 
$inputPage->showSavedScheds($_SESSION);
 
?>
 

	
 
<?php if (!empty($input_warning_banner)): ?>
 
<div class="warning">
 
  <?php echo $input_warning_banner; ?>
 
</div>
 
<?php endif; ?>
 

	
 
<p>
 
  Welcome to SlatePermutate<?php $inputPage->addressStudent(', ', '', FALSE); ?>!
 
  <?php if (school_has_auto($inputPage->get_school())): ?>
styles/general.css
Show inline comments
 
@@ -391,3 +391,9 @@ a:hover {
 
  border: none;
 
  background: transparent;
 
}
 

	
 
.warning
 
{
 
  background: #ffffdd;
 
  border: 1pt solid yellow;
 
}
0 comments (0 inline, 0 general)