Changeset - 2a9e1c9634e5
[Not reviewed]
Merge default
1 5 3
ethanzonca - 15 years ago 2010-10-02 23:06:07

Merge
9 files changed with 334 insertions and 162 deletions:
0 comments (0 inline, 0 general)
.hgignore
Show inline comments
 
new file 100644
 
style: regex
 

	
 
# ignore all saved schedules, but keep track of the .keep file.
 
^saved_schedules/[^.]
 

	
 
# ignore common unwanted suffixes
 
(~|\.orig|\.rej)$
class.schedule.php
Show inline comments
 
@@ -22,6 +22,12 @@ class Schedule
 
  private $storage;				// Integer array of valid schedules
 
  private $title;
 
  /**
 
   * \brief
 
   *   My global identification number. Not defined until the schedule
 
   *   is processed and first saved.
 
   */
 
  private $id;
 
  /**
 
   * The input format of the sections. Only used for the UI. Valid
 
   * values are 'numerous' for custom, 'numbered' for numeric, and 'lettered' for
 
   * alphabetical.
 
@@ -117,13 +123,16 @@ class Schedule
 
    do
 
      {
 
	$conflict = false;
 
	$upCounter = 0;
 
         
 
	// Get first class to compare
 
	while($upCounter < $this->nclasses)
 
	for ($upCounter = 0;
 
	     $upCounter < $this->nclasses && !$conflict;
 
	     $upCounter ++)
 
	  {
 
	    $downCounter = $this->nclasses-1;
 
	    while($downCounter > $upCounter)
 
	    
 
	    for ($downCounter = $this->nclasses - 1;
 
		 $downCounter > $upCounter && !$conflict;
 
		 $downCounter --)
 
	      {
 
		$start1 = $this->classStorage[$upCounter]->getSection($cs[$upCounter])->getStartTime();
 
		$end1 = $this->classStorage[$upCounter]->getSection($cs[$upCounter])->getEndTime();
 
@@ -131,43 +140,49 @@ class Schedule
 
		$end2 = $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getEndTime();
 
					
 
		// If the two times overlap, then check if days overlap.
 
		if(!$conflict && ((($start1 >= $start2) && ($start1 <= $end2)) || (($start2 >= $start1) && ($start2 <= $end1))))
 
		if ((($start1 >= $start2) && ($start1 <= $end2)) || (($start2 >= $start1) && ($start2 <= $end1)))
 
		  {
 
		    // Monday
 
		    if(!$conflict && ($this->classStorage[$upCounter]->getSection($cs[$upCounter])->getM() == $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getM()))
 
		    if(!$conflict
 
		       && ($this->classStorage[$upCounter]->getSection($cs[$upCounter])->getM()
 
			   && $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getM()))
 
		      {
 
			$conflict = true;
 
			$conflict = TRUE;
 
		      }
 
						
 
		    // Tuesday
 
		    if(!$conflict && ($this->classStorage[$upCounter]->getSection($cs[$upCounter])->getTu() == $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getTu()))
 
		    if(!$conflict
 
		       && ($this->classStorage[$upCounter]->getSection($cs[$upCounter])->getTu()
 
			   && $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getTu()))
 
		      {
 
			$conflict = true;
 
			$conflict = TRUE;
 
		      }
 
						
 
		    // Wednesday
 
		    if(!$conflict && ($this->classStorage[$upCounter]->getSection($cs[$upCounter])->getW() == $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getW()))
 
		    if(!$conflict
 
		       && ($this->classStorage[$upCounter]->getSection($cs[$upCounter])->getW()
 
			   && $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getW()))
 
		      {
 
			$conflict = true;
 
			$conflict = TRUE;
 
		      }
 
						
 
		    // Thursday
 
		    if(!$conflict && ($this->classStorage[$upCounter]->getSection($cs[$upCounter])->getTh() == $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getTh()))
 
		    if(!$conflict
 
		       && ($this->classStorage[$upCounter]->getSection($cs[$upCounter])->getTh()
 
			   && $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getTh()))
 
		      {
 
			$conflict = true;
 
			$conflict = TRUE;
 
		      }
 
						
 
		    // Friday
 
		    if(!$conflict && ($this->classStorage[$upCounter]->getSection($cs[$upCounter])->getF() == $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getF()))
 
		    if(!$conflict
 
		       && ($this->classStorage[$upCounter]->getSection($cs[$upCounter])->getF()
 
			   && $this->classStorage[$downCounter]->getSection($cs[$downCounter])->getF()))
 
		      {
 
			$conflict = true;
 
			$conflict = TRUE;
 
		      }
 
		  }
 
               
 
		$downCounter--;
 
	      }
 
				
 
	    $upCounter++;
 
	  }
 
            
 
	// Store to storage if no conflict is found.
 
@@ -300,11 +315,11 @@ class Schedule
 
      echo '});'; /* Close document.ready */
 
      echo 'window.print();
 
			      </script>';
 
      echo '<p><span id="selectItems"><a href="#">Select Schedules to Print</a></span> :: <a href="'.$_SERVER["SCRIPT_NAME"].'?savedkey=0">Return to normal view</a> :: <a href="input.php">Home</a></p>';
 
      echo '<div  id="selectItemsInput"><p><form action="'.$_SERVER["SCRIPT_NAME"].'?savedkey=0"><label><strong>Schedules to Print</strong> <em>(seperate with commas, "all" for all)</em></label><br /><input type="text" name="print" value="'.$_REQUEST['print'].'" /><input type="submit" value="submit" /><span id="cancelItems"><input type="button" value="cancel" /></span></form></p></div>';
 
      echo '<p><span id="selectItems"><a href="#">Select Schedules to Print</a></span> :: <a href="'.$_SERVER['SCRIPT_NAME'].'?s=' . $this->id_get() . '">Return to normal view</a> :: <a href="input.php">Home</a></p>';
 
      echo '<div  id="selectItemsInput"><p><form action="'.$_SERVER["SCRIPT_NAME"].'?s=' . $this->id_get() . '"><label><strong>Schedules to Print</strong> <em>(seperate with commas, "all" for all)</em></label><br /><input type="text" name="print" value="'.$_REQUEST['print'].'" /><input type="submit" value="submit" /><span id="cancelItems"><input type="button" value="cancel" /></span></form></p></div>';
 
    }
 
    else {
 
      echo '<p><a href="'.$_SERVER["SCRIPT_NAME"].'?savedkey=0&amp;print=all">Print</a> :: <a href="input.php">Home</a></p>';
 
      echo '<p><a href="'.$_SERVER["SCRIPT_NAME"].'?s=' . $this->id_get() . '&amp;print=all">Print</a> :: <a href="input.php">Home</a></p>';
 
    }		
 

	
 
    if($this->nPermutations > 0)
 
