Changeset - cca88ad00317
[Not reviewed]
default
0 5 0
Ethan Zonca - 15 years ago 2010-10-27 19:37:31
ez@ethanzonca.com
Added synonym support. Still needs to be fixed in crawlers. Show professor by default. Show IE message only to IE users.
5 files changed with 9 insertions and 3 deletions:
0 comments (0 inline, 0 general)
class.schedule.php
Show inline comments
 
@@ -252,8 +252,9 @@ class Schedule
 
    echo '<div id="show-box" class="gray righttext" style="float: right; padding-right: 5pt; padding-bottom: 7pt">
 
  <form>
 
     <h3>Display</h3>
 
     <div style="text-align:left;"><input id="show-prof" name="show-prof" type="checkbox" /><label for="show-prof">Professor</label></div>
 
     <div style="text-align:left;"><input id="show-prof" name="show-prof" type="checkbox" checked="checked" /><label for="show-prof">Professor</label></div>
 
     <div style="text-align:left;"><input id="show-location" name="show-location" type="checkbox" /><label for="show-location">Room</label></div>
 
     <div style="text-align:left;"><input id="show-synonym" name="show-synonym" type="checkbox" /><label for="show-synonym">Synonym</label></div>
 
  </form>
 
  </div> <!-- id="details" -->';
 

	
 
@@ -340,6 +341,7 @@ class Schedule
 
					. htmlentities($section->getLetter(), ENT_QUOTES) . "\n"
 
					. '<span class="prof block">' . htmlentities($section->getProf(), ENT_QUOTES) . "</span>\n"
 
					. '<span class="location block">' . htmlentities($current_meeting->getLocation(), ENT_QUOTES) . "</span>\n"
 
					. '<span class="synonym block">' . htmlentities($section->getSynonym(), ENT_QUOTES) . "</span>\n"
 
					. "</td>\n";
 
				      $filled = TRUE;
 
				    }
class.section.php
Show inline comments
 
@@ -47,6 +47,8 @@ class Section
 

	
 
    $this->meetings = $section_meetings;
 

	
 
    $this->synonym = $synonym;
 

	
 
    $this->prof = $prof;
 
  }
 

	
input.php
Show inline comments
 
@@ -82,9 +82,11 @@ if (!empty($_REQUEST['selectschool'])
 
  FALSE); ?>! To get started, enter in some of your
 
  class IDs, and click the autosuggestion to add available sections for each class.
 
</p>
 
<!--[if IE]>
 
<p>
 
  Note: The auto-complete function does not work in <b>Internet Explorer</b>.
 
</p>
 
<![endif]-->
 
<form method="post" action="process.php" id="scheduleForm">
 
<br />
 
<label>Schedule Name</label><br />
process.php
Show inline comments
 
@@ -121,7 +121,7 @@ if(!$DEBUG)
 
				  /* Skip the section name, which isn't a section */
 
					if(is_array($section))
 
					{
 
					  $allClasses->addSection($class['name'], $section['letter'], $section['start'], $section['end'], arrayToDays($section['days'], 'alpha'), NULL, $section['professor'], $section['location']);
 
					  $allClasses->addSection($class['name'], $section['letter'], $section['start'], $section['end'], arrayToDays($section['days'], 'alpha'), $section['synonym'], $section['professor'], $section['location']);
 
					}
 
			}
 
		}
scripts/scheduleInput.js
Show inline comments
 
@@ -83,7 +83,7 @@ function genSectionHtml_n(cnum, name, sy
 
		var snum = sectionsOfClass[cnum];
 

	
 
		var result = '<tr class="section class' + cnum + '"><td class="none"></td>';
 
	        result = result + '<td class="sectionIdentifier center"><input type="hidden" name="postData[' + cnum + '][' + snum + '][synonym]" value="' + synonym + '" /><input type="text" size="1" class="required" name="postData[' + cnum + '][' + snum + '][letter]" value="' + name + '" /></td>';
 
	        result = result + '<td class="sectionIdentifier center"><input type="text" name="postData[' + cnum + '][' + snum + '][synonym]" value="' + synonym + '" /><input type="text" size="1" class="required" name="postData[' + cnum + '][' + snum + '][letter]" value="' + name + '" /></td>';
 
		result = result + '<td class="professor center"><input type="text" size="10" class="" name="postData[' + cnum + ']['+ snum + '][professor]" value="' + prof + '" /></td>';
 
		result = result + '<td><select class="selectRequired" name="postData[' + cnum + '][' + snum + '][start]"><option value="none"></option>'
 
				 + genOptionHtml("0700", "7:00 am", stime) + genOptionHtml("0730", "7:30 am", stime)
0 comments (0 inline, 0 general)