Changeset:
        02451c91f114
        
https://sourceforge.net/p/mrbs/hg-code/ci/02451c91f1148d3262e43173d4097f77ec6dc0fb
Author:
        Campbell Morrison <[email protected]>
Date:
        Sun Mar 05 16:41:47 2017 +0000
Log message:

Restructured

diffstat:

 web/Themes/default/header.inc |  11 ++++++++---
 web/functions.inc             |   2 +-
 web/search.php                |   2 +-
 3 files changed, 10 insertions(+), 5 deletions(-)

diffs (60 lines):

diff -r 65b140aa769b -r 02451c91f114 web/Themes/default/header.inc
--- a/web/Themes/default/header.inc     Sun Mar 05 16:30:28 2017 +0000
+++ b/web/Themes/default/header.inc     Sun Mar 05 16:41:47 2017 +0000
@@ -125,8 +125,13 @@
 }
 
 
-function print_search($day, $month, $year, $area, $room, $search_str = '')
+function print_search($day, $month, $year, $area, $room, $search_str=null)
 {
+  if (!isset($search_str))
+  {
+    $search_str = '';
+  }
+  
   echo "<form id=\"header_search\" method=\"get\" action=\"search.php\">\n";
   echo "<div>\n";
   echo "<a href=\"search.php?advanced=1\">" . get_vocab("search") . ":</a>\n";
@@ -147,7 +152,7 @@
 }
 
 
-function print_nav($day, $month, $year, $area, $room, $search_str = '', 
$simple=false)
+function print_nav($day, $month, $year, $area, $room, $search_str=null, 
$simple=false)
 {
   $query_string = "day=$day&amp;month=$month&amp;year=$year";
   if (!empty($area))
@@ -205,7 +210,7 @@
 // Print the page header
 // If $simple is true, then just print a simple header that doesn't require 
any database
 // access or JavaScript (useful for fatal errors and database upgrades).
-function print_theme_header($day, $month, $year, $area, $room, $simple=false, 
$search_str='')
+function print_theme_header($day, $month, $year, $area, $room, $simple=false, 
$search_str=null)
 {
   // We want to prevent IE8 offering "Compatibility View" as that really
   // messes up MRBS, especially on the Report page
diff -r 65b140aa769b -r 02451c91f114 web/functions.inc
--- a/web/functions.inc Sun Mar 05 16:30:28 2017 +0000
+++ b/web/functions.inc Sun Mar 05 16:41:47 2017 +0000
@@ -175,7 +175,7 @@
 
 
 // Print the page header
-function print_header($day=null, $month=null, $year=null, $area=null, 
$room=null, $simple=false, $search_str='')
+function print_header($day=null, $month=null, $year=null, $area=null, 
$room=null, $simple=false, $search_str=null)
 {
   global $theme;
   
diff -r 65b140aa769b -r 02451c91f114 web/search.php
--- a/web/search.php    Sun Mar 05 16:30:28 2017 +0000
+++ b/web/search.php    Sun Mar 05 16:41:47 2017 +0000
@@ -174,7 +174,7 @@
     exit;
   }
 
-  if (!isset($search_str) || ($search_str == ''))
+  if (!isset($search_str) || ($search_str === ''))
   {
     echo "<p class=\"error\">" . get_vocab("invalid_search") . "</p>";
     output_trailer();

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Mrbs-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mrbs-commits

Reply via email to