@@ -575,18 +590,7 @@ class Schedule
 
    }
 

	
 
    /* edit button */
 
    if (!isset($savedkey))
 
      {
 
	if (isset($_REQUEST['savedkey']))
 
	  $savedkey = (int)$_REQUEST['savedkey'];
 
	else
 
	  /*
 
	   * if this is a new saved schedule, it'll be the
 
	   * next item added to $_SESSION['saved']
 
	   */
 
	  $savedkey = max(array_keys($_SESSION['saved'])) + 1;
 
      }
 
    echo '<form method="get" action="input.php"><p><input type="hidden" name="savedkey" value="' . $savedkey . '" /><input type="submit" value="edit" /></p></form>';
 
    echo '<form method="get" action="input.php"><p><input type="hidden" name="s" value="' . $this->id_get() . '" /><input type="submit" value="edit" /></p></form>';
 

	
 
    echo "<p>There were a total of " . $this->possiblePermutations . " possible permutations. Only " . $this->nPermutations . " permutations had no class conflicts.</p>";
 

	
 
@@ -649,4 +653,24 @@ class Schedule
 
  {
 
    return $this->classStorage[$class_key];
 
  }
 

	
 
  /**
 
   * \brief
 
   *   Set my global ID.
 
   *
 
   * Only to be called by schedule_store_store().
 
   */
 
  function id_set($id)
 
  { 
 
    $this->id = $id;
 
  }
 

	
 
  /*
 
   * \brief
 
   *   Get my global ID.
 
   */
 
  function id_get()
 
  {
 
    return $this->id;
 
  }
 
}
class.section.php
Show inline comments
 
