diff --git a/system/libraries/Loader.php b/system/libraries/Loader.php
index 5db9886..41c0a9b 100644
--- a/system/libraries/Loader.php
+++ b/system/libraries/Loader.php
@@ -71,12 +71,25 @@
 	 * @param	mixed	the optional parameters
 	 * @return	void
 	 */	
-	function library($class, $params = NULL)
+	function library($library = '', $params = NULL)
 	{		
-		if ($class == '')
-			return;
-	
-		$this->_ci_load_class($class, $params);
+		if ($library == '')
+		{
+			return FALSE;
+		}
+
+		if (is_array($library))
+		{
+			foreach ($library as $class)
+			{
+				$this->_ci_load_class($class, $params);
+			}
+		}
+		else
+		{
+			$this->_ci_load_class($library, $params);
+		}
+		
 		$this->_ci_assign_to_models();
 	}
 
@@ -621,8 +634,7 @@
 		if ($return === TRUE)
 		{		
 			$buffer = ob_get_contents();
-			ob_end_clean();
-			
+			@ob_end_clean();
 			return $buffer;
 		}
 
@@ -645,7 +657,7 @@
 			// PHP 4 requires that we use a global
 			global $OUT;
 			$OUT->set_output(ob_get_contents());
-			ob_end_clean();
+			@ob_end_clean();
 		}
 	}
 
@@ -663,49 +675,53 @@
 	 */
 	function _ci_load_class($class, $params = NULL)
 	{	
-		// Prep the class name
-		$class = ucfirst(strtolower(str_replace(EXT, '', $class)));
+		// Get the class name
+		$class = str_replace(EXT, '', $class);
 
-		// Is this a class extension request?
-		if (file_exists(APPPATH.'libraries/'.config_item('subclass_prefix').$class.EXT))
+		// We'll test for both lowercase and capitalized versions of the file name
+		foreach (array(ucfirst($class), strtolower($class)) as $class)
 		{
-			if ( ! file_exists(BASEPATH.'libraries/'.$class.EXT))
+			// Is this a class extension request?
+			if (file_exists(APPPATH.'libraries/'.config_item('subclass_prefix').$class.EXT))
 			{
-				log_message('error', "Unable to load the requested class: ".$class);
-				show_error("Unable to load the requested class: ".$class);
+				if ( ! file_exists(BASEPATH.'libraries/'.ucfirst($class).EXT))
+				{
+					log_message('error', "Unable to load the requested class: ".$class);
+					show_error("Unable to load the requested class: ".$class);
+				}
+	
+				include(BASEPATH.'libraries/'.ucfirst($class).EXT);
+				include(APPPATH.'libraries/'.config_item('subclass_prefix').$class.EXT);
+	
+				return $this->_ci_init_class($class, config_item('subclass_prefix'), $params);			
 			}
-
-			include(BASEPATH.'libraries/'.ucfirst($class).EXT);
-			include(APPPATH.'libraries/'.config_item('subclass_prefix').$class.EXT);
-
-			return $this->_ci_init_class($class, config_item('subclass_prefix'), $params);			
-		}
-
-		// Lets search for the requested library file and load it.
-		$is_duplicate = FALSE;		
-		for ($i = 1; $i < 3; $i++)
-		{
-			$path = ($i % 2) ? APPPATH : BASEPATH;	
-			$fp = $path.'libraries/'.$class.EXT;
-			
-			// Does the file exist?  No?  Bummer...
-			if ( ! file_exists($fp))
+		
+			// Lets search for the requested library file and load it.
+			$is_duplicate = FALSE;		
+			for ($i = 1; $i < 3; $i++)
 			{
-				continue;
+				$path = ($i % 2) ? APPPATH : BASEPATH;	
+				$fp = $path.'libraries/'.$class.EXT;
+				
+				// Does the file exist?  No?  Bummer...
+				if ( ! file_exists($fp))
+				{
+					continue;
+				}
+				
+				// Safety:  Was the class already loaded by a previous call?
+				if (in_array($fp, $this->_ci_classes))
+				{
+					$is_duplicate = TRUE;
+					continue;
+				}
+				
+				include($fp);
+				$this->_ci_classes[] = $fp;
+				return $this->_ci_init_class($class, '', $params);
 			}
-			
-			// Safety:  Was the class already loaded by a previous call?
-			if (in_array($fp, $this->_ci_classes))
-			{
-				$is_duplicate = TRUE;
-				continue;
-			}
-			
-			include($fp);
-			$this->_ci_classes[] = $fp;
-			return $this->_ci_init_class($class, '', $params);
-		}
-
+		} // END FOREACH
+		
 		// If we got this far we were unable to find the requested class.
 		// We do not issue errors if the load call failed due to a duplicate request
 		if ($is_duplicate == FALSE)