Changeset - 90f2acce2d8a
[Not reviewed]
default
0 4 0
Ethan Zonca - 15 years ago 2011-01-27 19:07:54
ez@ethanzonca.com
Minor fixes
4 files changed with 20 insertions and 11 deletions:
0 comments (0 inline, 0 general)
inc/class.page.php
Show inline comments
 
@@ -57,25 +57,25 @@ if (file_exists($config_inc)) {
 

	
 
//**************************************************
 
// class.page.php   Author: Ethan Zonca
 
//
 
// Provides an interface for generating a styled
 
// XHTML page, supporting modular script inclusion
 
// and other various features
 
//**************************************************
 
class page
 
{
 

	
 
  /* Site-wide configuration options */
 
  private $base_title = 'SlatePermutate';
 
  private $base_title = 'SlatePermutate :: Find the schedule that works for you!';
 
  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"';
 
  private $bodyargs = '';
 

	
 

	
 
  public $lastJobTable = '';
 
  private $pageGenTime = 0;
 

	
 
  /* Whether or not to output valid XHTML */
 
  private $xhtml = FALSE;
 

	
 
  /* Scripts and styles */
inc/class.schedule.php
Show inline comments
 
@@ -290,30 +290,30 @@ class Schedule
 
      echo '<p class="centeredtext">Having problems? <a href="feedback.php">Let us know</a>.</p>';
 
      echo '<p class="centeredtext graytext"><em>Keyboard Shortcut: Left and right arrow keys switch between schedules</em></p>';
 
    }		
 

	
 
    echo "\n";
 

	
 
    if($this->nPermutations > 0)
 
      {
 

	
 
        echo '<div id="regDialog" title="Registration Codes"><p>Enter these codes into your school\'s online course registration system to register for classes:</p><div id="regDialogList"></div></div>';
 
	echo '<div id="tabs">' . "\n" .
 
               '<div id="show-box" class="show-buttons">
 
                  <form>
 
                  <form action="#"><p class="nospace">
 
                    <label><strong>Display:</strong></label>
 
                    <input id="show-prof" name="show-prof" type="checkbox" checked="checked" /><label for="show-prof">Professor</label>
 
                    <input id="show-location" name="show-location" type="checkbox" /><label for="show-location">Room</label>
 
                    <input id="show-synonym" name="show-synonym" type="checkbox" /><label for="show-synonym">Synonym</label>
 
                    <div id="regCodes"><label><a href="#">Registration Codes</a></label></div>
 
                    <span id="regCodes"><label><a href="#">Registration Codes</a></label></span></p>
 
                  </form>
 
                </div> <!-- id="show-box" -->'
 
	     . '<div id="the-tabs"><ul>' . "\n";
 
			
 
	for($nn = $first_permutation + 1; $nn <= $last_permutation; $nn++)
 
	  {
 
	    echo  "<li><a href=\"#tabs-" . $nn . "\">&nbsp;" . $nn . "&nbsp;</a></li>\n";
 
	  }
 
			
 
	echo "    </ul></div>\n  \n";
 

	
 
	echo "    <div id=\"pagers\">\n";
 
@@ -418,36 +418,36 @@ class Schedule
 
		  /* If the cell was not filled, fill it with an empty cell. */
 
			if(!$filled)
 
			{
 
				echo "            <td class=\"none\">&nbsp;</td>\n";
 
			}
 
			$filled = FALSE;
 
		}
 
		
 
		// End of row
 
		echo "          </tr>\n";
 
	      }
 

	
 
            echo '<div class="syns syns'.$i.'">'.  json_encode($syns) . '</div>';
 

	
 

	
 
	    // End of table
 
	    echo "        </table>\n"
 
              . '         <span class="syns syns'.$i.'">'.  json_encode($syns) . "</span>\n"
 
	      . '      </div> <!-- id="section' . ($i + 1) . "\" -->\n";
 
	  }
 

	
 
	echo $table
 
	  . "    </div> <!-- class=\"scontent\" -->\n"
 
	  . "  </div> <!-- class=\"scroller\" -->\n"
 
	  . "</div> <!-- id=\"my-glider\" -->\n"
 
	  . $footcloser; // Closes off the content div
 
          echo "    </div> <!-- class=\"scontent\" -->\n"
 
	     . "  </div> <!-- class=\"scroller\" -->\n"
 
	     . "</div> <!-- id=\"my-glider\" -->\n"
 
	     . $footcloser; // Closes off the content div
 
      } else {
 
      echo '<html><body><p>There are no possible schedules. Please try again.</p></body></html>';
 
    }
 

	
 
    /* edit button */
 
    if ($id = $this->id_get())
 
      echo '<form method="get" action="input.php"><p><input type="hidden" name="s" value="' . $id . '" /><input class="gray" id="editbutton" type="submit" value="edit" /></p></form>';
 

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

	
 
    $outputPage->foot();
 
  }
index.php
Show inline comments
 
@@ -14,17 +14,21 @@
 
 * 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 SlatePermutate.  If not, see <http://www.gnu.org/licenses/>.
 
 */
 

	
 
  include_once 'inc/class.page.php'; 
 
  $welcomepage = new page('Welcome');
 
?>
 

	
 
<h3>Find the schedule that works for you!</h3>
 
<p>View <a href="schedulecreator.php">demo output</a> or <a href="input.php">get started on your own</a>. This program was created by <a href="http://www.calvin.edu" rel="external">Calvin College</a> and <a href="http://cedarville.edu/" rel="external">Cedarville University</a> students. SlatePermutate works with any college or university.</p>
 
<p>Plan your next semester with SlatePermutate! SlatePermutate generates every possible schedule with the courses you enter to let you pick the schedule that fits your life.</p>
 
<p><!-- View <a href="schedulecreator.php">demo output</a> or --><a href="input.php">Get started</a></p> 
 

	
 

	
 
<p class="righttext"><a href="input.php"><img class="noborder" src="images/get-started.png" alt="Get Started" /></a></p>
 

	
 
<!-- <p style="color: #777; font-size: .7em;">This program was created by <a href="http://www.calvin.edu" rel="external">Calvin College</a> and <a href="http://cedarville.edu/" rel="external">Cedarville University</a> students. SlatePermutate works with any college or university.</p>
 
-->
 
<?php
 
$welcomepage->foot();
styles/general.css
Show inline comments
 
@@ -222,12 +222,17 @@ td.center {
 
  padding:0;
 
  margin:0;
 
}
 
.syns {
 
  display:none;
 
}
 
#regCodes {
 
  float: right;
 
}
 
.synList {
 
  margin-left: 1em;
 
}
 

	
 
.nospace {
 
  padding:0!important;
 
  margin:0!important;
 
}
0 comments (0 inline, 0 general)