@@ -28,7 +28,7 @@ class Section
 

	
 
  function setbdays()
 
  {
 
    $result;
 
    $result = array(FALSE, FALSE, FALSE, FALSE, FALSE);
 

	
 
    if($this->idays == 12345)
 
      {$result[0] = true; $result[1] = true; $result[2] = true; $result[3] = true; $result[4] = true;}
 
@@ -181,7 +181,6 @@ class Section
 
      . '    <select class="selectRequired" name="postData[' . $class_key . '][' . $section_key . '][start]">' . $n;
 
    for ($h = 7; $h <= 21; $h ++)
 
      {
 
	$val = $h . '00';
 
	$nm = 'p';
 
	$hr = $h;
 
	if ($h < 12)
 
@@ -191,8 +190,14 @@ class Section
 

	
 
	foreach (array('00', '30') as $m)
 
	  {
 
	    $val = $h . $m;
 

	
 
	    $selected = '';
 
	    if ($this->start == $val)
 
	      $selected = ' selected="selected"';
 

	
 
	    $label = $hr . ':' . $m . $nm . 'm';
 
	    $out .= '      <option value="' . $val . '">' . $label . '</option>' . $n;
 
	    $out .= '      <option value="' . $val . '"' . $selected . '>' . $label . '</option>' . $n;
 
	  }
 
      }
 
    $out .= "    </select>\n"
 
@@ -203,7 +208,6 @@ class Section
 
      . '    <select class="selectRequired" name="postData[' . $class_key . '][' . $section_key . '][end]">' . $n;
 
    for ($h = 7; $h <= 21; $h ++)
 
      {
 
	$val = $h . '00';
 
	$nm = 'p';
 
	$hr = $h;
 
	if ($h < 12)
 
@@ -213,8 +217,14 @@ class Section
 

	
 
	foreach (array('20', '50') as $m)
 
	  {
 
	    $val = $h . $m;
 

	
 
	    $selected = '';
 
	    if ($this->tend == $val)
 
	      $selected = ' selected="selected"';
 

	
 
	    $label = $hr . ':' . $m . $nm . 'm';
 
	    $out .= '      <option value="' . $val . '">' . $label . '</option>' . $n;
 
	    $out .= '      <option value="' . $val . '"' . $selected . '>' . $label . '</option>' . $n;
 
	  }
 
      }
 
    $out .= "    </select>\n"
 
@@ -228,7 +238,7 @@ class Section
 
	  $day_enabled = '';
 
	$out .= "  <td>\n"
 
	  . '    <input type="checkbox" class="daysRequired"'
 
	  . '           name="postData[' . $class_key . '][' . $section_key . '][days][' . $day_key . ']" ' . $day_enabled . ' />' . $n
 
	  . '           name="postData[' . $class_key . '][' . $section_key . '][days][' . $day_key . ']" value="1" ' . $day_enabled . ' />' . $n
 
	  . "  </td>\n";
 
      }
 

	
inc/class.page.php
Show inline comments
 
<?php
 

	
 
/* Class for general page generation */
 
class page {
 

	
 
class page
 
{
 
  private $base_title = 'SlatePermutate';
 
  private $doctype = 'html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"';
 
  private $htmlargs = 'xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"';
 
@@ -141,20 +141,48 @@ class page {
 
      return $ret;
 
  }
 

	
 
