# HG changeset patch
# User ethanzonca
# Date 2010-07-10 01:16:24
# Node ID fcd0768aa12da9503bd5c0ac9a8a799f125dd20c
# Parent  f13987338fbfabea1cf8d02461517cb71266343a
Added nicer defaulttext implementation. jQuery doesn't support .live blur though, so it won't work for new sections. Workaround?
diff --git a/input.php b/input.php
--- a/input.php
+++ b/input.php
@@ -17,6 +17,12 @@ include_once 'class.section.php';
 		margin:auto;
 		font-family: sans-serif;
 	}
+	.defaultText { 
+		width: 300px; }
+	.defaultTextActive { 
+		color: #a1a1a1; 
+		font-style: italic; 
+	}
 	#savedBox {
 		width: 15em;
 		padding: 1em;
@@ -190,7 +196,7 @@ include_once 'class.section.php';
 	//--------------------------------------------------
 	function addRow(){
 		sectionsOfClass[classNum] = 0; // This is class 0, initialize at 0
-		jQuery('#jsrows').append('
 | ' + getCommonInputs(classNum) + ' |  | 
');
+		jQuery('#jsrows').append(' | ' + getCommonInputs(classNum) + ' |  | 
');
 		classNum++;
 	};
 	
@@ -234,9 +240,26 @@ include_once 'class.section.php';
 		jQuery('#scheduleForm').resetForm();
     });
 
-	jQuery('#scheduleName').hover(function() {
-		jQuery(this).val('');
-	});
+	//--------------------------------------------------
+	// Default text stuff
+	//--------------------------------------------------
+    jQuery(".defText").focus(function(srcc)
+    {
+        if (jQuery(this).val() == jQuery(this)[0].title)
+        {
+            jQuery(this).removeClass("defaultTextActive");
+            jQuery(this).val("");
+        }
+    });
+    jQuery(".defText").blur(function()
+    {
+        if (jQuery(this).val() == "")
+        {
+            jQuery(this).addClass("defaultTextActive");
+            jQuery(this).val($(this)[0].title);
+        }
+    });
+    jQuery(".defText").blur();    
 
 });
 
@@ -274,7 +297,7 @@ if(isset($_SESSION['saved']) && count($_