  public function showSavedScheds($session) {
 
       echo '<p>';
 
	if(isset($session['saved']) && count($session['saved']) > 0){
 
		echo '<div id="savedBox" ><h3>Saved Schedules:</h3>';
 
		foreach($session['saved'] as $key => $schedule){
 
			$sch = unserialize($schedule);
 
			echo "#" . ($key + 1) . " - " . $sch->getName()
 
			  . " - <a href=\"process.php?savedkey=$key\">view</a>" .' <a href="input.php?savedkey=' . $key . '">edit</a> '
 
			  . "<a href=\"process.php?delsaved=$key\">delete</a>"
 
			  . "<br /><br />\n";
 
		}
 
		echo '</div>';
 
	}
 
       echo '</p>';
 
  public function showSavedScheds($session)
 
  {
 
    echo '<p>';
 
    if (isset($session['saved']) && count($session['saved']) > 0)
 
      {
 
	echo '<div id="savedBox" ><h3>Saved Schedules:</h3>';
 
	foreach($session['saved'] as $key => $name)
 
	  {
 
	    echo '<a href="process.php?s=' . $key . '" title="View schedule #' . $key . '">#' . $key . "</a>:\n "
 
	      . htmlentities($name)
 
	      . ' <a href="input.php?s=' . $key . '">edit</a>'
 
	      . ' <a href="process.php?del=' . $key . '">delete</a>'
 
	      . "<br /><br />\n";
 
	  }
 
	echo '</div>';
 
      }
 
    echo '</p>';
 
  }
 

	
 
  /**
 
   * \brief
 
   *   Display a 404 page and halt the PHP interpreter.
 
   *
 
   * This function does not return. It handles the creation of a Page
 
   * class with 404-ish stuff and then calls exit() after flushing the
 
   * page out to the user.
 
   *
 
   * \param $message
 
   *   A message consisting of valid XHTML to display to the user in
 
   *   the 404 page.
 
   */
 
  public static function show_404($message = 'I couldn\'t find what you were looking for :-/.')
 
  {
 
    $page_404 = new Page('404: Content Not Found');
 

	
 
    echo "<h2>404: Content Not Found</h2>\n"
 
      . "<p>\n"
 
      . '  ' . $message . "\n"
 
      . "</p>\n";
 

	
 
    $page_404->foot();
 

	
 
    exit();
 
  }
 
}
 

	
 
}
inc/schedule_store.inc
Show inline comments
 
new file 100644
 
<?php
 
/*
 
 * Copyright 2010 Nathan Phillip Brink <ohnobinki@ohnopublishing.net>
 
 *
 
 * This file is a part of slate_permutate.
 
 *
 
 * slate_permutate is free software: you can redistribute it and/or modify
 
 * it under the terms of the GNU Affero General Public License as published by
 
 * the Free Software Foundation, either version 3 of the License, or
 
 * (at your option) any later version.
 
 *
 
 * slate_permutate is distributed in the hope that it will be useful,
 
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
 * GNU Affero General Public License for more details.
 
 *
 
 * You should have received a copy of the GNU Affero General Public License
 
 * along with slate_permutate.  If not, see <http://www.gnu.org/licenses/>.
 
 */
 

	
 
require_once('class.schedule.php');
 

	
 
/**
 
 * \brief
 
 *   Initialize a schedule_store.
 
 *
 
 * \param $dir
 
 *   Directory to use as the schedule storage.
 
 * \return
 
 *   A schedule_store handle or NULL on failure.
 
 */
 
function schedule_store_init($dir = 'saved_schedules')
 
{
 
  $schedule_store = array();
 

	
 
  if (!is_dir($dir) || !is_writable($dir))
 
    {
 
      error_log('I can\'t write to ' . $dir . ' or it is not a directory!');
 
      return NULL;
 
    }
 

	
 
  $schedule_store['dir'] = realpath($dir);
 

	
 
  return $schedule_store;
 
}
 

	
 
/**
 
 * \brief
 
 *   Store a saved schedule into the schedule storage.
 
 *
 
 * \param $schedule_store
 
 *   The schedule_store handle from schedule_store_init().
 
 * \param $schedule
 
 *   The schedule object of type Schedule.
 
 * \return
 
 *   The newly-saved schedules global ID (numeric) or NULL on error.
 
 */
 
function schedule_store_store($schedule_store, $schedule)
 
{
 
  $tempfile_name = tempnam($schedule_store['dir'], 'sch');
 

	
 
  $new_schedule_id_name = tempnam($schedule_store['dir'], 'id');
 
  $new_schedule_id_file = fopen($new_schedule_id_name, 'wb');
 

	
 
  _schedule_store_flock_grab($schedule_store, LOCK_EX);
 
  /* if the file doesn't exist, we'll end up with a value of 1 for our first entry. */
 
  $schedule_id = (int)file_get_contents($schedule_store['dir'] . DIRECTORY_SEPARATOR . 'lastid');
 
  $new_schedule_id = $schedule_id + 1;
 
  fwrite($new_schedule_id_file, $new_schedule_id);
 
  fclose($new_schedule_id_file);
 
  rename($new_schedule_id_name, $schedule_store['dir'] . DIRECTORY_SEPARATOR . 'lastid');
 
  _schedule_store_flock_release($schedule_store);
 

	
 
  /* we need to serialize the schedule _after_ giving it an ID */
 
  $schedule->id_set($new_schedule_id);
 
  file_put_contents($tempfile_name, serialize($schedule));
 

	
 
  rename($tempfile_name, $schedule_store['dir'] . DIRECTORY_SEPARATOR . $new_schedule_id);
 

	
 
  return $new_schedule_id;
 
}
 

	
 
/**
 
 * \brief
 
 *   Retrieve a stored saved schedule from the schedule storage.
 
 *
 
 * \param $schedule_store
 
 *   The schedule_store handle from which to retrieve the saved
 
 *   schedule.
 
 * \param $schedule_id
 
 *   The saved schedule's globally-accessible ID. This value must have
 
 *   been returned from schedule_store_store() at one point.
 
 * \return
 
 *   A Schedule object whose ID was $schedule_id or NULL if
 
 *   $schedule_id is an invalid or not-yet-allocated schedule
 
 *   identifier.
 
 */
 
function schedule_store_retrieve($schedule_store, $schedule_id)
 
{
 
  if (strcmp($schedule_id, (int)$schedule_id))
 
    return NULL;
 
  $schedule_id = (int)$schedule_id;
 

	
 
  $schedule_serialized = file_get_contents($schedule_store['dir'] . DIRECTORY_SEPARATOR . $schedule_id);
 
  if ($schedule_serialized === FALSE)
 
    return NULL;
 

	
 
  $schedule = unserialize($schedule_serialized);
 
  if ($schedule === FALSE)
 
    return NULL;
 
  return $schedule;
 
}
 

	
 
/**
 
 * \brief
 
 *   Delete a saved schedule.
 
 *
 
 * \param $schedule_store
 
 *   The store from which to delete the schedule.
 
 * \param $schedule_id
 
 *   The identifier of the schedule to delete.
 
 */
 
function schedule_store_delete($schedule_store, $schedule_id)
 
{
 
  $remove_filename = $schedule_store['dir'] . DIRECTORY_SEPARATOR . $schedule_id;
 
  /* avoid an E_WARNING if the file doesn't exist */
 
  if (file_exists($remove_filename))
 
    unlink($remove_filename);
 
}
 

	
 
/**
 
 * \brief
 
 *   Obtains a lock on the /lastid file in the schedule_store.
 
 *
 
 * \see _schedule_store_flock_release().
 
 *
 
 * \param $schedule_store
 
 *   The schedule_store instance we're working with.
 
 * \param $operation
 
 *   Which flock() operation to perform: valid are LOCK_SH and LOCK_EX.
 
 */
 
function _schedule_store_flock_grab(&$schedule_store, $operation)
 
{
 
  $schedule_store['lastid_flock_file'] = fopen($schedule_store['dir'] . DIRECTORY_SEPARATOR . 'lastid.flock', 'c');
 
  return flock($schedule_store['lastid_flock_file'], $operation);
 
}
 

	
 
/**
 
 * \brief
 
 *   Release a lock grabbed with _schedule_store_flock_grab().
 
 */
 
function _schedule_store_flock_release(&$schedule_store)
 
{
 
  flock($schedule_store['lastid_flock_file'], LOCK_UN);
 
  fclose($schedule_store['lastid_flock_file']);
 
  unset($schedule_store['lastid_flock_file']);
 
}
input.php
Show inline comments
 
@@ -4,18 +4,18 @@ include_once 'class.schedule.php';
 
include_once 'class.class.php';
 
include_once 'class.section.php';
 
include_once 'inc/class.page.php';
 
require_once('inc/schedule_store.inc');
 

	
 
$scripts = array('jQuery', 'jQueryUI', 'jValidate','schedInput');
 
$inputPage = new page('Scheduler', $scripts, FALSE);
 

	
 
$schedule_store = FALSE;
 
$sch = FALSE;
 
if (isset($_REQUEST['savedkey']) && isset($_SESSION['saved']))
 
if (isset($_REQUEST['s']))
 
  {
 
    $savedkey = (int)$_REQUEST['savedkey'];
 
    if (isset($_SESSION['saved'][$savedkey]))
 
      {
 
	$sch = unserialize($_SESSION['saved'][$savedkey]);
 
      }
 
    $schedule_store = schedule_store_init();
 
    $schedule_id = (int)$_REQUEST['s'];
 
    $sch = schedule_store_retrieve($schedule_store, $schedule_id);
 
  }
 

	
 
if ($sch)
process.php
Show inline comments
 
@@ -2,6 +2,8 @@
 

	
 
session_start();
 

	
 
require_once('inc/schedule_store.inc');
 
require_once('inc/class.page.php');
 
include_once 'class.schedule.php';
 
include_once 'class.class.php';
 
include_once 'class.section.php';
 
@@ -55,23 +57,36 @@ function prettyTime($time){
 
	return substr($time,0,strlen($time)-2) . ":" . substr($time,strlen($time)-2, strlen($time));
 
}
 

	
 
$DEBUG = false;
 
if(isset($_GET['debug']))
 
	$DEBUG = $_GET['debug'];
 
$DEBUG = FALSE;
 
if (isset($_GET['debug']))
 
  $DEBUG = $_GET['debug'];
 

	
 
if(!$DEBUG){
 
$schedule_store = schedule_store_init();
 

	
 
	if(isset($_GET['savedkey'])){
 
		$savedSched = unserialize($_SESSION['saved'][$_GET['savedkey']]);
 
		$savedSched->writeoutTables();
 
	}
 
	else if(isset($_GET['delsaved'])){
 
		$_SESSION['saved'][$_GET['delsaved']] = '';
 
		$_SESSION['saved'] = array_filter($_SESSION['saved']); // Remove null entries
 
              header( 'Location: input.php' ) ;
 
if(!$DEBUG)
 
  {
 
    if(isset($_GET['s']))
 
      {
 
	$savedSched = schedule_store_retrieve($schedule_store, $_GET['s']);
 
	if ($savedSched)
 
	  $savedSched->writeoutTables();
 
	else
 
	  Page::show_404('Unable to find a saved schedule with an ID of ' . $_GET['s'] . '.');
 
      }
 
    elseif(isset($_GET['del']))
 
      {
 
	/* Allow the user to delete schedules that he has stored in his session */
 
	if ($_SESSION['saved'][(int)$_GET['del']])
 
	  {
 
	    /* user owns this schedule ID */
 
	    schedule_store_delete($schedule_store, (int)$_GET['del']);
 
	    unset($_SESSION['saved'][(int)$_GET['del']]);
 
	  }
 

	
 
	}
 
	else{
 
	header('Location: input.php');
 
      }
 
    else
 
      {
 
		$allClasses = new Schedule($_POST['postData']['name']);
 
	
 
		foreach(sortInputs($_POST) as $class)
 
@@ -95,14 +110,22 @@ if(!$DEBUG){
 
			}
 
		}
 
		$allClasses->findPossibilities();
 
		if (!isset($_SESSION['saved']))
 
		  $_SESSION['saved'] = array();
 
		$schedule_id = schedule_store_store($schedule_store, $allClasses);
 
		if ($schedule_id != NULL)
 
		  $_SESSION['saved'][$schedule_id] = $allClasses->getName();
 

	
 
		/*
 
		 * writeoutTables() needs to know $schedule_id, so it
 
		 * has to be called after we save the schedule. See
 
		 * schedule_store_store().
 
		 */
 
		$allClasses->writeoutTables();
 
		if(!isset($_SESSION['saved']))
 
			$_SESSION['saved'] = array();
 
		array_push ( $_SESSION['saved'], serialize($allClasses));
 
	}
 
} else {
 

	
 

	
 
      }
 
  }
 
else
 
  {
 
	echo '<pre>DEBUG OUTPUT: <br /><br />';
 
	foreach(sortInputs($_POST) as $class) {
 
		echo 'Class: ' . $class['name'] . '<br />';
saved_schedules/.keep
Show inline comments
 
new file 100644
somejavacode.php
Show inline comments
 
deleted file
0 comments (0 inline, 0 general)