<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>CHANGELOG</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -7,16 +7,18 @@ thor install http://github.com/coryodaniel/ruby-yui/raw/master/task.thor
 # this also takes a options hash, defaults are stated below
 yui = Yui.new &quot;./path/to/javascripts&quot;
 yui = Yui.new &quot;./path/to/javascripts&quot;, :out_path =&gt; &quot;./public/javascripts&quot;
+yui = Yui.new &quot;./path/to/javascripts/application.js&quot;
+yui = Yui.new &quot;./path/to/javascripts/*.my.cool.glob.*.js&quot;
 
 # to compress
 yui.minify
+Yui.compress_string(&quot;alert('hello world');&quot;)
 # =&gt; true|false if 100% of files where minified
 
 # to compress &amp; bundle
 yui.bundle
 # =&gt; path to bundle OR nil if failed to bundle
 
-
 ==== Quick Usage
 # This does the same thing as instantiating a Yui object and calling minify
 #   it also takes the same params hash</diff>
      <filename>README</filename>
    </modified>
    <modified>
      <diff>@@ -23,11 +23,10 @@ SPEC = Gem::Specification.new do |s|
   s.email = EMAIL
   s.homepage = HOMEPAGE
   s.rubyforge_project = PROJECT
-    
+  s.executables = [&quot;rubyyui&quot;]    
   s.require_path = 'lib'
   s.bindir = &quot;bin&quot;
-  s.executables = []
-  s.files = s.extra_rdoc_files + %w(Thorfile) + Dir.glob(&quot;{ext,lib,test,spec}/**/*&quot;)
+  s.files = s.extra_rdoc_files + %w(Thorfile) + Dir.glob(&quot;{ext,bin,lib,test,spec}/**/*&quot;)
 end
 
 class Default &lt; Thor</diff>
      <filename>Thorfile</filename>
    </modified>
    <modified>
      <filename>ext/yuicompressor-2.4.2.jar</filename>
    </modified>
    <modified>
      <filename>lib/ruby-yui.rb</filename>
    </modified>
    <modified>
      <diff>@@ -2,11 +2,10 @@
 require &quot;ruby-debug&quot;
 Debugger.start
 Debugger.settings[:autoeval] = true if Debugger.respond_to?(:settings)
-# TODO md5 checksum the compressed files for spec testing to verify they were compressed correctly.
-# TODO output yui.checksums.txt &quot;#{OUT_PATH}\t#{CHECKSUM}\n&quot;
 
 require 'open3'
 require 'fileutils'
+require 'tempfile'
 
 class Yui
   include Open3
@@ -15,37 +14,45 @@ class Yui
   
   MAJOR = 0
   MINOR = 0
-  RELEASE = 4
+  RELEASE = 6
   def Yui.version
     [MAJOR,MINOR,RELEASE].join('.')
   end
   
   YUI_ROOT    = File.join(File.dirname(__FILE__),'..','..')
-      
+  FILE_TYPES  = [:js, :css]
+  
   # Grabs a glob of files
-  # @param inpath [String] path
+  # @param inpath [String] file path, directory or glob
   # @param options [Hash]
   # @see Yui#defaults
   #
-  # inpath + options[:type] will create a glob,
-  #   directory structure will be replicated in outputh
-  #
   # @example
   #   Yui.new(&quot;./javascripts&quot;)
   #   [/javascripts/main.js, /javascripts/folder/other.js]
   #
-  def initialize(inpath,options={})
+  def initialize(inpath, options = {})    
     @inpath   = inpath
     @options  = Yui.defaults.merge(options)
     @options[:suffix] = &quot;&quot; if @options[:suffix].nil?
-    glob_path = File.join(@inpath,&quot;**&quot;,&quot;*.#{@options[:type]}&quot;)
-    @files    = Dir.glob(glob_path)
     
+    @files = if File.file?(@inpath) #Processing a single file
+      extension = File.extname(@inpath).delete!('.').to_sym
+      # set the type automatically
+      @options[:type] = extension if FILE_TYPES.member?(extension)
+      
+      [@inpath]
+    elsif File.directory?(@inpath)
+      Dir[File.join(@inpath,&quot;**&quot;,&quot;*.#{@options[:type]}&quot;)]
+    else # assume its a glob
+      Dir[@inpath]
+    end
+        
     if @options[:suffix].empty? &amp;&amp; outpath == @inpath &amp;&amp; @options[:stomp] == false
       raise Exception, &quot;Your originals will be destroyed without a suffix or an outpath, run again with :stomp =&gt; true to allow this.&quot;
     end
     
-    #Dont compress ruby-yui files.
+    #Try not to compress ruby-yui files.
     @files.delete_if {|file| file =~ /#{@options[:suffix]}/} unless @options[:suffix].empty?
     
     self.clobber if @options[:clobber]
@@ -54,9 +61,7 @@ class Yui
   attr_reader :inpath
   attr_reader :options
   
-  def outpath
-    @options[:out_path] || @inpath
-  end
+  def outpath;@options[:out_path] || @inpath;end;
   
   #Clobbers files with the right suffix/type in the outpath
   #   outpath defaults to inpath
@@ -151,18 +156,47 @@ class Yui
       
   # Clobber *.SUFFIX.(js|css)
   def Yui.clobber(path,suffix,type)
-    if suffix.empty?
-      glob_path = File.join(path,&quot;**.#{type}&quot;)
+    glob_path = if File.file?(path)
+      path
+    elsif suffix.empty?
+      File.join(path,&quot;**.#{type}&quot;)
     else
-      glob_path = File.join(path,&quot;**&quot;,&quot;*#{suffix}.#{type}&quot;)
+      File.join(path,&quot;**&quot;,&quot;*#{suffix}.#{type}&quot;)
     end
     
-    Dir.glob(glob_path).each do |file|
+    Dir[glob_path].each do |file|
       puts &quot;Clobbering #{file}...&quot;
       FileUtils.rm file
     end
   end
   
+  #
+  # @param str [String] javascript/css to compress
+  # @param type [Symbol] :js | :css
+  # @param outpath [String] path to (optionally) out put to
+  # 
+  # @return [Array[Boolean,String]] Success, compressed data
+  #
+  # @notes, this is done with the tempfile class
+  #
+  def Yui.compress_string(str,type,outpath =  nil)
+    temp_file = Tempfile.new(&quot;rubyui-#{rand(5000)}&quot;)
+    temp_file.puts str
+    temp_file.flush
+    
+    cmd = Yui.gen_cmd temp_file.path, Yui.defaults.merge({:type =&gt; type})
+    stdin, stdout, stderr = Open3::popen3(cmd.join(' '))
+
+    comp_ok = (stderr.read.empty?)
+    stdout = stdout.read
+    
+    if comp_ok &amp;&amp; outpath
+      File.open(outpath,'w+'){ |fs| fs.puts stdout }
+    end
+    
+    [comp_ok, stdout]
+  end
+  
   # Compresses inpath with options
   # @see Yui#initialize
   # @return [Boolean]
@@ -175,11 +209,17 @@ class Yui
   protected
   # Generates the command line call
   def Yui.gen_cmd(in_file,options)
-    _cmd = [%{#{options[:java_cli]} #{options[:yui_jar]} #{in_file}}]
+    _cmd = [%{#{options[:java_cli]} #{options[:yui_jar]}}]
+    _cmd &lt;&lt; &quot;--type #{options[:type]}&quot;
     _cmd &lt;&lt; &quot;--charset #{options[:charset]}&quot; if options[:charset]
-    _cmd &lt;&lt; &quot;--nomunge&quot; if options[:nomunge]
-    _cmd &lt;&lt; &quot;--preserve-semi&quot; if options[:preserve_semi]
-    _cmd &lt;&lt; &quot;--disable-optimizations&quot; if options[:disable_opt]
+    
+    if options[:type] == :js #js only options
+      _cmd &lt;&lt; &quot;--nomunge&quot; if options[:nomunge] 
+      _cmd &lt;&lt; &quot;--preserve-semi&quot; if options[:preserve_semi]
+      _cmd &lt;&lt; &quot;--disable-optimizations&quot; if options[:disable_opt]
+    end
+    
+    _cmd &lt;&lt; in_file
     _cmd
   end
   </diff>
      <filename>lib/ruby-yui/yui.rb</filename>
    </modified>
    <modified>
      <diff>@@ -2,16 +2,17 @@
 
 Gem::Specification.new do |s|
   s.name = %q{ruby-yui}
-  s.version = &quot;0.0.4&quot;
+  s.version = &quot;0.0.6&quot;
 
   s.required_rubygems_version = Gem::Requirement.new(&quot;&gt;= 0&quot;) if s.respond_to? :required_rubygems_version=
   s.authors = [&quot;Cory O'Daniel&quot;]
-  s.date = %q{2008-12-17}
+  s.date = %q{2009-02-27}
   s.description = %q{A ruby wrapper for YUI compressor}
   s.email = %q{ruby-yui@coryodaniel.com}
   s.extra_rdoc_files = [&quot;README&quot;]
   s.files = [&quot;README&quot;, &quot;Thorfile&quot;, &quot;ext/yuicompressor-2.4.2.jar&quot;, &quot;lib/ruby-yui&quot;, &quot;lib/ruby-yui/yui.rb&quot;, &quot;lib/ruby-yui.rb&quot;, &quot;test/data&quot;, &quot;test/data/alt_out_path&quot;, &quot;test/data/alt_out_path/javascripts&quot;, &quot;test/data/backups&quot;, &quot;test/data/backups/jquery-1.2.6.js&quot;, &quot;test/data/backups/prototype.js&quot;, &quot;test/data/backups/stompable.js&quot;, &quot;test/data/javascripts&quot;, &quot;test/data/javascripts/jquery-1.2.6.js&quot;, &quot;test/data/javascripts/prototype.js&quot;, &quot;test/data/stompers&quot;, &quot;test/data/stompers/stompable.js&quot;, &quot;test/data/stylesheets&quot;, &quot;spec/unit&quot;, &quot;spec/unit/yui_spec.rb&quot;]
   s.has_rdoc = true
+  s.executables = [&quot;rubyyui&quot;]    
   s.homepage = %q{http://coryodaniel.com}
   s.require_paths = [&quot;lib&quot;]
   s.rubyforge_project = %q{ruby-yui}</diff>
      <filename>ruby-yui.gemspec</filename>
    </modified>
    <modified>
      <diff>@@ -57,6 +57,28 @@ describe Yui do
     }.should raise_error(Exception)
   end
   
+  it 'should be able to compress a string' do
+    Yui.compress_string(&quot;alert('js');&quot;,:js).first.should be(true)
+  end
+  
+  it 'should be able to compress a string to file' do
+    file = &quot;./test/data/alt_out_path/compress_from_str.js&quot;
+    result = Yui.compress_string(&quot;alert('js');&quot;,:js, file)
+    
+    result.first.should be(true)
+    File.file?(file).should be(true)
+        
+    FileUtils.rm file
+  end
+  
+  it 'should be able to process a single file' do
+    yui = Yui.new &quot;./test/data/javascripts/prototype.js&quot;
+    yui.minify
+    File.exist?(&quot;./test/data/javascripts/prototype.yui-min.js&quot;).should be(true)
+    
+    FileUtils.rm &quot;./test/data/javascripts/prototype.yui-min.js&quot;
+  end
+  
   it 'should be able to specify an alternate out path' do
     yui = Yui.new &quot;./test/data/javascripts&quot;, :out_path =&gt; &quot;./test/data/alt_out_path/javascripts&quot;
     yui.minify</diff>
      <filename>spec/unit/yui_spec.rb</filename>
    </modified>
    <modified>
      <filename>task.thor</filename>
    </modified>
    <modified>
      <filename>test/data/backups/jquery-1.2.6.js</filename>
    </modified>
    <modified>
      <filename>test/data/backups/prototype.js</filename>
    </modified>
    <modified>
      <filename>test/data/backups/stompable.js</filename>
    </modified>
    <modified>
      <filename>test/data/javascripts/.DS_Store</filename>
    </modified>
    <modified>
      <diff>@@ -1,3549 +1 @@
-(function(){
-/*
- * jQuery 1.2.6 - New Wave Javascript
- *
- * Copyright (c) 2008 John Resig (jquery.com)
- * Dual licensed under the MIT (MIT-LICENSE.txt)
- * and GPL (GPL-LICENSE.txt) licenses.
- *
- * $Date: 2008-05-24 14:22:17 -0400 (Sat, 24 May 2008) $
- * $Rev: 5685 $
- */
-
-// Map over jQuery in case of overwrite
-var _jQuery = window.jQuery,
-// Map over the $ in case of overwrite
-	_$ = window.$;
-
-var jQuery = window.jQuery = window.$ = function( selector, context ) {
-	// The jQuery object is actually just the init constructor 'enhanced'
-	return new jQuery.fn.init( selector, context );
-};
-
-// A simple way to check for HTML strings or ID strings
-// (both of which we optimize for)
-var quickExpr = /^[^&lt;]*(&lt;(.|\s)+&gt;)[^&gt;]*$|^#(\w+)$/,
-
-// Is it a simple selector
-	isSimple = /^.[^:#\[\.]*$/,
-
-// Will speed up references to undefined, and allows munging its name.
-	undefined;
-
-jQuery.fn = jQuery.prototype = {
-	init: function( selector, context ) {
-		// Make sure that a selection was provided
-		selector = selector || document;
-
-		// Handle $(DOMElement)
-		if ( selector.nodeType ) {
-			this[0] = selector;
-			this.length = 1;
-			return this;
-		}
-		// Handle HTML strings
-		if ( typeof selector == &quot;string&quot; ) {
-			// Are we dealing with HTML string or an ID?
-			var match = quickExpr.exec( selector );
-
-			// Verify a match, and that no context was specified for #id
-			if ( match &amp;&amp; (match[1] || !context) ) {
-
-				// HANDLE: $(html) -&gt; $(array)
-				if ( match[1] )
-					selector = jQuery.clean( [ match[1] ], context );
-
-				// HANDLE: $(&quot;#id&quot;)
-				else {
-					var elem = document.getElementById( match[3] );
-
-					// Make sure an element was located
-					if ( elem ){
-						// Handle the case where IE and Opera return items
-						// by name instead of ID
-						if ( elem.id != match[3] )
-							return jQuery().find( selector );
-
-						// Otherwise, we inject the element directly into the jQuery object
-						return jQuery( elem );
-					}
-					selector = [];
-				}
-
-			// HANDLE: $(expr, [context])
-			// (which is just equivalent to: $(content).find(expr)
-			} else
-				return jQuery( context ).find( selector );
-
-		// HANDLE: $(function)
-		// Shortcut for document ready
-		} else if ( jQuery.isFunction( selector ) )
-			return jQuery( document )[ jQuery.fn.ready ? &quot;ready&quot; : &quot;load&quot; ]( selector );
-
-		return this.setArray(jQuery.makeArray(selector));
-	},
-
-	// The current version of jQuery being used
-	jquery: &quot;1.2.6&quot;,
-
-	// The number of elements contained in the matched element set
-	size: function() {
-		return this.length;
-	},
-
-	// The number of elements contained in the matched element set
-	length: 0,
-
-	// Get the Nth element in the matched element set OR
-	// Get the whole matched element set as a clean array
-	get: function( num ) {
-		return num == undefined ?
-
-			// Return a 'clean' array
-			jQuery.makeArray( this ) :
-
-			// Return just the object
-			this[ num ];
-	},
-
-	// Take an array of elements and push it onto the stack
-	// (returning the new matched element set)
-	pushStack: function( elems ) {
-		// Build a new jQuery matched element set
-		var ret = jQuery( elems );
-
-		// Add the old object onto the stack (as a reference)
-		ret.prevObject = this;
-
-		// Return the newly-formed element set
-		return ret;
-	},
-
-	// Force the current matched set of elements to become
-	// the specified array of elements (destroying the stack in the process)
-	// You should use pushStack() in order to do this, but maintain the stack
-	setArray: function( elems ) {
-		// Resetting the length to 0, then using the native Array push
-		// is a super-fast way to populate an object with array-like properties
-		this.length = 0;
-		Array.prototype.push.apply( this, elems );
-
-		return this;
-	},
-
-	// Execute a callback for every element in the matched set.
-	// (You can seed the arguments with an array of args, but this is
-	// only used internally.)
-	each: function( callback, args ) {
-		return jQuery.each( this, callback, args );
-	},
-
-	// Determine the position of an element within
-	// the matched set of elements
-	index: function( elem ) {
-		var ret = -1;
-
-		// Locate the position of the desired element
-		return jQuery.inArray(
-			// If it receives a jQuery object, the first element is used
-			elem &amp;&amp; elem.jquery ? elem[0] : elem
-		, this );
-	},
-
-	attr: function( name, value, type ) {
-		var options = name;
-
-		// Look for the case where we're accessing a style value
-		if ( name.constructor == String )
-			if ( value === undefined )
-				return this[0] &amp;&amp; jQuery[ type || &quot;attr&quot; ]( this[0], name );
-
-			else {
-				options = {};
-				options[ name ] = value;
-			}
-
-		// Check to see if we're setting style values
-		return this.each(function(i){
-			// Set all the styles
-			for ( name in options )
-				jQuery.attr(
-					type ?
-						this.style :
-						this,
-					name, jQuery.prop( this, options[ name ], type, i, name )
-				);
-		});
-	},
-
-	css: function( key, value ) {
-		// ignore negative width and height values
-		if ( (key == 'width' || key == 'height') &amp;&amp; parseFloat(value) &lt; 0 )
-			value = undefined;
-		return this.attr( key, value, &quot;curCSS&quot; );
-	},
-
-	text: function( text ) {
-		if ( typeof text != &quot;object&quot; &amp;&amp; text != null )
-			return this.empty().append( (this[0] &amp;&amp; this[0].ownerDocument || document).createTextNode( text ) );
-
-		var ret = &quot;&quot;;
-
-		jQuery.each( text || this, function(){
-			jQuery.each( this.childNodes, function(){
-				if ( this.nodeType != 8 )
-					ret += this.nodeType != 1 ?
-						this.nodeValue :
-						jQuery.fn.text( [ this ] );
-			});
-		});
-
-		return ret;
-	},
-
-	wrapAll: function( html ) {
-		if ( this[0] )
-			// The elements to wrap the target around
-			jQuery( html, this[0].ownerDocument )
-				.clone()
-				.insertBefore( this[0] )
-				.map(function(){
-					var elem = this;
-
-					while ( elem.firstChild )
-						elem = elem.firstChild;
-
-					return elem;
-				})
-				.append(this);
-
-		return this;
-	},
-
-	wrapInner: function( html ) {
-		return this.each(function(){
-			jQuery( this ).contents().wrapAll( html );
-		});
-	},
-
-	wrap: function( html ) {
-		return this.each(function(){
-			jQuery( this ).wrapAll( html );
-		});
-	},
-
-	append: function() {
-		return this.domManip(arguments, true, false, function(elem){
-			if (this.nodeType == 1)
-				this.appendChild( elem );
-		});
-	},
-
-	prepend: function() {
-		return this.domManip(arguments, true, true, function(elem){
-			if (this.nodeType == 1)
-				this.insertBefore( elem, this.firstChild );
-		});
-	},
-
-	before: function() {
-		return this.domManip(arguments, false, false, function(elem){
-			this.parentNode.insertBefore( elem, this );
-		});
-	},
-
-	after: function() {
-		return this.domManip(arguments, false, true, function(elem){
-			this.parentNode.insertBefore( elem, this.nextSibling );
-		});
-	},
-
-	end: function() {
-		return this.prevObject || jQuery( [] );
-	},
-
-	find: function( selector ) {
-		var elems = jQuery.map(this, function(elem){
-			return jQuery.find( selector, elem );
-		});
-
-		return this.pushStack( /[^+&gt;] [^+&gt;]/.test( selector ) || selector.indexOf(&quot;..&quot;) &gt; -1 ?
-			jQuery.unique( elems ) :
-			elems );
-	},
-
-	clone: function( events ) {
-		// Do the clone
-		var ret = this.map(function(){
-			if ( jQuery.browser.msie &amp;&amp; !jQuery.isXMLDoc(this) ) {
-				// IE copies events bound via attachEvent when
-				// using cloneNode. Calling detachEvent on the
-				// clone will also remove the events from the orignal
-				// In order to get around this, we use innerHTML.
-				// Unfortunately, this means some modifications to
-				// attributes in IE that are actually only stored
-				// as properties will not be copied (such as the
-				// the name attribute on an input).
-				var clone = this.cloneNode(true),
-					container = document.createElement(&quot;div&quot;);
-				container.appendChild(clone);
-				return jQuery.clean([container.innerHTML])[0];
-			} else
-				return this.cloneNode(true);
-		});
-
-		// Need to set the expando to null on the cloned set if it exists
-		// removeData doesn't work here, IE removes it from the original as well
-		// this is primarily for IE but the data expando shouldn't be copied over in any browser
-		var clone = ret.find(&quot;*&quot;).andSelf().each(function(){
-			if ( this[ expando ] != undefined )
-				this[ expando ] = null;
-		});
-
-		// Copy the events from the original to the clone
-		if ( events === true )
-			this.find(&quot;*&quot;).andSelf().each(function(i){
-				if (this.nodeType == 3)
-					return;
-				var events = jQuery.data( this, &quot;events&quot; );
-
-				for ( var type in events )
-					for ( var handler in events[ type ] )
-						jQuery.event.add( clone[ i ], type, events[ type ][ handler ], events[ type ][ handler ].data );
-			});
-
-		// Return the cloned set
-		return ret;
-	},
-
-	filter: function( selector ) {
-		return this.pushStack(
-			jQuery.isFunction( selector ) &amp;&amp;
-			jQuery.grep(this, function(elem, i){
-				return selector.call( elem, i );
-			}) ||
-
-			jQuery.multiFilter( selector, this ) );
-	},
-
-	not: function( selector ) {
-		if ( selector.constructor == String )
-			// test special case where just one selector is passed in
-			if ( isSimple.test( selector ) )
-				return this.pushStack( jQuery.multiFilter( selector, this, true ) );
-			else
-				selector = jQuery.multiFilter( selector, this );
-
-		var isArrayLike = selector.length &amp;&amp; selector[selector.length - 1] !== undefined &amp;&amp; !selector.nodeType;
-		return this.filter(function() {
-			return isArrayLike ? jQuery.inArray( this, selector ) &lt; 0 : this != selector;
-		});
-	},
-
-	add: function( selector ) {
-		return this.pushStack( jQuery.unique( jQuery.merge(
-			this.get(),
-			typeof selector == 'string' ?
-				jQuery( selector ) :
-				jQuery.makeArray( selector )
-		)));
-	},
-
-	is: function( selector ) {
-		return !!selector &amp;&amp; jQuery.multiFilter( selector, this ).length &gt; 0;
-	},
-
-	hasClass: function( selector ) {
-		return this.is( &quot;.&quot; + selector );
-	},
-
-	val: function( value ) {
-		if ( value == undefined ) {
-
-			if ( this.length ) {
-				var elem = this[0];
-
-				// We need to handle select boxes special
-				if ( jQuery.nodeName( elem, &quot;select&quot; ) ) {
-					var index = elem.selectedIndex,
-						values = [],
-						options = elem.options,
-						one = elem.type == &quot;select-one&quot;;
-
-					// Nothing was selected
-					if ( index &lt; 0 )
-						return null;
-
-					// Loop through all the selected options
-					for ( var i = one ? index : 0, max = one ? index + 1 : options.length; i &lt; max; i++ ) {
-						var option = options[ i ];
-
-						if ( option.selected ) {
-							// Get the specifc value for the option
-							value = jQuery.browser.msie &amp;&amp; !option.attributes.value.specified ? option.text : option.value;
-
-							// We don't need an array for one selects
-							if ( one )
-								return value;
-
-							// Multi-Selects return an array
-							values.push( value );
-						}
-					}
-
-					return values;
-
-				// Everything else, we just grab the value
-				} else
-					return (this[0].value || &quot;&quot;).replace(/\r/g, &quot;&quot;);
-
-			}
-
-			return undefined;
-		}
-
-		if( value.constructor == Number )
-			value += '';
-
-		return this.each(function(){
-			if ( this.nodeType != 1 )
-				return;
-
-			if ( value.constructor == Array &amp;&amp; /radio|checkbox/.test( this.type ) )
-				this.checked = (jQuery.inArray(this.value, value) &gt;= 0 ||
-					jQuery.inArray(this.name, value) &gt;= 0);
-
-			else if ( jQuery.nodeName( this, &quot;select&quot; ) ) {
-				var values = jQuery.makeArray(value);
-
-				jQuery( &quot;option&quot;, this ).each(function(){
-					this.selected = (jQuery.inArray( this.value, values ) &gt;= 0 ||
-						jQuery.inArray( this.text, values ) &gt;= 0);
-				});
-
-				if ( !values.length )
-					this.selectedIndex = -1;
-
-			} else
-				this.value = value;
-		});
-	},
-
-	html: function( value ) {
-		return value == undefined ?
-			(this[0] ?
-				this[0].innerHTML :
-				null) :
-			this.empty().append( value );
-	},
-
-	replaceWith: function( value ) {
-		return this.after( value ).remove();
-	},
-
-	eq: function( i ) {
-		return this.slice( i, i + 1 );
-	},
-
-	slice: function() {
-		return this.pushStack( Array.prototype.slice.apply( this, arguments ) );
-	},
-
-	map: function( callback ) {
-		return this.pushStack( jQuery.map(this, function(elem, i){
-			return callback.call( elem, i, elem );
-		}));
-	},
-
-	andSelf: function() {
-		return this.add( this.prevObject );
-	},
-
-	data: function( key, value ){
-		var parts = key.split(&quot;.&quot;);
-		parts[1] = parts[1] ? &quot;.&quot; + parts[1] : &quot;&quot;;
-
-		if ( value === undefined ) {
-			var data = this.triggerHandler(&quot;getData&quot; + parts[1] + &quot;!&quot;, [parts[0]]);
-
-			if ( data === undefined &amp;&amp; this.length )
-				data = jQuery.data( this[0], key );
-
-			return data === undefined &amp;&amp; parts[1] ?
-				this.data( parts[0] ) :
-				data;
-		} else
-			return this.trigger(&quot;setData&quot; + parts[1] + &quot;!&quot;, [parts[0], value]).each(function(){
-				jQuery.data( this, key, value );
-			});
-	},
-
-	removeData: function( key ){
-		return this.each(function(){
-			jQuery.removeData( this, key );
-		});
-	},
-
-	domManip: function( args, table, reverse, callback ) {
-		var clone = this.length &gt; 1, elems;
-
-		return this.each(function(){
-			if ( !elems ) {
-				elems = jQuery.clean( args, this.ownerDocument );
-
-				if ( reverse )
-					elems.reverse();
-			}
-
-			var obj = this;
-
-			if ( table &amp;&amp; jQuery.nodeName( this, &quot;table&quot; ) &amp;&amp; jQuery.nodeName( elems[0], &quot;tr&quot; ) )
-				obj = this.getElementsByTagName(&quot;tbody&quot;)[0] || this.appendChild( this.ownerDocument.createElement(&quot;tbody&quot;) );
-
-			var scripts = jQuery( [] );
-
-			jQuery.each(elems, function(){
-				var elem = clone ?
-					jQuery( this ).clone( true )[0] :
-					this;
-
-				// execute all scripts after the elements have been injected
-				if ( jQuery.nodeName( elem, &quot;script&quot; ) )
-					scripts = scripts.add( elem );
-				else {
-					// Remove any inner scripts for later evaluation
-					if ( elem.nodeType == 1 )
-						scripts = scripts.add( jQuery( &quot;script&quot;, elem ).remove() );
-
-					// Inject the elements into the document
-					callback.call( obj, elem );
-				}
-			});
-
-			scripts.each( evalScript );
-		});
-	}
-};
-
-// Give the init function the jQuery prototype for later instantiation
-jQuery.fn.init.prototype = jQuery.fn;
-
-function evalScript( i, elem ) {
-	if ( elem.src )
-		jQuery.ajax({
-			url: elem.src,
-			async: false,
-			dataType: &quot;script&quot;
-		});
-
-	else
-		jQuery.globalEval( elem.text || elem.textContent || elem.innerHTML || &quot;&quot; );
-
-	if ( elem.parentNode )
-		elem.parentNode.removeChild( elem );
-}
-
-function now(){
-	return +new Date;
-}
-
-jQuery.extend = jQuery.fn.extend = function() {
-	// copy reference to target object
-	var target = arguments[0] || {}, i = 1, length = arguments.length, deep = false, options;
-
-	// Handle a deep copy situation
-	if ( target.constructor == Boolean ) {
-		deep = target;
-		target = arguments[1] || {};
-		// skip the boolean and the target
-		i = 2;
-	}
-
-	// Handle case when target is a string or something (possible in deep copy)
-	if ( typeof target != &quot;object&quot; &amp;&amp; typeof target != &quot;function&quot; )
-		target = {};
-
-	// extend jQuery itself if only one argument is passed
-	if ( length == i ) {
-		target = this;
-		--i;
-	}
-
-	for ( ; i &lt; length; i++ )
-		// Only deal with non-null/undefined values
-		if ( (options = arguments[ i ]) != null )
-			// Extend the base object
-			for ( var name in options ) {
-				var src = target[ name ], copy = options[ name ];
-
-				// Prevent never-ending loop
-				if ( target === copy )
-					continue;
-
-				// Recurse if we're merging object values
-				if ( deep &amp;&amp; copy &amp;&amp; typeof copy == &quot;object&quot; &amp;&amp; !copy.nodeType )
-					target[ name ] = jQuery.extend( deep, 
-						// Never move original objects, clone them
-						src || ( copy.length != null ? [ ] : { } )
-					, copy );
-
-				// Don't bring in undefined values
-				else if ( copy !== undefined )
-					target[ name ] = copy;
-
-			}
-
-	// Return the modified object
-	return target;
-};
-
-var expando = &quot;jQuery&quot; + now(), uuid = 0, windowData = {},
-	// exclude the following css properties to add px
-	exclude = /z-?index|font-?weight|opacity|zoom|line-?height/i,
-	// cache defaultView
-	defaultView = document.defaultView || {};
-
-jQuery.extend({
-	noConflict: function( deep ) {
-		window.$ = _$;
-
-		if ( deep )
-			window.jQuery = _jQuery;
-
-		return jQuery;
-	},
-
-	// See test/unit/core.js for details concerning this function.
-	isFunction: function( fn ) {
-		return !!fn &amp;&amp; typeof fn != &quot;string&quot; &amp;&amp; !fn.nodeName &amp;&amp;
-			fn.constructor != Array &amp;&amp; /^[\s[]?function/.test( fn + &quot;&quot; );
-	},
-
-	// check if an element is in a (or is an) XML document
-	isXMLDoc: function( elem ) {
-		return elem.documentElement &amp;&amp; !elem.body ||
-			elem.tagName &amp;&amp; elem.ownerDocument &amp;&amp; !elem.ownerDocument.body;
-	},
-
-	// Evalulates a script in a global context
-	globalEval: function( data ) {
-		data = jQuery.trim( data );
-
-		if ( data ) {
-			// Inspired by code by Andrea Giammarchi
-			// http://webreflection.blogspot.com/2007/08/global-scope-evaluation-and-dom.html
-			var head = document.getElementsByTagName(&quot;head&quot;)[0] || document.documentElement,
-				script = document.createElement(&quot;script&quot;);
-
-			script.type = &quot;text/javascript&quot;;
-			if ( jQuery.browser.msie )
-				script.text = data;
-			else
-				script.appendChild( document.createTextNode( data ) );
-
-			// Use insertBefore instead of appendChild  to circumvent an IE6 bug.
-			// This arises when a base node is used (#2709).
-			head.insertBefore( script, head.firstChild );
-			head.removeChild( script );
-		}
-	},
-
-	nodeName: function( elem, name ) {
-		return elem.nodeName &amp;&amp; elem.nodeName.toUpperCase() == name.toUpperCase();
-	},
-
-	cache: {},
-
-	data: function( elem, name, data ) {
-		elem = elem == window ?
-			windowData :
-			elem;
-
-		var id = elem[ expando ];
-
-		// Compute a unique ID for the element
-		if ( !id )
-			id = elem[ expando ] = ++uuid;
-
-		// Only generate the data cache if we're
-		// trying to access or manipulate it
-		if ( name &amp;&amp; !jQuery.cache[ id ] )
-			jQuery.cache[ id ] = {};
-
-		// Prevent overriding the named cache with undefined values
-		if ( data !== undefined )
-			jQuery.cache[ id ][ name ] = data;
-
-		// Return the named cache data, or the ID for the element
-		return name ?
-			jQuery.cache[ id ][ name ] :
-			id;
-	},
-
-	removeData: function( elem, name ) {
-		elem = elem == window ?
-			windowData :
-			elem;
-
-		var id = elem[ expando ];
-
-		// If we want to remove a specific section of the element's data
-		if ( name ) {
-			if ( jQuery.cache[ id ] ) {
-				// Remove the section of cache data
-				delete jQuery.cache[ id ][ name ];
-
-				// If we've removed all the data, remove the element's cache
-				name = &quot;&quot;;
-
-				for ( name in jQuery.cache[ id ] )
-					break;
-
-				if ( !name )
-					jQuery.removeData( elem );
-			}
-
-		// Otherwise, we want to remove all of the element's data
-		} else {
-			// Clean up the element expando
-			try {
-				delete elem[ expando ];
-			} catch(e){
-				// IE has trouble directly removing the expando
-				// but it's ok with using removeAttribute
-				if ( elem.removeAttribute )
-					elem.removeAttribute( expando );
-			}
-
-			// Completely remove the data cache
-			delete jQuery.cache[ id ];
-		}
-	},
-
-	// args is for internal usage only
-	each: function( object, callback, args ) {
-		var name, i = 0, length = object.length;
-
-		if ( args ) {
-			if ( length == undefined ) {
-				for ( name in object )
-					if ( callback.apply( object[ name ], args ) === false )
-						break;
-			} else
-				for ( ; i &lt; length; )
-					if ( callback.apply( object[ i++ ], args ) === false )
-						break;
-
-		// A special, fast, case for the most common use of each
-		} else {
-			if ( length == undefined ) {
-				for ( name in object )
-					if ( callback.call( object[ name ], name, object[ name ] ) === false )
-						break;
-			} else
-				for ( var value = object[0];
-					i &lt; length &amp;&amp; callback.call( value, i, value ) !== false; value = object[++i] ){}
-		}
-
-		return object;
-	},
-
-	prop: function( elem, value, type, i, name ) {
-		// Handle executable functions
-		if ( jQuery.isFunction( value ) )
-			value = value.call( elem, i );
-
-		// Handle passing in a number to a CSS property
-		return value &amp;&amp; value.constructor == Number &amp;&amp; type == &quot;curCSS&quot; &amp;&amp; !exclude.test( name ) ?
-			value + &quot;px&quot; :
-			value;
-	},
-
-	className: {
-		// internal only, use addClass(&quot;class&quot;)
-		add: function( elem, classNames ) {
-			jQuery.each((classNames || &quot;&quot;).split(/\s+/), function(i, className){
-				if ( elem.nodeType == 1 &amp;&amp; !jQuery.className.has( elem.className, className ) )
-					elem.className += (elem.className ? &quot; &quot; : &quot;&quot;) + className;
-			});
-		},
-
-		// internal only, use removeClass(&quot;class&quot;)
-		remove: function( elem, classNames ) {
-			if (elem.nodeType == 1)
-				elem.className = classNames != undefined ?
-					jQuery.grep(elem.className.split(/\s+/), function(className){
-						return !jQuery.className.has( classNames, className );
-					}).join(&quot; &quot;) :
-					&quot;&quot;;
-		},
-
-		// internal only, use hasClass(&quot;class&quot;)
-		has: function( elem, className ) {
-			return jQuery.inArray( className, (elem.className || elem).toString().split(/\s+/) ) &gt; -1;
-		}
-	},
-
-	// A method for quickly swapping in/out CSS properties to get correct calculations
-	swap: function( elem, options, callback ) {
-		var old = {};
-		// Remember the old values, and insert the new ones
-		for ( var name in options ) {
-			old[ name ] = elem.style[ name ];
-			elem.style[ name ] = options[ name ];
-		}
-
-		callback.call( elem );
-
-		// Revert the old values
-		for ( var name in options )
-			elem.style[ name ] = old[ name ];
-	},
-
-	css: function( elem, name, force ) {
-		if ( name == &quot;width&quot; || name == &quot;height&quot; ) {
-			var val, props = { position: &quot;absolute&quot;, visibility: &quot;hidden&quot;, display:&quot;block&quot; }, which = name == &quot;width&quot; ? [ &quot;Left&quot;, &quot;Right&quot; ] : [ &quot;Top&quot;, &quot;Bottom&quot; ];
-
-			function getWH() {
-				val = name == &quot;width&quot; ? elem.offsetWidth : elem.offsetHeight;
-				var padding = 0, border = 0;
-				jQuery.each( which, function() {
-					padding += parseFloat(jQuery.curCSS( elem, &quot;padding&quot; + this, true)) || 0;
-					border += parseFloat(jQuery.curCSS( elem, &quot;border&quot; + this + &quot;Width&quot;, true)) || 0;
-				});
-				val -= Math.round(padding + border);
-			}
-
-			if ( jQuery(elem).is(&quot;:visible&quot;) )
-				getWH();
-			else
-				jQuery.swap( elem, props, getWH );
-
-			return Math.max(0, val);
-		}
-
-		return jQuery.curCSS( elem, name, force );
-	},
-
-	curCSS: function( elem, name, force ) {
-		var ret, style = elem.style;
-
-		// A helper method for determining if an element's values are broken
-		function color( elem ) {
-			if ( !jQuery.browser.safari )
-				return false;
-
-			// defaultView is cached
-			var ret = defaultView.getComputedStyle( elem, null );
-			return !ret || ret.getPropertyValue(&quot;color&quot;) == &quot;&quot;;
-		}
-
-		// We need to handle opacity special in IE
-		if ( name == &quot;opacity&quot; &amp;&amp; jQuery.browser.msie ) {
-			ret = jQuery.attr( style, &quot;opacity&quot; );
-
-			return ret == &quot;&quot; ?
-				&quot;1&quot; :
-				ret;
-		}
-		// Opera sometimes will give the wrong display answer, this fixes it, see #2037
-		if ( jQuery.browser.opera &amp;&amp; name == &quot;display&quot; ) {
-			var save = style.outline;
-			style.outline = &quot;0 solid black&quot;;
-			style.outline = save;
-		}
-
-		// Make sure we're using the right name for getting the float value
-		if ( name.match( /float/i ) )
-			name = styleFloat;
-
-		if ( !force &amp;&amp; style &amp;&amp; style[ name ] )
-			ret = style[ name ];
-
-		else if ( defaultView.getComputedStyle ) {
-
-			// Only &quot;float&quot; is needed here
-			if ( name.match( /float/i ) )
-				name = &quot;float&quot;;
-
-			name = name.replace( /([A-Z])/g, &quot;-$1&quot; ).toLowerCase();
-
-			var computedStyle = defaultView.getComputedStyle( elem, null );
-
-			if ( computedStyle &amp;&amp; !color( elem ) )
-				ret = computedStyle.getPropertyValue( name );
-
-			// If the element isn't reporting its values properly in Safari
-			// then some display: none elements are involved
-			else {
-				var swap = [], stack = [], a = elem, i = 0;
-
-				// Locate all of the parent display: none elements
-				for ( ; a &amp;&amp; color(a); a = a.parentNode )
-					stack.unshift(a);
-
-				// Go through and make them visible, but in reverse
-				// (It would be better if we knew the exact display type that they had)
-				for ( ; i &lt; stack.length; i++ )
-					if ( color( stack[ i ] ) ) {
-						swap[ i ] = stack[ i ].style.display;
-						stack[ i ].style.display = &quot;block&quot;;
-					}
-
-				// Since we flip the display style, we have to handle that
-				// one special, otherwise get the value
-				ret = name == &quot;display&quot; &amp;&amp; swap[ stack.length - 1 ] != null ?
-					&quot;none&quot; :
-					( computedStyle &amp;&amp; computedStyle.getPropertyValue( name ) ) || &quot;&quot;;
-
-				// Finally, revert the display styles back
-				for ( i = 0; i &lt; swap.length; i++ )
-					if ( swap[ i ] != null )
-						stack[ i ].style.display = swap[ i ];
-			}
-
-			// We should always get a number back from opacity
-			if ( name == &quot;opacity&quot; &amp;&amp; ret == &quot;&quot; )
-				ret = &quot;1&quot;;
-
-		} else if ( elem.currentStyle ) {
-			var camelCase = name.replace(/\-(\w)/g, function(all, letter){
-				return letter.toUpperCase();
-			});
-
-			ret = elem.currentStyle[ name ] || elem.currentStyle[ camelCase ];
-
-			// From the awesome hack by Dean Edwards
-			// http://erik.eae.net/archives/2007/07/27/18.54.15/#comment-102291
-
-			// If we're not dealing with a regular pixel number
-			// but a number that has a weird ending, we need to convert it to pixels
-			if ( !/^\d+(px)?$/i.test( ret ) &amp;&amp; /^\d/.test( ret ) ) {
-				// Remember the original values
-				var left = style.left, rsLeft = elem.runtimeStyle.left;
-
-				// Put in the new values to get a computed value out
-				elem.runtimeStyle.left = elem.currentStyle.left;
-				style.left = ret || 0;
-				ret = style.pixelLeft + &quot;px&quot;;
-
-				// Revert the changed values
-				style.left = left;
-				elem.runtimeStyle.left = rsLeft;
-			}
-		}
-
-		return ret;
-	},
-
-	clean: function( elems, context ) {
-		var ret = [];
-		context = context || document;
-		// !context.createElement fails in IE with an error but returns typeof 'object'
-		if (typeof context.createElement == 'undefined')
-			context = context.ownerDocument || context[0] &amp;&amp; context[0].ownerDocument || document;
-
-		jQuery.each(elems, function(i, elem){
-			if ( !elem )
-				return;
-
-			if ( elem.constructor == Number )
-				elem += '';
-
-			// Convert html string into DOM nodes
-			if ( typeof elem == &quot;string&quot; ) {
-				// Fix &quot;XHTML&quot;-style tags in all browsers
-				elem = elem.replace(/(&lt;(\w+)[^&gt;]*?)\/&gt;/g, function(all, front, tag){
-					return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i) ?
-						all :
-						front + &quot;&gt;&lt;/&quot; + tag + &quot;&gt;&quot;;
-				});
-
-				// Trim whitespace, otherwise indexOf won't work as expected
-				var tags = jQuery.trim( elem ).toLowerCase(), div = context.createElement(&quot;div&quot;);
-
-				var wrap =
-					// option or optgroup
-					!tags.indexOf(&quot;&lt;opt&quot;) &amp;&amp;
-					[ 1, &quot;&lt;select multiple='multiple'&gt;&quot;, &quot;&lt;/select&gt;&quot; ] ||
-
-					!tags.indexOf(&quot;&lt;leg&quot;) &amp;&amp;
-					[ 1, &quot;&lt;fieldset&gt;&quot;, &quot;&lt;/fieldset&gt;&quot; ] ||
-
-					tags.match(/^&lt;(thead|tbody|tfoot|colg|cap)/) &amp;&amp;
-					[ 1, &quot;&lt;table&gt;&quot;, &quot;&lt;/table&gt;&quot; ] ||
-
-					!tags.indexOf(&quot;&lt;tr&quot;) &amp;&amp;
-					[ 2, &quot;&lt;table&gt;&lt;tbody&gt;&quot;, &quot;&lt;/tbody&gt;&lt;/table&gt;&quot; ] ||
-
-				 	// &lt;thead&gt; matched above
-					(!tags.indexOf(&quot;&lt;td&quot;) || !tags.indexOf(&quot;&lt;th&quot;)) &amp;&amp;
-					[ 3, &quot;&lt;table&gt;&lt;tbody&gt;&lt;tr&gt;&quot;, &quot;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&quot; ] ||
-
-					!tags.indexOf(&quot;&lt;col&quot;) &amp;&amp;
-					[ 2, &quot;&lt;table&gt;&lt;tbody&gt;&lt;/tbody&gt;&lt;colgroup&gt;&quot;, &quot;&lt;/colgroup&gt;&lt;/table&gt;&quot; ] ||
-
-					// IE can't serialize &lt;link&gt; and &lt;script&gt; tags normally
-					jQuery.browser.msie &amp;&amp;
-					[ 1, &quot;div&lt;div&gt;&quot;, &quot;&lt;/div&gt;&quot; ] ||
-
-					[ 0, &quot;&quot;, &quot;&quot; ];
-
-				// Go to html and back, then peel off extra wrappers
-				div.innerHTML = wrap[1] + elem + wrap[2];
-
-				// Move to the right depth
-				while ( wrap[0]-- )
-					div = div.lastChild;
-
-				// Remove IE's autoinserted &lt;tbody&gt; from table fragments
-				if ( jQuery.browser.msie ) {
-
-					// String was a &lt;table&gt;, *may* have spurious &lt;tbody&gt;
-					var tbody = !tags.indexOf(&quot;&lt;table&quot;) &amp;&amp; tags.indexOf(&quot;&lt;tbody&quot;) &lt; 0 ?
-						div.firstChild &amp;&amp; div.firstChild.childNodes :
-
-						// String was a bare &lt;thead&gt; or &lt;tfoot&gt;
-						wrap[1] == &quot;&lt;table&gt;&quot; &amp;&amp; tags.indexOf(&quot;&lt;tbody&quot;) &lt; 0 ?
-							div.childNodes :
-							[];
-
-					for ( var j = tbody.length - 1; j &gt;= 0 ; --j )
-						if ( jQuery.nodeName( tbody[ j ], &quot;tbody&quot; ) &amp;&amp; !tbody[ j ].childNodes.length )
-							tbody[ j ].parentNode.removeChild( tbody[ j ] );
-
-					// IE completely kills leading whitespace when innerHTML is used
-					if ( /^\s/.test( elem ) )
-						div.insertBefore( context.createTextNode( elem.match(/^\s*/)[0] ), div.firstChild );
-
-				}
-
-				elem = jQuery.makeArray( div.childNodes );
-			}
-
-			if ( elem.length === 0 &amp;&amp; (!jQuery.nodeName( elem, &quot;form&quot; ) &amp;&amp; !jQuery.nodeName( elem, &quot;select&quot; )) )
-				return;
-
-			if ( elem[0] == undefined || jQuery.nodeName( elem, &quot;form&quot; ) || elem.options )
-				ret.push( elem );
-
-			else
-				ret = jQuery.merge( ret, elem );
-
-		});
-
-		return ret;
-	},
-
-	attr: function( elem, name, value ) {
-		// don't set attributes on text and comment nodes
-		if (!elem || elem.nodeType == 3 || elem.nodeType == 8)
-			return undefined;
-
-		var notxml = !jQuery.isXMLDoc( elem ),
-			// Whether we are setting (or getting)
-			set = value !== undefined,
-			msie = jQuery.browser.msie;
-
-		// Try to normalize/fix the name
-		name = notxml &amp;&amp; jQuery.props[ name ] || name;
-
-		// Only do all the following if this is a node (faster for style)
-		// IE elem.getAttribute passes even for style
-		if ( elem.tagName ) {
-
-			// These attributes require special treatment
-			var special = /href|src|style/.test( name );
-
-			// Safari mis-reports the default selected property of a hidden option
-			// Accessing the parent's selectedIndex property fixes it
-			if ( name == &quot;selected&quot; &amp;&amp; jQuery.browser.safari )
-				elem.parentNode.selectedIndex;
-
-			// If applicable, access the attribute via the DOM 0 way
-			if ( name in elem &amp;&amp; notxml &amp;&amp; !special ) {
-				if ( set ){
-					// We can't allow the type property to be changed (since it causes problems in IE)
-					if ( name == &quot;type&quot; &amp;&amp; jQuery.nodeName( elem, &quot;input&quot; ) &amp;&amp; elem.parentNode )
-						throw &quot;type property can't be changed&quot;;
-
-					elem[ name ] = value;
-				}
-
-				// browsers index elements by id/name on forms, give priority to attributes.
-				if( jQuery.nodeName( elem, &quot;form&quot; ) &amp;&amp; elem.getAttributeNode(name) )
-					return elem.getAttributeNode( name ).nodeValue;
-
-				return elem[ name ];
-			}
-
-			if ( msie &amp;&amp; notxml &amp;&amp;  name == &quot;style&quot; )
-				return jQuery.attr( elem.style, &quot;cssText&quot;, value );
-
-			if ( set )
-				// convert the value to a string (all browsers do this but IE) see #1070
-				elem.setAttribute( name, &quot;&quot; + value );
-
-			var attr = msie &amp;&amp; notxml &amp;&amp; special
-					// Some attributes require a special call on IE
-					? elem.getAttribute( name, 2 )
-					: elem.getAttribute( name );
-
-			// Non-existent attributes return null, we normalize to undefined
-			return attr === null ? undefined : attr;
-		}
-
-		// elem is actually elem.style ... set the style
-
-		// IE uses filters for opacity
-		if ( msie &amp;&amp; name == &quot;opacity&quot; ) {
-			if ( set ) {
-				// IE has trouble with opacity if it does not have layout
-				// Force it by setting the zoom level
-				elem.zoom = 1;
-
-				// Set the alpha filter to set the opacity
-				elem.filter = (elem.filter || &quot;&quot;).replace( /alpha\([^)]*\)/, &quot;&quot; ) +
-					(parseInt( value ) + '' == &quot;NaN&quot; ? &quot;&quot; : &quot;alpha(opacity=&quot; + value * 100 + &quot;)&quot;);
-			}
-
-			return elem.filter &amp;&amp; elem.filter.indexOf(&quot;opacity=&quot;) &gt;= 0 ?
-				(parseFloat( elem.filter.match(/opacity=([^)]*)/)[1] ) / 100) + '':
-				&quot;&quot;;
-		}
-
-		name = name.replace(/-([a-z])/ig, function(all, letter){
-			return letter.toUpperCase();
-		});
-
-		if ( set )
-			elem[ name ] = value;
-
-		return elem[ name ];
-	},
-
-	trim: function( text ) {
-		return (text || &quot;&quot;).replace( /^\s+|\s+$/g, &quot;&quot; );
-	},
-
-	makeArray: function( array ) {
-		var ret = [];
-
-		if( array != null ){
-			var i = array.length;
-			//the window, strings and functions also have 'length'
-			if( i == null || array.split || array.setInterval || array.call )
-				ret[0] = array;
-			else
-				while( i )
-					ret[--i] = array[i];
-		}
-
-		return ret;
-	},
-
-	inArray: function( elem, array ) {
-		for ( var i = 0, length = array.length; i &lt; length; i++ )
-		// Use === because on IE, window == document
-			if ( array[ i ] === elem )
-				return i;
-
-		return -1;
-	},
-
-	merge: function( first, second ) {
-		// We have to loop this way because IE &amp; Opera overwrite the length
-		// expando of getElementsByTagName
-		var i = 0, elem, pos = first.length;
-		// Also, we need to make sure that the correct elements are being returned
-		// (IE returns comment nodes in a '*' query)
-		if ( jQuery.browser.msie ) {
-			while ( elem = second[ i++ ] )
-				if ( elem.nodeType != 8 )
-					first[ pos++ ] = elem;
-
-		} else
-			while ( elem = second[ i++ ] )
-				first[ pos++ ] = elem;
-
-		return first;
-	},
-
-	unique: function( array ) {
-		var ret = [], done = {};
-
-		try {
-
-			for ( var i = 0, length = array.length; i &lt; length; i++ ) {
-				var id = jQuery.data( array[ i ] );
-
-				if ( !done[ id ] ) {
-					done[ id ] = true;
-					ret.push( array[ i ] );
-				}
-			}
-
-		} catch( e ) {
-			ret = array;
-		}
-
-		return ret;
-	},
-
-	grep: function( elems, callback, inv ) {
-		var ret = [];
-
-		// Go through the array, only saving the items
-		// that pass the validator function
-		for ( var i = 0, length = elems.length; i &lt; length; i++ )
-			if ( !inv != !callback( elems[ i ], i ) )
-				ret.push( elems[ i ] );
-
-		return ret;
-	},
-
-	map: function( elems, callback ) {
-		var ret = [];
-
-		// Go through the array, translating each of the items to their
-		// new value (or values).
-		for ( var i = 0, length = elems.length; i &lt; length; i++ ) {
-			var value = callback( elems[ i ], i );
-
-			if ( value != null )
-				ret[ ret.length ] = value;
-		}
-
-		return ret.concat.apply( [], ret );
-	}
-});
-
-var userAgent = navigator.userAgent.toLowerCase();
-
-// Figure out what browser is being used
-jQuery.browser = {
-	version: (userAgent.match( /.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/ ) || [])[1],
-	safari: /webkit/.test( userAgent ),
-	opera: /opera/.test( userAgent ),
-	msie: /msie/.test( userAgent ) &amp;&amp; !/opera/.test( userAgent ),
-	mozilla: /mozilla/.test( userAgent ) &amp;&amp; !/(compatible|webkit)/.test( userAgent )
-};
-
-var styleFloat = jQuery.browser.msie ?
-	&quot;styleFloat&quot; :
-	&quot;cssFloat&quot;;
-
-jQuery.extend({
-	// Check to see if the W3C box model is being used
-	boxModel: !jQuery.browser.msie || document.compatMode == &quot;CSS1Compat&quot;,
-
-	props: {
-		&quot;for&quot;: &quot;htmlFor&quot;,
-		&quot;class&quot;: &quot;className&quot;,
-		&quot;float&quot;: styleFloat,
-		cssFloat: styleFloat,
-		styleFloat: styleFloat,
-		readonly: &quot;readOnly&quot;,
-		maxlength: &quot;maxLength&quot;,
-		cellspacing: &quot;cellSpacing&quot;
-	}
-});
-
-jQuery.each({
-	parent: function(elem){return elem.parentNode;},
-	parents: function(elem){return jQuery.dir(elem,&quot;parentNode&quot;);},
-	next: function(elem){return jQuery.nth(elem,2,&quot;nextSibling&quot;);},
-	prev: function(elem){return jQuery.nth(elem,2,&quot;previousSibling&quot;);},
-	nextAll: function(elem){return jQuery.dir(elem,&quot;nextSibling&quot;);},
-	prevAll: function(elem){return jQuery.dir(elem,&quot;previousSibling&quot;);},
-	siblings: function(elem){return jQuery.sibling(elem.parentNode.firstChild,elem);},
-	children: function(elem){return jQuery.sibling(elem.firstChild);},
-	contents: function(elem){return jQuery.nodeName(elem,&quot;iframe&quot;)?elem.contentDocument||elem.contentWindow.document:jQuery.makeArray(elem.childNodes);}
-}, function(name, fn){
-	jQuery.fn[ name ] = function( selector ) {
-		var ret = jQuery.map( this, fn );
-
-		if ( selector &amp;&amp; typeof selector == &quot;string&quot; )
-			ret = jQuery.multiFilter( selector, ret );
-
-		return this.pushStack( jQuery.unique( ret ) );
-	};
-});
-
-jQuery.each({
-	appendTo: &quot;append&quot;,
-	prependTo: &quot;prepend&quot;,
-	insertBefore: &quot;before&quot;,
-	insertAfter: &quot;after&quot;,
-	replaceAll: &quot;replaceWith&quot;
-}, function(name, original){
-	jQuery.fn[ name ] = function() {
-		var args = arguments;
-
-		return this.each(function(){
-			for ( var i = 0, length = args.length; i &lt; length; i++ )
-				jQuery( args[ i ] )[ original ]( this );
-		});
-	};
-});
-
-jQuery.each({
-	removeAttr: function( name ) {
-		jQuery.attr( this, name, &quot;&quot; );
-		if (this.nodeType == 1)
-			this.removeAttribute( name );
-	},
-
-	addClass: function( classNames ) {
-		jQuery.className.add( this, classNames );
-	},
-
-	removeClass: function( classNames ) {
-		jQuery.className.remove( this, classNames );
-	},
-
-	toggleClass: function( classNames ) {
-		jQuery.className[ jQuery.className.has( this, classNames ) ? &quot;remove&quot; : &quot;add&quot; ]( this, classNames );
-	},
-
-	remove: function( selector ) {
-		if ( !selector || jQuery.filter( selector, [ this ] ).r.length ) {
-			// Prevent memory leaks
-			jQuery( &quot;*&quot;, this ).add(this).each(function(){
-				jQuery.event.remove(this);
-				jQuery.removeData(this);
-			});
-			if (this.parentNode)
-				this.parentNode.removeChild( this );
-		}
-	},
-
-	empty: function() {
-		// Remove element nodes and prevent memory leaks
-		jQuery( &quot;&gt;*&quot;, this ).remove();
-
-		// Remove any remaining nodes
-		while ( this.firstChild )
-			this.removeChild( this.firstChild );
-	}
-}, function(name, fn){
-	jQuery.fn[ name ] = function(){
-		return this.each( fn, arguments );
-	};
-});
-
-jQuery.each([ &quot;Height&quot;, &quot;Width&quot; ], function(i, name){
-	var type = name.toLowerCase();
-
-	jQuery.fn[ type ] = function( size ) {
-		// Get window width or height
-		return this[0] == window ?
-			// Opera reports document.body.client[Width/Height] properly in both quirks and standards
-			jQuery.browser.opera &amp;&amp; document.body[ &quot;client&quot; + name ] ||
-
-			// Safari reports inner[Width/Height] just fine (Mozilla and Opera include scroll bar widths)
-			jQuery.browser.safari &amp;&amp; window[ &quot;inner&quot; + name ] ||
-
-			// Everyone else use document.documentElement or document.body depending on Quirks vs Standards mode
-			document.compatMode == &quot;CSS1Compat&quot; &amp;&amp; document.documentElement[ &quot;client&quot; + name ] || document.body[ &quot;client&quot; + name ] :
-
-			// Get document width or height
-			this[0] == document ?
-				// Either scroll[Width/Height] or offset[Width/Height], whichever is greater
-				Math.max(
-					Math.max(document.body[&quot;scroll&quot; + name], document.documentElement[&quot;scroll&quot; + name]),
-					Math.max(document.body[&quot;offset&quot; + name], document.documentElement[&quot;offset&quot; + name])
-				) :
-
-				// Get or set width or height on the element
-				size == undefined ?
-					// Get width or height on the element
-					(this.length ? jQuery.css( this[0], type ) : null) :
-
-					// Set the width or height on the element (default to pixels if value is unitless)
-					this.css( type, size.constructor == String ? size : size + &quot;px&quot; );
-	};
-});
-
-// Helper function used by the dimensions and offset modules
-function num(elem, prop) {
-	return elem[0] &amp;&amp; parseInt( jQuery.curCSS(elem[0], prop, true), 10 ) || 0;
-}var chars = jQuery.browser.safari &amp;&amp; parseInt(jQuery.browser.version) &lt; 417 ?
-		&quot;(?:[\\w*_-]|\\\\.)&quot; :
-		&quot;(?:[\\w\u0128-\uFFFF*_-]|\\\\.)&quot;,
-	quickChild = new RegExp(&quot;^&gt;\\s*(&quot; + chars + &quot;+)&quot;),
-	quickID = new RegExp(&quot;^(&quot; + chars + &quot;+)(#)(&quot; + chars + &quot;+)&quot;),
-	quickClass = new RegExp(&quot;^([#.]?)(&quot; + chars + &quot;*)&quot;);
-
-jQuery.extend({
-	expr: {
-		&quot;&quot;: function(a,i,m){return m[2]==&quot;*&quot;||jQuery.nodeName(a,m[2]);},
-		&quot;#&quot;: function(a,i,m){return a.getAttribute(&quot;id&quot;)==m[2];},
-		&quot;:&quot;: {
-			// Position Checks
-			lt: function(a,i,m){return i&lt;m[3]-0;},
-			gt: function(a,i,m){return i&gt;m[3]-0;},
-			nth: function(a,i,m){return m[3]-0==i;},
-			eq: function(a,i,m){return m[3]-0==i;},
-			first: function(a,i){return i==0;},
-			last: function(a,i,m,r){return i==r.length-1;},
-			even: function(a,i){return i%2==0;},
-			odd: function(a,i){return i%2;},
-
-			// Child Checks
-			&quot;first-child&quot;: function(a){return a.parentNode.getElementsByTagName(&quot;*&quot;)[0]==a;},
-			&quot;last-child&quot;: function(a){return jQuery.nth(a.parentNode.lastChild,1,&quot;previousSibling&quot;)==a;},
-			&quot;only-child&quot;: function(a){return !jQuery.nth(a.parentNode.lastChild,2,&quot;previousSibling&quot;);},
-
-			// Parent Checks
-			parent: function(a){return a.firstChild;},
-			empty: function(a){return !a.firstChild;},
-
-			// Text Check
-			contains: function(a,i,m){return (a.textContent||a.innerText||jQuery(a).text()||&quot;&quot;).indexOf(m[3])&gt;=0;},
-
-			// Visibility
-			visible: function(a){return &quot;hidden&quot;!=a.type&amp;&amp;jQuery.css(a,&quot;display&quot;)!=&quot;none&quot;&amp;&amp;jQuery.css(a,&quot;visibility&quot;)!=&quot;hidden&quot;;},
-			hidden: function(a){return &quot;hidden&quot;==a.type||jQuery.css(a,&quot;display&quot;)==&quot;none&quot;||jQuery.css(a,&quot;visibility&quot;)==&quot;hidden&quot;;},
-
-			// Form attributes
-			enabled: function(a){return !a.disabled;},
-			disabled: function(a){return a.disabled;},
-			checked: function(a){return a.checked;},
-			selected: function(a){return a.selected||jQuery.attr(a,&quot;selected&quot;);},
-
-			// Form elements
-			text: function(a){return &quot;text&quot;==a.type;},
-			radio: function(a){return &quot;radio&quot;==a.type;},
-			checkbox: function(a){return &quot;checkbox&quot;==a.type;},
-			file: function(a){return &quot;file&quot;==a.type;},
-			password: function(a){return &quot;password&quot;==a.type;},
-			submit: function(a){return &quot;submit&quot;==a.type;},
-			image: function(a){return &quot;image&quot;==a.type;},
-			reset: function(a){return &quot;reset&quot;==a.type;},
-			button: function(a){return &quot;button&quot;==a.type||jQuery.nodeName(a,&quot;button&quot;);},
-			input: function(a){return /input|select|textarea|button/i.test(a.nodeName);},
-
-			// :has()
-			has: function(a,i,m){return jQuery.find(m[3],a).length;},
-
-			// :header
-			header: function(a){return /h\d/i.test(a.nodeName);},
-
-			// :animated
-			animated: function(a){return jQuery.grep(jQuery.timers,function(fn){return a==fn.elem;}).length;}
-		}
-	},
-
-	// The regular expressions that power the parsing engine
-	parse: [
-		// Match: [@value='test'], [@foo]
-		/^(\[) *@?([\w-]+) *([!*$^~=]*) *('?&quot;?)(.*?)\4 *\]/,
-
-		// Match: :contains('foo')
-		/^(:)([\w-]+)\(&quot;?'?(.*?(\(.*?\))?[^(]*?)&quot;?'?\)/,
-
-		// Match: :even, :last-child, #id, .class
-		new RegExp(&quot;^([:.#]*)(&quot; + chars + &quot;+)&quot;)
-	],
-
-	multiFilter: function( expr, elems, not ) {
-		var old, cur = [];
-
-		while ( expr &amp;&amp; expr != old ) {
-			old = expr;
-			var f = jQuery.filter( expr, elems, not );
-			expr = f.t.replace(/^\s*,\s*/, &quot;&quot; );
-			cur = not ? elems = f.r : jQuery.merge( cur, f.r );
-		}
-
-		return cur;
-	},
-
-	find: function( t, context ) {
-		// Quickly handle non-string expressions
-		if ( typeof t != &quot;string&quot; )
-			return [ t ];
-
-		// check to make sure context is a DOM element or a document
-		if ( context &amp;&amp; context.nodeType != 1 &amp;&amp; context.nodeType != 9)
-			return [ ];
-
-		// Set the correct context (if none is provided)
-		context = context || document;
-
-		// Initialize the search
-		var ret = [context], done = [], last, nodeName;
-
-		// Continue while a selector expression exists, and while
-		// we're no longer looping upon ourselves
-		while ( t &amp;&amp; last != t ) {
-			var r = [];
-			last = t;
-
-			t = jQuery.trim(t);
-
-			var foundToken = false,
-
-			// An attempt at speeding up child selectors that
-			// point to a specific element tag
-				re = quickChild,
-
-				m = re.exec(t);
-
-			if ( m ) {
-				nodeName = m[1].toUpperCase();
-
-				// Perform our own iteration and filter
-				for ( var i = 0; ret[i]; i++ )
-					for ( var c = ret[i].firstChild; c; c = c.nextSibling )
-						if ( c.nodeType == 1 &amp;&amp; (nodeName == &quot;*&quot; || c.nodeName.toUpperCase() == nodeName) )
-							r.push( c );
-
-				ret = r;
-				t = t.replace( re, &quot;&quot; );
-				if ( t.indexOf(&quot; &quot;) == 0 ) continue;
-				foundToken = true;
-			} else {
-				re = /^([&gt;+~])\s*(\w*)/i;
-
-				if ( (m = re.exec(t)) != null ) {
-					r = [];
-
-					var merge = {};
-					nodeName = m[2].toUpperCase();
-					m = m[1];
-
-					for ( var j = 0, rl = ret.length; j &lt; rl; j++ ) {
-						var n = m == &quot;~&quot; || m == &quot;+&quot; ? ret[j].nextSibling : ret[j].firstChild;
-						for ( ; n; n = n.nextSibling )
-							if ( n.nodeType == 1 ) {
-								var id = jQuery.data(n);
-
-								if ( m == &quot;~&quot; &amp;&amp; merge[id] ) break;
-
-								if (!nodeName || n.nodeName.toUpperCase() == nodeName ) {
-									if ( m == &quot;~&quot; ) merge[id] = true;
-									r.push( n );
-								}
-
-								if ( m == &quot;+&quot; ) break;
-							}
-					}
-
-					ret = r;
-
-					// And remove the token
-					t = jQuery.trim( t.replace( re, &quot;&quot; ) );
-					foundToken = true;
-				}
-			}
-
-			// See if there's still an expression, and that we haven't already
-			// matched a token
-			if ( t &amp;&amp; !foundToken ) {
-				// Handle multiple expressions
-				if ( !t.indexOf(&quot;,&quot;) ) {
-					// Clean the result set
-					if ( context == ret[0] ) ret.shift();
-
-					// Merge the result sets
-					done = jQuery.merge( done, ret );
-
-					// Reset the context
-					r = ret = [context];
-
-					// Touch up the selector string
-					t = &quot; &quot; + t.substr(1,t.length);
-
-				} else {
-					// Optimize for the case nodeName#idName
-					var re2 = quickID;
-					var m = re2.exec(t);
-
-					// Re-organize the results, so that they're consistent
-					if ( m ) {
-						m = [ 0, m[2], m[3], m[1] ];
-
-					} else {
-						// Otherwise, do a traditional filter check for
-						// ID, class, and element selectors
-						re2 = quickClass;
-						m = re2.exec(t);
-					}
-
-					m[2] = m[2].replace(/\\/g, &quot;&quot;);
-
-					var elem = ret[ret.length-1];
-
-					// Try to do a global search by ID, where we can
-					if ( m[1] == &quot;#&quot; &amp;&amp; elem &amp;&amp; elem.getElementById &amp;&amp; !jQuery.isXMLDoc(elem) ) {
-						// Optimization for HTML document case
-						var oid = elem.getElementById(m[2]);
-
-						// Do a quick check for the existence of the actual ID attribute
-						// to avoid selecting by the name attribute in IE
-						// also check to insure id is a string to avoid selecting an element with the name of 'id' inside a form
-						if ( (jQuery.browser.msie||jQuery.browser.opera) &amp;&amp; oid &amp;&amp; typeof oid.id == &quot;string&quot; &amp;&amp; oid.id != m[2] )
-							oid = jQuery('[@id=&quot;'+m[2]+'&quot;]', elem)[0];
-
-						// Do a quick check for node name (where applicable) so
-						// that div#foo searches will be really fast
-						ret = r = oid &amp;&amp; (!m[3] || jQuery.nodeName(oid, m[3])) ? [oid] : [];
-					} else {
-						// We need to find all descendant elements
-						for ( var i = 0; ret[i]; i++ ) {
-							// Grab the tag name being searched for
-							var tag = m[1] == &quot;#&quot; &amp;&amp; m[3] ? m[3] : m[1] != &quot;&quot; || m[0] == &quot;&quot; ? &quot;*&quot; : m[2];
-
-							// Handle IE7 being really dumb about &lt;object&gt;s
-							if ( tag == &quot;*&quot; &amp;&amp; ret[i].nodeName.toLowerCase() == &quot;object&quot; )
-								tag = &quot;param&quot;;
-
-							r = jQuery.merge( r, ret[i].getElementsByTagName( tag ));
-						}
-
-						// It's faster to filter by class and be done with it
-						if ( m[1] == &quot;.&quot; )
-							r = jQuery.classFilter( r, m[2] );
-
-						// Same with ID filtering
-						if ( m[1] == &quot;#&quot; ) {
-							var tmp = [];
-
-							// Try to find the element with the ID
-							for ( var i = 0; r[i]; i++ )
-								if ( r[i].getAttribute(&quot;id&quot;) == m[2] ) {
-									tmp = [ r[i] ];
-									break;
-								}
-
-							r = tmp;
-						}
-
-						ret = r;
-					}
-
-					t = t.replace( re2, &quot;&quot; );
-				}
-
-			}
-
-			// If a selector string still exists
-			if ( t ) {
-				// Attempt to filter it
-				var val = jQuery.filter(t,r);
-				ret = r = val.r;
-				t = jQuery.trim(val.t);
-			}
-		}
-
-		// An error occurred with the selector;
-		// just return an empty set instead
-		if ( t )
-			ret = [];
-
-		// Remove the root context
-		if ( ret &amp;&amp; context == ret[0] )
-			ret.shift();
-
-		// And combine the results
-		done = jQuery.merge( done, ret );
-
-		return done;
-	},
-
-	classFilter: function(r,m,not){
-		m = &quot; &quot; + m + &quot; &quot;;
-		var tmp = [];
-		for ( var i = 0; r[i]; i++ ) {
-			var pass = (&quot; &quot; + r[i].className + &quot; &quot;).indexOf( m ) &gt;= 0;
-			if ( !not &amp;&amp; pass || not &amp;&amp; !pass )
-				tmp.push( r[i] );
-		}
-		return tmp;
-	},
-
-	filter: function(t,r,not) {
-		var last;
-
-		// Look for common filter expressions
-		while ( t &amp;&amp; t != last ) {
-			last = t;
-
-			var p = jQuery.parse, m;
-
-			for ( var i = 0; p[i]; i++ ) {
-				m = p[i].exec( t );
-
-				if ( m ) {
-					// Remove what we just matched
-					t = t.substring( m[0].length );
-
-					m[2] = m[2].replace(/\\/g, &quot;&quot;);
-					break;
-				}
-			}
-
-			if ( !m )
-				break;
-
-			// :not() is a special case that can be optimized by
-			// keeping it out of the expression list
-			if ( m[1] == &quot;:&quot; &amp;&amp; m[2] == &quot;not&quot; )
-				// optimize if only one selector found (most common case)
-				r = isSimple.test( m[3] ) ?
-					jQuery.filter(m[3], r, true).r :
-					jQuery( r ).not( m[3] );
-
-			// We can get a big speed boost by filtering by class here
-			else if ( m[1] == &quot;.&quot; )
-				r = jQuery.classFilter(r, m[2], not);
-
-			else if ( m[1] == &quot;[&quot; ) {
-				var tmp = [], type = m[3];
-
-				for ( var i = 0, rl = r.length; i &lt; rl; i++ ) {
-					var a = r[i], z = a[ jQuery.props[m[2]] || m[2] ];
-
-					if ( z == null || /href|src|selected/.test(m[2]) )
-						z = jQuery.attr(a,m[2]) || '';
-
-					if ( (type == &quot;&quot; &amp;&amp; !!z ||
-						 type == &quot;=&quot; &amp;&amp; z == m[5] ||
-						 type == &quot;!=&quot; &amp;&amp; z != m[5] ||
-						 type == &quot;^=&quot; &amp;&amp; z &amp;&amp; !z.indexOf(m[5]) ||
-						 type == &quot;$=&quot; &amp;&amp; z.substr(z.length - m[5].length) == m[5] ||
-						 (type == &quot;*=&quot; || type == &quot;~=&quot;) &amp;&amp; z.indexOf(m[5]) &gt;= 0) ^ not )
-							tmp.push( a );
-				}
-
-				r = tmp;
-
-			// We can get a speed boost by handling nth-child here
-			} else if ( m[1] == &quot;:&quot; &amp;&amp; m[2] == &quot;nth-child&quot; ) {
-				var merge = {}, tmp = [],
-					// parse equations like 'even', 'odd', '5', '2n', '3n+2', '4n-1', '-n+6'
-					test = /(-?)(\d*)n((?:\+|-)?\d*)/.exec(
-						m[3] == &quot;even&quot; &amp;&amp; &quot;2n&quot; || m[3] == &quot;odd&quot; &amp;&amp; &quot;2n+1&quot; ||
-						!/\D/.test(m[3]) &amp;&amp; &quot;0n+&quot; + m[3] || m[3]),
-					// calculate the numbers (first)n+(last) including if they are negative
-					first = (test[1] + (test[2] || 1)) - 0, last = test[3] - 0;
-
-				// loop through all the elements left in the jQuery object
-				for ( var i = 0, rl = r.length; i &lt; rl; i++ ) {
-					var node = r[i], parentNode = node.parentNode, id = jQuery.data(parentNode);
-
-					if ( !merge[id] ) {
-						var c = 1;
-
-						for ( var n = parentNode.firstChild; n; n = n.nextSibling )
-							if ( n.nodeType == 1 )
-								n.nodeIndex = c++;
-
-						merge[id] = true;
-					}
-
-					var add = false;
-
-					if ( first == 0 ) {
-						if ( node.nodeIndex == last )
-							add = true;
-					} else if ( (node.nodeIndex - last) % first == 0 &amp;&amp; (node.nodeIndex - last) / first &gt;= 0 )
-						add = true;
-
-					if ( add ^ not )
-						tmp.push( node );
-				}
-
-				r = tmp;
-
-			// Otherwise, find the expression to execute
-			} else {
-				var fn = jQuery.expr[ m[1] ];
-				if ( typeof fn == &quot;object&quot; )
-					fn = fn[ m[2] ];
-
-				if ( typeof fn == &quot;string&quot; )
-					fn = eval(&quot;false||function(a,i){return &quot; + fn + &quot;;}&quot;);
-
-				// Execute it against the current filter
-				r = jQuery.grep( r, function(elem, i){
-					return fn(elem, i, m, r);
-				}, not );
-			}
-		}
-
-		// Return an array of filtered elements (r)
-		// and the modified expression string (t)
-		return { r: r, t: t };
-	},
-
-	dir: function( elem, dir ){
-		var matched = [],
-			cur = elem[dir];
-		while ( cur &amp;&amp; cur != document ) {
-			if ( cur.nodeType == 1 )
-				matched.push( cur );
-			cur = cur[dir];
-		}
-		return matched;
-	},
-
-	nth: function(cur,result,dir,elem){
-		result = result || 1;
-		var num = 0;
-
-		for ( ; cur; cur = cur[dir] )
-			if ( cur.nodeType == 1 &amp;&amp; ++num == result )
-				break;
-
-		return cur;
-	},
-
-	sibling: function( n, elem ) {
-		var r = [];
-
-		for ( ; n; n = n.nextSibling ) {
-			if ( n.nodeType == 1 &amp;&amp; n != elem )
-				r.push( n );
-		}
-
-		return r;
-	}
-});
-/*
- * A number of helper functions used for managing events.
- * Many of the ideas behind this code orignated from
- * Dean Edwards' addEvent library.
- */
-jQuery.event = {
-
-	// Bind an event to an element
-	// Original by Dean Edwards
-	add: function(elem, types, handler, data) {
-		if ( elem.nodeType == 3 || elem.nodeType == 8 )
-			return;
-
-		// For whatever reason, IE has trouble passing the window object
-		// around, causing it to be cloned in the process
-		if ( jQuery.browser.msie &amp;&amp; elem.setInterval )
-			elem = window;
-
-		// Make sure that the function being executed has a unique ID
-		if ( !handler.guid )
-			handler.guid = this.guid++;
-
-		// if data is passed, bind to handler
-		if( data != undefined ) {
-			// Create temporary function pointer to original handler
-			var fn = handler;
-
-			// Create unique handler function, wrapped around original handler
-			handler = this.proxy( fn, function() {
-				// Pass arguments and context to original handler
-				return fn.apply(this, arguments);
-			});
-
-			// Store data in unique handler
-			handler.data = data;
-		}
-
-		// Init the element's event structure
-		var events = jQuery.data(elem, &quot;events&quot;) || jQuery.data(elem, &quot;events&quot;, {}),
-			handle = jQuery.data(elem, &quot;handle&quot;) || jQuery.data(elem, &quot;handle&quot;, function(){
-				// Handle the second event of a trigger and when
-				// an event is called after a page has unloaded
-				if ( typeof jQuery != &quot;undefined&quot; &amp;&amp; !jQuery.event.triggered )
-					return jQuery.event.handle.apply(arguments.callee.elem, arguments);
-			});
-		// Add elem as a property of the handle function
-		// This is to prevent a memory leak with non-native
-		// event in IE.
-		handle.elem = elem;
-
-		// Handle multiple events separated by a space
-		// jQuery(...).bind(&quot;mouseover mouseout&quot;, fn);
-		jQuery.each(types.split(/\s+/), function(index, type) {
-			// Namespaced event handlers
-			var parts = type.split(&quot;.&quot;);
-			type = parts[0];
-			handler.type = parts[1];
-
-			// Get the current list of functions bound to this event
-			var handlers = events[type];
-
-			// Init the event handler queue
-			if (!handlers) {
-				handlers = events[type] = {};
-
-				// Check for a special event handler
-				// Only use addEventListener/attachEvent if the special
-				// events handler returns false
-				if ( !jQuery.event.special[type] || jQuery.event.special[type].setup.call(elem) === false ) {
-					// Bind the global event handler to the element
-					if (elem.addEventListener)
-						elem.addEventListener(type, handle, false);
-					else if (elem.attachEvent)
-						elem.attachEvent(&quot;on&quot; + type, handle);
-				}
-			}
-
-			// Add the function to the element's handler list
-			handlers[handler.guid] = handler;
-
-			// Keep track of which events have been used, for global triggering
-			jQuery.event.global[type] = true;
-		});
-
-		// Nullify elem to prevent memory leaks in IE
-		elem = null;
-	},
-
-	guid: 1,
-	global: {},
-
-	// Detach an event or set of events from an element
-	remove: function(elem, types, handler) {
-		// don't do events on text and comment nodes
-		if ( elem.nodeType == 3 || elem.nodeType == 8 )
-			return;
-
-		var events = jQuery.data(elem, &quot;events&quot;), ret, index;
-
-		if ( events ) {
-			// Unbind all events for the element
-			if ( types == undefined || (typeof types == &quot;string&quot; &amp;&amp; types.charAt(0) == &quot;.&quot;) )
-				for ( var type in events )
-					this.remove( elem, type + (types || &quot;&quot;) );
-			else {
-				// types is actually an event object here
-				if ( types.type ) {
-					handler = types.handler;
-					types = types.type;
-				}
-
-				// Handle multiple events seperated by a space
-				// jQuery(...).unbind(&quot;mouseover mouseout&quot;, fn);
-				jQuery.each(types.split(/\s+/), function(index, type){
-					// Namespaced event handlers
-					var parts = type.split(&quot;.&quot;);
-					type = parts[0];
-
-					if ( events[type] ) {
-						// remove the given handler for the given type
-						if ( handler )
-							delete events[type][handler.guid];
-
-						// remove all handlers for the given type
-						else
-							for ( handler in events[type] )
-								// Handle the removal of namespaced events
-								if ( !parts[1] || events[type][handler].type == parts[1] )
-									delete events[type][handler];
-
-						// remove generic event handler if no more handlers exist
-						for ( ret in events[type] ) break;
-						if ( !ret ) {
-							if ( !jQuery.event.special[type] || jQuery.event.special[type].teardown.call(elem) === false ) {
-								if (elem.removeEventListener)
-									elem.removeEventListener(type, jQuery.data(elem, &quot;handle&quot;), false);
-								else if (elem.detachEvent)
-									elem.detachEvent(&quot;on&quot; + type, jQuery.data(elem, &quot;handle&quot;));
-							}
-							ret = null;
-							delete events[type];
-						}
-					}
-				});
-			}
-
-			// Remove the expando if it's no longer used
-			for ( ret in events ) break;
-			if ( !ret ) {
-				var handle = jQuery.data( elem, &quot;handle&quot; );
-				if ( handle ) handle.elem = null;
-				jQuery.removeData( elem, &quot;events&quot; );
-				jQuery.removeData( elem, &quot;handle&quot; );
-			}
-		}
-	},
-
-	trigger: function(type, data, elem, donative, extra) {
-		// Clone the incoming data, if any
-		data = jQuery.makeArray(data);
-
-		if ( type.indexOf(&quot;!&quot;) &gt;= 0 ) {
-			type = type.slice(0, -1);
-			var exclusive = true;
-		}
-
-		// Handle a global trigger
-		if ( !elem ) {
-			// Only trigger if we've ever bound an event for it
-			if ( this.global[type] )
-				jQuery(&quot;*&quot;).add([window, document]).trigger(type, data);
-
-		// Handle triggering a single element
-		} else {
-			// don't do events on text and comment nodes
-			if ( elem.nodeType == 3 || elem.nodeType == 8 )
-				return undefined;
-
-			var val, ret, fn = jQuery.isFunction( elem[ type ] || null ),
-				// Check to see if we need to provide a fake event, or not
-				event = !data[0] || !data[0].preventDefault;
-
-			// Pass along a fake event
-			if ( event ) {
-				data.unshift({
-					type: type,
-					target: elem,
-					preventDefault: function(){},
-					stopPropagation: function(){},
-					timeStamp: now()
-				});
-				data[0][expando] = true; // no need to fix fake event
-			}
-
-			// Enforce the right trigger type
-			data[0].type = type;
-			if ( exclusive )
-				data[0].exclusive = true;
-
-			// Trigger the event, it is assumed that &quot;handle&quot; is a function
-			var handle = jQuery.data(elem, &quot;handle&quot;);
-			if ( handle )
-				val = handle.apply( elem, data );
-
-			// Handle triggering native .onfoo handlers (and on links since we don't call .click() for links)
-			if ( (!fn || (jQuery.nodeName(elem, 'a') &amp;&amp; type == &quot;click&quot;)) &amp;&amp; elem[&quot;on&quot;+type] &amp;&amp; elem[&quot;on&quot;+type].apply( elem, data ) === false )
-				val = false;
-
-			// Extra functions don't get the custom event object
-			if ( event )
-				data.shift();
-
-			// Handle triggering of extra function
-			if ( extra &amp;&amp; jQuery.isFunction( extra ) ) {
-				// call the extra function and tack the current return value on the end for possible inspection
-				ret = extra.apply( elem, val == null ? data : data.concat( val ) );
-				// if anything is returned, give it precedence and have it overwrite the previous value
-				if (ret !== undefined)
-					val = ret;
-			}
-
-			// Trigger the native events (except for clicks on links)
-			if ( fn &amp;&amp; donative !== false &amp;&amp; val !== false &amp;&amp; !(jQuery.nodeName(elem, 'a') &amp;&amp; type == &quot;click&quot;) ) {
-				this.triggered = true;
-				try {
-					elem[ type ]();
-				// prevent IE from throwing an error for some hidden elements
-				} catch (e) {}
-			}
-
-			this.triggered = false;
-		}
-
-		return val;
-	},
-
-	handle: function(event) {
-		// returned undefined or false
-		var val, ret, namespace, all, handlers;
-
-		event = arguments[0] = jQuery.event.fix( event || window.event );
-
-		// Namespaced event handlers
-		namespace = event.type.split(&quot;.&quot;);
-		event.type = namespace[0];
-		namespace = namespace[1];
-		// Cache this now, all = true means, any handler
-		all = !namespace &amp;&amp; !event.exclusive;
-
-		handlers = ( jQuery.data(this, &quot;events&quot;) || {} )[event.type];
-
-		for ( var j in handlers ) {
-			var handler = handlers[j];
-
-			// Filter the functions by class
-			if ( all || handler.type == namespace ) {
-				// Pass in a reference to the handler function itself
-				// So that we can later remove it
-				event.handler = handler;
-				event.data = handler.data;
-
-				ret = handler.apply( this, arguments );
-
-				if ( val !== false )
-					val = ret;
-
-				if ( ret === false ) {
-					event.preventDefault();
-					event.stopPropagation();
-				}
-			}
-		}
-
-		return val;
-	},
-
-	fix: function(event) {
-		if ( event[expando] == true )
-			return event;
-
-		// store a copy of the original event object
-		// and &quot;clone&quot; to set read-only properties
-		var originalEvent = event;
-		event = { originalEvent: originalEvent };
-		var props = &quot;altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target timeStamp toElement type view wheelDelta which&quot;.split(&quot; &quot;);
-		for ( var i=props.length; i; i-- )
-			event[ props[i] ] = originalEvent[ props[i] ];
-
-		// Mark it as fixed
-		event[expando] = true;
-
-		// add preventDefault and stopPropagation since
-		// they will not work on the clone
-		event.preventDefault = function() {
-			// if preventDefault exists run it on the original event
-			if (originalEvent.preventDefault)
-				originalEvent.preventDefault();
-			// otherwise set the returnValue property of the original event to false (IE)
-			originalEvent.returnValue = false;
-		};
-		event.stopPropagation = function() {
-			// if stopPropagation exists run it on the original event
-			if (originalEvent.stopPropagation)
-				originalEvent.stopPropagation();
-			// otherwise set the cancelBubble property of the original event to true (IE)
-			originalEvent.cancelBubble = true;
-		};
-
-		// Fix timeStamp
-		event.timeStamp = event.timeStamp || now();
-
-		// Fix target property, if necessary
-		if ( !event.target )
-			event.target = event.srcElement || document; // Fixes #1925 where srcElement might not be defined either
-
-		// check if target is a textnode (safari)
-		if ( event.target.nodeType == 3 )
-			event.target = event.target.parentNode;
-
-		// Add relatedTarget, if necessary
-		if ( !event.relatedTarget &amp;&amp; event.fromElement )
-			event.relatedTarget = event.fromElement == event.target ? event.toElement : event.fromElement;
-
-		// Calculate pageX/Y if missing and clientX/Y available
-		if ( event.pageX == null &amp;&amp; event.clientX != null ) {
-			var doc = document.documentElement, body = document.body;
-			event.pageX = event.clientX + (doc &amp;&amp; doc.scrollLeft || body &amp;&amp; body.scrollLeft || 0) - (doc.clientLeft || 0);
-			event.pageY = event.clientY + (doc &amp;&amp; doc.scrollTop || body &amp;&amp; body.scrollTop || 0) - (doc.clientTop || 0);
-		}
-
-		// Add which for key events
-		if ( !event.which &amp;&amp; ((event.charCode || event.charCode === 0) ? event.charCode : event.keyCode) )
-			event.which = event.charCode || event.keyCode;
-
-		// Add metaKey to non-Mac browsers (use ctrl for PC's and Meta for Macs)
-		if ( !event.metaKey &amp;&amp; event.ctrlKey )
-			event.metaKey = event.ctrlKey;
-
-		// Add which for click: 1 == left; 2 == middle; 3 == right
-		// Note: button is not normalized, so don't use it
-		if ( !event.which &amp;&amp; event.button )
-			event.which = (event.button &amp; 1 ? 1 : ( event.button &amp; 2 ? 3 : ( event.button &amp; 4 ? 2 : 0 ) ));
-
-		return event;
-	},
-
-	proxy: function( fn, proxy ){
-		// Set the guid of unique handler to the same of original handler, so it can be removed
-		proxy.guid = fn.guid = fn.guid || proxy.guid || this.guid++;
-		// So proxy can be declared as an argument
-		return proxy;
-	},
-
-	special: {
-		ready: {
-			setup: function() {
-				// Make sure the ready event is setup
-				bindReady();
-				return;
-			},
-
-			teardown: function() { return; }
-		},
-
-		mouseenter: {
-			setup: function() {
-				if ( jQuery.browser.msie ) return false;
-				jQuery(this).bind(&quot;mouseover&quot;, jQuery.event.special.mouseenter.handler);
-				return true;
-			},
-
-			teardown: function() {
-				if ( jQuery.browser.msie ) return false;
-				jQuery(this).unbind(&quot;mouseover&quot;, jQuery.event.special.mouseenter.handler);
-				return true;
-			},
-
-			handler: function(event) {
-				// If we actually just moused on to a sub-element, ignore it
-				if ( withinElement(event, this) ) return true;
-				// Execute the right handlers by setting the event type to mouseenter
-				event.type = &quot;mouseenter&quot;;
-				return jQuery.event.handle.apply(this, arguments);
-			}
-		},
-
-		mouseleave: {
-			setup: function() {
-				if ( jQuery.browser.msie ) return false;
-				jQuery(this).bind(&quot;mouseout&quot;, jQuery.event.special.mouseleave.handler);
-				return true;
-			},
-
-			teardown: function() {
-				if ( jQuery.browser.msie ) return false;
-				jQuery(this).unbind(&quot;mouseout&quot;, jQuery.event.special.mouseleave.handler);
-				return true;
-			},
-
-			handler: function(event) {
-				// If we actually just moused on to a sub-element, ignore it
-				if ( withinElement(event, this) ) return true;
-				// Execute the right handlers by setting the event type to mouseleave
-				event.type = &quot;mouseleave&quot;;
-				return jQuery.event.handle.apply(this, arguments);
-			}
-		}
-	}
-};
-
-jQuery.fn.extend({
-	bind: function( type, data, fn ) {
-		return type == &quot;unload&quot; ? this.one(type, data, fn) : this.each(function(){
-			jQuery.event.add( this, type, fn || data, fn &amp;&amp; data );
-		});
-	},
-
-	one: function( type, data, fn ) {
-		var one = jQuery.event.proxy( fn || data, function(event) {
-			jQuery(this).unbind(event, one);
-			return (fn || data).apply( this, arguments );
-		});
-		return this.each(function(){
-			jQuery.event.add( this, type, one, fn &amp;&amp; data);
-		});
-	},
-
-	unbind: function( type, fn ) {
-		return this.each(function(){
-			jQuery.event.remove( this, type, fn );
-		});
-	},
-
-	trigger: function( type, data, fn ) {
-		return this.each(function(){
-			jQuery.event.trigger( type, data, this, true, fn );
-		});
-	},
-
-	triggerHandler: function( type, data, fn ) {
-		return this[0] &amp;&amp; jQuery.event.trigger( type, data, this[0], false, fn );
-	},
-
-	toggle: function( fn ) {
-		// Save reference to arguments for access in closure
-		var args = arguments, i = 1;
-
-		// link all the functions, so any of them can unbind this click handler
-		while( i &lt; args.length )
-			jQuery.event.proxy( fn, args[i++] );
-
-		return this.click( jQuery.event.proxy( fn, function(event) {
-			// Figure out which function to execute
-			this.lastToggle = ( this.lastToggle || 0 ) % i;
-
-			// Make sure that clicks stop
-			event.preventDefault();
-
-			// and execute the function
-			return args[ this.lastToggle++ ].apply( this, arguments ) || false;
-		}));
-	},
-
-	hover: function(fnOver, fnOut) {
-		return this.bind('mouseenter', fnOver).bind('mouseleave', fnOut);
-	},
-
-	ready: function(fn) {
-		// Attach the listeners
-		bindReady();
-
-		// If the DOM is already ready
-		if ( jQuery.isReady )
-			// Execute the function immediately
-			fn.call( document, jQuery );
-
-		// Otherwise, remember the function for later
-		else
-			// Add the function to the wait list
-			jQuery.readyList.push( function() { return fn.call(this, jQuery); } );
-
-		return this;
-	}
-});
-
-jQuery.extend({
-	isReady: false,
-	readyList: [],
-	// Handle when the DOM is ready
-	ready: function() {
-		// Make sure that the DOM is not already loaded
-		if ( !jQuery.isReady ) {
-			// Remember that the DOM is ready
-			jQuery.isReady = true;
-
-			// If there are functions bound, to execute
-			if ( jQuery.readyList ) {
-				// Execute all of them
-				jQuery.each( jQuery.readyList, function(){
-					this.call( document );
-				});
-
-				// Reset the list of functions
-				jQuery.readyList = null;
-			}
-
-			// Trigger any bound ready events
-			jQuery(document).triggerHandler(&quot;ready&quot;);
-		}
-	}
-});
-
-var readyBound = false;
-
-function bindReady(){
-	if ( readyBound ) return;
-	readyBound = true;
-
-	// Mozilla, Opera (see further below for it) and webkit nightlies currently support this event
-	if ( document.addEventListener &amp;&amp; !jQuery.browser.opera)
-		// Use the handy event callback
-		document.addEventListener( &quot;DOMContentLoaded&quot;, jQuery.ready, false );
-
-	// If IE is used and is not in a frame
-	// Continually check to see if the document is ready
-	if ( jQuery.browser.msie &amp;&amp; window == top ) (function(){
-		if (jQuery.isReady) return;
-		try {
-			// If IE is used, use the trick by Diego Perini
-			// http://javascript.nwbox.com/IEContentLoaded/
-			document.documentElement.doScroll(&quot;left&quot;);
-		} catch( error ) {
-			setTimeout( arguments.callee, 0 );
-			return;
-		}
-		// and execute any waiting functions
-		jQuery.ready();
-	})();
-
-	if ( jQuery.browser.opera )
-		document.addEventListener( &quot;DOMContentLoaded&quot;, function () {
-			if (jQuery.isReady) return;
-			for (var i = 0; i &lt; document.styleSheets.length; i++)
-				if (document.styleSheets[i].disabled) {
-					setTimeout( arguments.callee, 0 );
-					return;
-				}
-			// and execute any waiting functions
-			jQuery.ready();
-		}, false);
-
-	if ( jQuery.browser.safari ) {
-		var numStyles;
-		(function(){
-			if (jQuery.isReady) return;
-			if ( document.readyState != &quot;loaded&quot; &amp;&amp; document.readyState != &quot;complete&quot; ) {
-				setTimeout( arguments.callee, 0 );
-				return;
-			}
-			if ( numStyles === undefined )
-				numStyles = jQuery(&quot;style, link[rel=stylesheet]&quot;).length;
-			if ( document.styleSheets.length != numStyles ) {
-				setTimeout( arguments.callee, 0 );
-				return;
-			}
-			// and execute any waiting functions
-			jQuery.ready();
-		})();
-	}
-
-	// A fallback to window.onload, that will always work
-	jQuery.event.add( window, &quot;load&quot;, jQuery.ready );
-}
-
-jQuery.each( (&quot;blur,focus,load,resize,scroll,unload,click,dblclick,&quot; +
-	&quot;mousedown,mouseup,mousemove,mouseover,mouseout,change,select,&quot; +
-	&quot;submit,keydown,keypress,keyup,error&quot;).split(&quot;,&quot;), function(i, name){
-
-	// Handle event binding
-	jQuery.fn[name] = function(fn){
-		return fn ? this.bind(name, fn) : this.trigger(name);
-	};
-});
-
-// Checks if an event happened on an element within another element
-// Used in jQuery.event.special.mouseenter and mouseleave handlers
-var withinElement = function(event, elem) {
-	// Check if mouse(over|out) are still within the same parent element
-	var parent = event.relatedTarget;
-	// Traverse up the tree
-	while ( parent &amp;&amp; parent != elem ) try { parent = parent.parentNode; } catch(error) { parent = elem; }
-	// Return true if we actually just moused on to a sub-element
-	return parent == elem;
-};
-
-// Prevent memory leaks in IE
-// And prevent errors on refresh with events like mouseover in other browsers
-// Window isn't included so as not to unbind existing unload events
-jQuery(window).bind(&quot;unload&quot;, function() {
-	jQuery(&quot;*&quot;).add(document).unbind();
-});
-jQuery.fn.extend({
-	// Keep a copy of the old load
-	_load: jQuery.fn.load,
-
-	load: function( url, params, callback ) {
-		if ( typeof url != 'string' )
-			return this._load( url );
-
-		var off = url.indexOf(&quot; &quot;);
-		if ( off &gt;= 0 ) {
-			var selector = url.slice(off, url.length);
-			url = url.slice(0, off);
-		}
-
-		callback = callback || function(){};
-
-		// Default to a GET request
-		var type = &quot;GET&quot;;
-
-		// If the second parameter was provided
-		if ( params )
-			// If it's a function
-			if ( jQuery.isFunction( params ) ) {
-				// We assume that it's the callback
-				callback = params;
-				params = null;
-
-			// Otherwise, build a param string
-			} else {
-				params = jQuery.param( params );
-				type = &quot;POST&quot;;
-			}
-
-		var self = this;
-
-		// Request the remote document
-		jQuery.ajax({
-			url: url,
-			type: type,
-			dataType: &quot;html&quot;,
-			data: params,
-			complete: function(res, status){
-				// If successful, inject the HTML into all the matched elements
-				if ( status == &quot;success&quot; || status == &quot;notmodified&quot; )
-					// See if a selector was specified
-					self.html( selector ?
-						// Create a dummy div to hold the results
-						jQuery(&quot;&lt;div/&gt;&quot;)
-							// inject the contents of the document in, removing the scripts
-							// to avoid any 'Permission Denied' errors in IE
-							.append(res.responseText.replace(/&lt;script(.|\s)*?\/script&gt;/g, &quot;&quot;))
-
-							// Locate the specified elements
-							.find(selector) :
-
-						// If not, just inject the full result
-						res.responseText );
-
-				self.each( callback, [res.responseText, status, res] );
-			}
-		});
-		return this;
-	},
-
-	serialize: function() {
-		return jQuery.param(this.serializeArray());
-	},
-	serializeArray: function() {
-		return this.map(function(){
-			return jQuery.nodeName(this, &quot;form&quot;) ?
-				jQuery.makeArray(this.elements) : this;
-		})
-		.filter(function(){
-			return this.name &amp;&amp; !this.disabled &amp;&amp;
-				(this.checked || /select|textarea/i.test(this.nodeName) ||
-					/text|hidden|password/i.test(this.type));
-		})
-		.map(function(i, elem){
-			var val = jQuery(this).val();
-			return val == null ? null :
-				val.constructor == Array ?
-					jQuery.map( val, function(val, i){
-						return {name: elem.name, value: val};
-					}) :
-					{name: elem.name, value: val};
-		}).get();
-	}
-});
-
-// Attach a bunch of functions for handling common AJAX events
-jQuery.each( &quot;ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend&quot;.split(&quot;,&quot;), function(i,o){
-	jQuery.fn[o] = function(f){
-		return this.bind(o, f);
-	};
-});
-
-var jsc = now();
-
-jQuery.extend({
-	get: function( url, data, callback, type ) {
-		// shift arguments if data argument was ommited
-		if ( jQuery.isFunction( data ) ) {
-			callback = data;
-			data = null;
-		}
-
-		return jQuery.ajax({
-			type: &quot;GET&quot;,
-			url: url,
-			data: data,
-			success: callback,
-			dataType: type
-		});
-	},
-
-	getScript: function( url, callback ) {
-		return jQuery.get(url, null, callback, &quot;script&quot;);
-	},
-
-	getJSON: function( url, data, callback ) {
-		return jQuery.get(url, data, callback, &quot;json&quot;);
-	},
-
-	post: function( url, data, callback, type ) {
-		if ( jQuery.isFunction( data ) ) {
-			callback = data;
-			data = {};
-		}
-
-		return jQuery.ajax({
-			type: &quot;POST&quot;,
-			url: url,
-			data: data,
-			success: callback,
-			dataType: type
-		});
-	},
-
-	ajaxSetup: function( settings ) {
-		jQuery.extend( jQuery.ajaxSettings, settings );
-	},
-
-	ajaxSettings: {
-		url: location.href,
-		global: true,
-		type: &quot;GET&quot;,
-		timeout: 0,
-		contentType: &quot;application/x-www-form-urlencoded&quot;,
-		processData: true,
-		async: true,
-		data: null,
-		username: null,
-		password: null,
-		accepts: {
-			xml: &quot;application/xml, text/xml&quot;,
-			html: &quot;text/html&quot;,
-			script: &quot;text/javascript, application/javascript&quot;,
-			json: &quot;application/json, text/javascript&quot;,
-			text: &quot;text/plain&quot;,
-			_default: &quot;*/*&quot;
-		}
-	},
-
-	// Last-Modified header cache for next request
-	lastModified: {},
-
-	ajax: function( s ) {
-		// Extend the settings, but re-extend 's' so that it can be
-		// checked again later (in the test suite, specifically)
-		s = jQuery.extend(true, s, jQuery.extend(true, {}, jQuery.ajaxSettings, s));
-
-		var jsonp, jsre = /=\?(&amp;|$)/g, status, data,
-			type = s.type.toUpperCase();
-
-		// convert data if not already a string
-		if ( s.data &amp;&amp; s.processData &amp;&amp; typeof s.data != &quot;string&quot; )
-			s.data = jQuery.param(s.data);
-
-		// Handle JSONP Parameter Callbacks
-		if ( s.dataType == &quot;jsonp&quot; ) {
-			if ( type == &quot;GET&quot; ) {
-				if ( !s.url.match(jsre) )
-					s.url += (s.url.match(/\?/) ? &quot;&amp;&quot; : &quot;?&quot;) + (s.jsonp || &quot;callback&quot;) + &quot;=?&quot;;
-			} else if ( !s.data || !s.data.match(jsre) )
-				s.data = (s.data ? s.data + &quot;&amp;&quot; : &quot;&quot;) + (s.jsonp || &quot;callback&quot;) + &quot;=?&quot;;
-			s.dataType = &quot;json&quot;;
-		}
-
-		// Build temporary JSONP function
-		if ( s.dataType == &quot;json&quot; &amp;&amp; (s.data &amp;&amp; s.data.match(jsre) || s.url.match(jsre)) ) {
-			jsonp = &quot;jsonp&quot; + jsc++;
-
-			// Replace the =? sequence both in the query string and the data
-			if ( s.data )
-				s.data = (s.data + &quot;&quot;).replace(jsre, &quot;=&quot; + jsonp + &quot;$1&quot;);
-			s.url = s.url.replace(jsre, &quot;=&quot; + jsonp + &quot;$1&quot;);
-
-			// We need to make sure
-			// that a JSONP style response is executed properly
-			s.dataType = &quot;script&quot;;
-
-			// Handle JSONP-style loading
-			window[ jsonp ] = function(tmp){
-				data = tmp;
-				success();
-				complete();
-				// Garbage collect
-				window[ jsonp ] = undefined;
-				try{ delete window[ jsonp ]; } catch(e){}
-				if ( head )
-					head.removeChild( script );
-			};
-		}
-
-		if ( s.dataType == &quot;script&quot; &amp;&amp; s.cache == null )
-			s.cache = false;
-
-		if ( s.cache === false &amp;&amp; type == &quot;GET&quot; ) {
-			var ts = now();
-			// try replacing _= if it is there
-			var ret = s.url.replace(/(\?|&amp;)_=.*?(&amp;|$)/, &quot;$1_=&quot; + ts + &quot;$2&quot;);
-			// if nothing was replaced, add timestamp to the end
-			s.url = ret + ((ret == s.url) ? (s.url.match(/\?/) ? &quot;&amp;&quot; : &quot;?&quot;) + &quot;_=&quot; + ts : &quot;&quot;);
-		}
-
-		// If data is available, append data to url for get requests
-		if ( s.data &amp;&amp; type == &quot;GET&quot; ) {
-			s.url += (s.url.match(/\?/) ? &quot;&amp;&quot; : &quot;?&quot;) + s.data;
-
-			// IE likes to send both get and post data, prevent this
-			s.data = null;
-		}
-
-		// Watch for a new set of requests
-		if ( s.global &amp;&amp; ! jQuery.active++ )
-			jQuery.event.trigger( &quot;ajaxStart&quot; );
-
-		// Matches an absolute URL, and saves the domain
-		var remote = /^(?:\w+:)?\/\/([^\/?#]+)/;
-
-		// If we're requesting a remote document
-		// and trying to load JSON or Script with a GET
-		if ( s.dataType == &quot;script&quot; &amp;&amp; type == &quot;GET&quot;
-				&amp;&amp; remote.test(s.url) &amp;&amp; remote.exec(s.url)[1] != location.host ){
-			var head = document.getElementsByTagName(&quot;head&quot;)[0];
-			var script = document.createElement(&quot;script&quot;);
-			script.src = s.url;
-			if (s.scriptCharset)
-				script.charset = s.scriptCharset;
-
-			// Handle Script loading
-			if ( !jsonp ) {
-				var done = false;
-
-				// Attach handlers for all browsers
-				script.onload = script.onreadystatechange = function(){
-					if ( !done &amp;&amp; (!this.readyState ||
-							this.readyState == &quot;loaded&quot; || this.readyState == &quot;complete&quot;) ) {
-						done = true;
-						success();
-						complete();
-						head.removeChild( script );
-					}
-				};
-			}
-
-			head.appendChild(script);
-
-			// We handle everything using the script element injection
-			return undefined;
-		}
-
-		var requestDone = false;
-
-		// Create the request object; Microsoft failed to properly
-		// implement the XMLHttpRequest in IE7, so we use the ActiveXObject when it is available
-		var xhr = window.ActiveXObject ? new ActiveXObject(&quot;Microsoft.XMLHTTP&quot;) : new XMLHttpRequest();
-
-		// Open the socket
-		// Passing null username, generates a login popup on Opera (#2865)
-		if( s.username )
-			xhr.open(type, s.url, s.async, s.username, s.password);
-		else
-			xhr.open(type, s.url, s.async);
-
-		// Need an extra try/catch for cross domain requests in Firefox 3
-		try {
-			// Set the correct header, if data is being sent
-			if ( s.data )
-				xhr.setRequestHeader(&quot;Content-Type&quot;, s.contentType);
-
-			// Set the If-Modified-Since header, if ifModified mode.
-			if ( s.ifModified )
-				xhr.setRequestHeader(&quot;If-Modified-Since&quot;,
-					jQuery.lastModified[s.url] || &quot;Thu, 01 Jan 1970 00:00:00 GMT&quot; );
-
-			// Set header so the called script knows that it's an XMLHttpRequest
-			xhr.setRequestHeader(&quot;X-Requested-With&quot;, &quot;XMLHttpRequest&quot;);
-
-			// Set the Accepts header for the server, depending on the dataType
-			xhr.setRequestHeader(&quot;Accept&quot;, s.dataType &amp;&amp; s.accepts[ s.dataType ] ?
-				s.accepts[ s.dataType ] + &quot;, */*&quot; :
-				s.accepts._default );
-		} catch(e){}
-
-		// Allow custom headers/mimetypes
-		if ( s.beforeSend &amp;&amp; s.beforeSend(xhr, s) === false ) {
-			// cleanup active request counter
-			s.global &amp;&amp; jQuery.active--;
-			// close opended socket
-			xhr.abort();
-			return false;
-		}
-
-		if ( s.global )
-			jQuery.event.trigger(&quot;ajaxSend&quot;, [xhr, s]);
-
-		// Wait for a response to come back
-		var onreadystatechange = function(isTimeout){
-			// The transfer is complete and the data is available, or the request timed out
-			if ( !requestDone &amp;&amp; xhr &amp;&amp; (xhr.readyState == 4 || isTimeout == &quot;timeout&quot;) ) {
-				requestDone = true;
-
-				// clear poll interval
-				if (ival) {
-					clearInterval(ival);
-					ival = null;
-				}
-
-				status = isTimeout == &quot;timeout&quot; &amp;&amp; &quot;timeout&quot; ||
-					!jQuery.httpSuccess( xhr ) &amp;&amp; &quot;error&quot; ||
-					s.ifModified &amp;&amp; jQuery.httpNotModified( xhr, s.url ) &amp;&amp; &quot;notmodified&quot; ||
-					&quot;success&quot;;
-
-				if ( status == &quot;success&quot; ) {
-					// Watch for, and catch, XML document parse errors
-					try {
-						// process the data (runs the xml through httpData regardless of callback)
-						data = jQuery.httpData( xhr, s.dataType, s.dataFilter );
-					} catch(e) {
-						status = &quot;parsererror&quot;;
-					}
-				}
-
-				// Make sure that the request was successful or notmodified
-				if ( status == &quot;success&quot; ) {
-					// Cache Last-Modified header, if ifModified mode.
-					var modRes;
-					try {
-						modRes = xhr.getResponseHeader(&quot;Last-Modified&quot;);
-					} catch(e) {} // swallow exception thrown by FF if header is not available
-
-					if ( s.ifModified &amp;&amp; modRes )
-						jQuery.lastModified[s.url] = modRes;
-
-					// JSONP handles its own success callback
-					if ( !jsonp )
-						success();
-				} else
-					jQuery.handleError(s, xhr, status);
-
-				// Fire the complete handlers
-				complete();
-
-				// Stop memory leaks
-				if ( s.async )
-					xhr = null;
-			}
-		};
-
-		if ( s.async ) {
-			// don't attach the handler to the request, just poll it instead
-			var ival = setInterval(onreadystatechange, 13);
-
-			// Timeout checker
-			if ( s.timeout &gt; 0 )
-				setTimeout(function(){
-					// Check to see if the request is still happening
-					if ( xhr ) {
-						// Cancel the request
-						xhr.abort();
-
-						if( !requestDone )
-							onreadystatechange( &quot;timeout&quot; );
-					}
-				}, s.timeout);
-		}
-
-		// Send the data
-		try {
-			xhr.send(s.data);
-		} catch(e) {
-			jQuery.handleError(s, xhr, null, e);
-		}
-
-		// firefox 1.5 doesn't fire statechange for sync requests
-		if ( !s.async )
-			onreadystatechange();
-
-		function success(){
-			// If a local callback was specified, fire it and pass it the data
-			if ( s.success )
-				s.success( data, status );
-
-			// Fire the global callback
-			if ( s.global )
-				jQuery.event.trigger( &quot;ajaxSuccess&quot;, [xhr, s] );
-		}
-
-		function complete(){
-			// Process result
-			if ( s.complete )
-				s.complete(xhr, status);
-
-			// The request was completed
-			if ( s.global )
-				jQuery.event.trigger( &quot;ajaxComplete&quot;, [xhr, s] );
-
-			// Handle the global AJAX counter
-			if ( s.global &amp;&amp; ! --jQuery.active )
-				jQuery.event.trigger( &quot;ajaxStop&quot; );
-		}
-
-		// return XMLHttpRequest to allow aborting the request etc.
-		return xhr;
-	},
-
-	handleError: function( s, xhr, status, e ) {
-		// If a local callback was specified, fire it
-		if ( s.error ) s.error( xhr, status, e );
-
-		// Fire the global callback
-		if ( s.global )
-			jQuery.event.trigger( &quot;ajaxError&quot;, [xhr, s, e] );
-	},
-
-	// Counter for holding the number of active queries
-	active: 0,
-
-	// Determines if an XMLHttpRequest was successful or not
-	httpSuccess: function( xhr ) {
-		try {
-			// IE error sometimes returns 1223 when it should be 204 so treat it as success, see #1450
-			return !xhr.status &amp;&amp; location.protocol == &quot;file:&quot; ||
-				( xhr.status &gt;= 200 &amp;&amp; xhr.status &lt; 300 ) || xhr.status == 304 || xhr.status == 1223 ||
-				jQuery.browser.safari &amp;&amp; xhr.status == undefined;
-		} catch(e){}
-		return false;
-	},
-
-	// Determines if an XMLHttpRequest returns NotModified
-	httpNotModified: function( xhr, url ) {
-		try {
-			var xhrRes = xhr.getResponseHeader(&quot;Last-Modified&quot;);
-
-			// Firefox always returns 200. check Last-Modified date
-			return xhr.status == 304 || xhrRes == jQuery.lastModified[url] ||
-				jQuery.browser.safari &amp;&amp; xhr.status == undefined;
-		} catch(e){}
-		return false;
-	},
-
-	httpData: function( xhr, type, filter ) {
-		var ct = xhr.getResponseHeader(&quot;content-type&quot;),
-			xml = type == &quot;xml&quot; || !type &amp;&amp; ct &amp;&amp; ct.indexOf(&quot;xml&quot;) &gt;= 0,
-			data = xml ? xhr.responseXML : xhr.responseText;
-
-		if ( xml &amp;&amp; data.documentElement.tagName == &quot;parsererror&quot; )
-			throw &quot;parsererror&quot;;
-			
-		// Allow a pre-filtering function to sanitize the response
-		if( filter )
-			data = filter( data, type );
-
-		// If the type is &quot;script&quot;, eval it in global context
-		if ( type == &quot;script&quot; )
-			jQuery.globalEval( data );
-
-		// Get the JavaScript object, if JSON is used.
-		if ( type == &quot;json&quot; )
-			data = eval(&quot;(&quot; + data + &quot;)&quot;);
-
-		return data;
-	},
-
-	// Serialize an array of form elements or a set of
-	// key/values into a query string
-	param: function( a ) {
-		var s = [];
-
-		// If an array was passed in, assume that it is an array
-		// of form elements
-		if ( a.constructor == Array || a.jquery )
-			// Serialize the form elements
-			jQuery.each( a, function(){
-				s.push( encodeURIComponent(this.name) + &quot;=&quot; + encodeURIComponent( this.value ) );
-			});
-
-		// Otherwise, assume that it's an object of key/value pairs
-		else
-			// Serialize the key/values
-			for ( var j in a )
-				// If the value is an array then the key names need to be repeated
-				if ( a[j] &amp;&amp; a[j].constructor == Array )
-					jQuery.each( a[j], function(){
-						s.push( encodeURIComponent(j) + &quot;=&quot; + encodeURIComponent( this ) );
-					});
-				else
-					s.push( encodeURIComponent(j) + &quot;=&quot; + encodeURIComponent( jQuery.isFunction(a[j]) ? a[j]() : a[j] ) );
-
-		// Return the resulting serialization
-		return s.join(&quot;&amp;&quot;).replace(/%20/g, &quot;+&quot;);
-	}
-
-});
-jQuery.fn.extend({
-	show: function(speed,callback){
-		return speed ?
-			this.animate({
-				height: &quot;show&quot;, width: &quot;show&quot;, opacity: &quot;show&quot;
-			}, speed, callback) :
-
-			this.filter(&quot;:hidden&quot;).each(function(){
-				this.style.display = this.oldblock || &quot;&quot;;
-				if ( jQuery.css(this,&quot;display&quot;) == &quot;none&quot; ) {
-					var elem = jQuery(&quot;&lt;&quot; + this.tagName + &quot; /&gt;&quot;).appendTo(&quot;body&quot;);
-					this.style.display = elem.css(&quot;display&quot;);
-					// handle an edge condition where css is - div { display:none; } or similar
-					if (this.style.display == &quot;none&quot;)
-						this.style.display = &quot;block&quot;;
-					elem.remove();
-				}
-			}).end();
-	},
-
-	hide: function(speed,callback){
-		return speed ?
-			this.animate({
-				height: &quot;hide&quot;, width: &quot;hide&quot;, opacity: &quot;hide&quot;
-			}, speed, callback) :
-
-			this.filter(&quot;:visible&quot;).each(function(){
-				this.oldblock = this.oldblock || jQuery.css(this,&quot;display&quot;);
-				this.style.display = &quot;none&quot;;
-			}).end();
-	},
-
-	// Save the old toggle function
-	_toggle: jQuery.fn.toggle,
-
-	toggle: function( fn, fn2 ){
-		return jQuery.isFunction(fn) &amp;&amp; jQuery.isFunction(fn2) ?
-			this._toggle.apply( this, arguments ) :
-			fn ?
-				this.animate({
-					height: &quot;toggle&quot;, width: &quot;toggle&quot;, opacity: &quot;toggle&quot;
-				}, fn, fn2) :
-				this.each(function(){
-					jQuery(this)[ jQuery(this).is(&quot;:hidden&quot;) ? &quot;show&quot; : &quot;hide&quot; ]();
-				});
-	},
-
-	slideDown: function(speed,callback){
-		return this.animate({height: &quot;show&quot;}, speed, callback);
-	},
-
-	slideUp: function(speed,callback){
-		return this.animate({height: &quot;hide&quot;}, speed, callback);
-	},
-
-	slideToggle: function(speed, callback){
-		return this.animate({height: &quot;toggle&quot;}, speed, callback);
-	},
-
-	fadeIn: function(speed, callback){
-		return this.animate({opacity: &quot;show&quot;}, speed, callback);
-	},
-
-	fadeOut: function(speed, callback){
-		return this.animate({opacity: &quot;hide&quot;}, speed, callback);
-	},
-
-	fadeTo: function(speed,to,callback){
-		return this.animate({opacity: to}, speed, callback);
-	},
-
-	animate: function( prop, speed, easing, callback ) {
-		var optall = jQuery.speed(speed, easing, callback);
-
-		return this[ optall.queue === false ? &quot;each&quot; : &quot;queue&quot; ](function(){
-			if ( this.nodeType != 1)
-				return false;
-
-			var opt = jQuery.extend({}, optall), p,
-				hidden = jQuery(this).is(&quot;:hidden&quot;), self = this;
-
-			for ( p in prop ) {
-				if ( prop[p] == &quot;hide&quot; &amp;&amp; hidden || prop[p] == &quot;show&quot; &amp;&amp; !hidden )
-					return opt.complete.call(this);
-
-				if ( p == &quot;height&quot; || p == &quot;width&quot; ) {
-					// Store display property
-					opt.display = jQuery.css(this, &quot;display&quot;);
-
-					// Make sure that nothing sneaks out
-					opt.overflow = this.style.overflow;
-				}
-			}
-
-			if ( opt.overflow != null )
-				this.style.overflow = &quot;hidden&quot;;
-
-			opt.curAnim = jQuery.extend({}, prop);
-
-			jQuery.each( prop, function(name, val){
-				var e = new jQuery.fx( self, opt, name );
-
-				if ( /toggle|show|hide/.test(val) )
-					e[ val == &quot;toggle&quot; ? hidden ? &quot;show&quot; : &quot;hide&quot; : val ]( prop );
-				else {
-					var parts = val.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),
-						start = e.cur(true) || 0;
-
-					if ( parts ) {
-						var end = parseFloat(parts[2]),
-							unit = parts[3] || &quot;px&quot;;
-
-						// We need to compute starting value
-						if ( unit != &quot;px&quot; ) {
-							self.style[ name ] = (end || 1) + unit;
-							start = ((end || 1) / e.cur(true)) * start;
-							self.style[ name ] = start + unit;
-						}
-
-						// If a +=/-= token was provided, we're doing a relative animation
-						if ( parts[1] )
-							end = ((parts[1] == &quot;-=&quot; ? -1 : 1) * end) + start;
-
-						e.custom( start, end, unit );
-					} else
-						e.custom( start, val, &quot;&quot; );
-				}
-			});
-
-			// For JS strict compliance
-			return true;
-		});
-	},
-
-	queue: function(type, fn){
-		if ( jQuery.isFunction(type) || ( type &amp;&amp; type.constructor == Array )) {
-			fn = type;
-			type = &quot;fx&quot;;
-		}
-
-		if ( !type || (typeof type == &quot;string&quot; &amp;&amp; !fn) )
-			return queue( this[0], type );
-
-		return this.each(function(){
-			if ( fn.constructor == Array )
-				queue(this, type, fn);
-			else {
-				queue(this, type).push( fn );
-
-				if ( queue(this, type).length == 1 )
-					fn.call(this);
-			}
-		});
-	},
-
-	stop: function(clearQueue, gotoEnd){
-		var timers = jQuery.timers;
-
-		if (clearQueue)
-			this.queue([]);
-
-		this.each(function(){
-			// go in reverse order so anything added to the queue during the loop is ignored
-			for ( var i = timers.length - 1; i &gt;= 0; i-- )
-				if ( timers[i].elem == this ) {
-					if (gotoEnd)
-						// force the next step to be the last
-						timers[i](true);
-					timers.splice(i, 1);
-				}
-		});
-
-		// start the next in the queue if the last step wasn't forced
-		if (!gotoEnd)
-			this.dequeue();
-
-		return this;
-	}
-
-});
-
-var queue = function( elem, type, array ) {
-	if ( elem ){
-
-		type = type || &quot;fx&quot;;
-
-		var q = jQuery.data( elem, type + &quot;queue&quot; );
-
-		if ( !q || array )
-			q = jQuery.data( elem, type + &quot;queue&quot;, jQuery.makeArray(array) );
-
-	}
-	return q;
-};
-
-jQuery.fn.dequeue = function(type){
-	type = type || &quot;fx&quot;;
-
-	return this.each(function(){
-		var q = queue(this, type);
-
-		q.shift();
-
-		if ( q.length )
-			q[0].call( this );
-	});
-};
-
-jQuery.extend({
-
-	speed: function(speed, easing, fn) {
-		var opt = speed &amp;&amp; speed.constructor == Object ? speed : {
-			complete: fn || !fn &amp;&amp; easing ||
-				jQuery.isFunction( speed ) &amp;&amp; speed,
-			duration: speed,
-			easing: fn &amp;&amp; easing || easing &amp;&amp; easing.constructor != Function &amp;&amp; easing
-		};
-
-		opt.duration = (opt.duration &amp;&amp; opt.duration.constructor == Number ?
-			opt.duration :
-			jQuery.fx.speeds[opt.duration]) || jQuery.fx.speeds.def;
-
-		// Queueing
-		opt.old = opt.complete;
-		opt.complete = function(){
-			if ( opt.queue !== false )
-				jQuery(this).dequeue();
-			if ( jQuery.isFunction( opt.old ) )
-				opt.old.call( this );
-		};
-
-		return opt;
-	},
-
-	easing: {
-		linear: function( p, n, firstNum, diff ) {
-			return firstNum + diff * p;
-		},
-		swing: function( p, n, firstNum, diff ) {
-			return ((-Math.cos(p*Math.PI)/2) + 0.5) * diff + firstNum;
-		}
-	},
-
-	timers: [],
-	timerId: null,
-
-	fx: function( elem, options, prop ){
-		this.options = options;
-		this.elem = elem;
-		this.prop = prop;
-
-		if ( !options.orig )
-			options.orig = {};
-	}
-
-});
-
-jQuery.fx.prototype = {
-
-	// Simple function for setting a style value
-	update: function(){
-		if ( this.options.step )
-			this.options.step.call( this.elem, this.now, this );
-
-		(jQuery.fx.step[this.prop] || jQuery.fx.step._default)( this );
-
-		// Set display property to block for height/width animations
-		if ( this.prop == &quot;height&quot; || this.prop == &quot;width&quot; )
-			this.elem.style.display = &quot;block&quot;;
-	},
-
-	// Get the current size
-	cur: function(force){
-		if ( this.elem[this.prop] != null &amp;&amp; this.elem.style[this.prop] == null )
-			return this.elem[ this.prop ];
-
-		var r = parseFloat(jQuery.css(this.elem, this.prop, force));
-		return r &amp;&amp; r &gt; -10000 ? r : parseFloat(jQuery.curCSS(this.elem, this.prop)) || 0;
-	},
-
-	// Start an animation from one number to another
-	custom: function(from, to, unit){
-		this.startTime = now();
-		this.start = from;
-		this.end = to;
-		this.unit = unit || this.unit || &quot;px&quot;;
-		this.now = this.start;
-		this.pos = this.state = 0;
-		this.update();
-
-		var self = this;
-		function t(gotoEnd){
-			return self.step(gotoEnd);
-		}
-
-		t.elem = this.elem;
-
-		jQuery.timers.push(t);
-
-		if ( jQuery.timerId == null ) {
-			jQuery.timerId = setInterval(function(){
-				var timers = jQuery.timers;
-
-				for ( var i = 0; i &lt; timers.length; i++ )
-					if ( !timers[i]() )
-						timers.splice(i--, 1);
-
-				if ( !timers.length ) {
-					clearInterval( jQuery.timerId );
-					jQuery.timerId = null;
-				}
-			}, 13);
-		}
-	},
-
-	// Simple 'show' function
-	show: function(){
-		// Remember where we started, so that we can go back to it later
-		this.options.orig[this.prop] = jQuery.attr( this.elem.style, this.prop );
-		this.options.show = true;
-
-		// Begin the animation
-		this.custom(0, this.cur());
-
-		// Make sure that we start at a small width/height to avoid any
-		// flash of content
-		if ( this.prop == &quot;width&quot; || this.prop == &quot;height&quot; )
-			this.elem.style[this.prop] = &quot;1px&quot;;
-
-		// Start by showing the element
-		jQuery(this.elem).show();
-	},
-
-	// Simple 'hide' function
-	hide: function(){
-		// Remember where we started, so that we can go back to it later
-		this.options.orig[this.prop] = jQuery.attr( this.elem.style, this.prop );
-		this.options.hide = true;
-
-		// Begin the animation
-		this.custom(this.cur(), 0);
-	},
-
-	// Each step of an animation
-	step: function(gotoEnd){
-		var t = now();
-
-		if ( gotoEnd || t &gt; this.options.duration + this.startTime ) {
-			this.now = this.end;
-			this.pos = this.state = 1;
-			this.update();
-
-			this.options.curAnim[ this.prop ] = true;
-
-			var done = true;
-			for ( var i in this.options.curAnim )
-				if ( this.options.curAnim[i] !== true )
-					done = false;
-
-			if ( done ) {
-				if ( this.options.display != null ) {
-					// Reset the overflow
-					this.elem.style.overflow = this.options.overflow;
-
-					// Reset the display
-					this.elem.style.display = this.options.display;
-					if ( jQuery.css(this.elem, &quot;display&quot;) == &quot;none&quot; )
-						this.elem.style.display = &quot;block&quot;;
-				}
-
-				// Hide the element if the &quot;hide&quot; operation was done
-				if ( this.options.hide )
-					this.elem.style.display = &quot;none&quot;;
-
-				// Reset the properties, if the item has been hidden or shown
-				if ( this.options.hide || this.options.show )
-					for ( var p in this.options.curAnim )
-						jQuery.attr(this.elem.style, p, this.options.orig[p]);
-			}
-
-			if ( done )
-				// Execute the complete function
-				this.options.complete.call( this.elem );
-
-			return false;
-		} else {
-			var n = t - this.startTime;
-			this.state = n / this.options.duration;
-
-			// Perform the easing function, defaults to swing
-			this.pos = jQuery.easing[this.options.easing || (jQuery.easing.swing ? &quot;swing&quot; : &quot;linear&quot;)](this.state, n, 0, 1, this.options.duration);
-			this.now = this.start + ((this.end - this.start) * this.pos);
-
-			// Perform the next step of the animation
-			this.update();
-		}
-
-		return true;
-	}
-
-};
-
-jQuery.extend( jQuery.fx, {
-	speeds:{
-		slow: 600,
- 		fast: 200,
- 		// Default speed
- 		def: 400
-	},
-	step: {
-		scrollLeft: function(fx){
-			fx.elem.scrollLeft = fx.now;
-		},
-
-		scrollTop: function(fx){
-			fx.elem.scrollTop = fx.now;
-		},
-
-		opacity: function(fx){
-			jQuery.attr(fx.elem.style, &quot;opacity&quot;, fx.now);
-		},
-
-		_default: function(fx){
-			fx.elem.style[ fx.prop ] = fx.now + fx.unit;
-		}
-	}
-});
-// The Offset Method
-// Originally By Brandon Aaron, part of the Dimension Plugin
-// http://jquery.com/plugins/project/dimensions
-jQuery.fn.offset = function() {
-	var left = 0, top = 0, elem = this[0], results;
-
-	if ( elem ) with ( jQuery.browser ) {
-		var parent       = elem.parentNode,
-		    offsetChild  = elem,
-		    offsetParent = elem.offsetParent,
-		    doc          = elem.ownerDocument,
-		    safari2      = safari &amp;&amp; parseInt(version) &lt; 522 &amp;&amp; !/adobeair/i.test(userAgent),
-		    css          = jQuery.curCSS,
-		    fixed        = css(elem, &quot;position&quot;) == &quot;fixed&quot;;
-
-		// Use getBoundingClientRect if available
-		if ( elem.getBoundingClientRect ) {
-			var box = elem.getBoundingClientRect();
-
-			// Add the document scroll offsets
-			add(box.left + Math.max(doc.documentElement.scrollLeft, doc.body.scrollLeft),
-				box.top  + Math.max(doc.documentElement.scrollTop,  doc.body.scrollTop));
-
-			// IE adds the HTML element's border, by default it is medium which is 2px
-			// IE 6 and 7 quirks mode the border width is overwritable by the following css html { border: 0; }
-			// IE 7 standards mode, the border is always 2px
-			// This border/offset is typically represented by the clientLeft and clientTop properties
-			// However, in IE6 and 7 quirks mode the clientLeft and clientTop properties are not updated when overwriting it via CSS
-			// Therefore this method will be off by 2px in IE while in quirksmode
-			add( -doc.documentElement.clientLeft, -doc.documentElement.clientTop );
-
-		// Otherwise loop through the offsetParents and parentNodes
-		} else {
-
-			// Initial element offsets
-			add( elem.offsetLeft, elem.offsetTop );
-
-			// Get parent offsets
-			while ( offsetParent ) {
-				// Add offsetParent offsets
-				add( offsetParent.offsetLeft, offsetParent.offsetTop );
-
-				// Mozilla and Safari &gt; 2 does not include the border on offset parents
-				// However Mozilla adds the border for table or table cells
-				if ( mozilla &amp;&amp; !/^t(able|d|h)$/i.test(offsetParent.tagName) || safari &amp;&amp; !safari2 )
-					border( offsetParent );
-
-				// Add the document scroll offsets if position is fixed on any offsetParent
-				if ( !fixed &amp;&amp; css(offsetParent, &quot;position&quot;) == &quot;fixed&quot; )
-					fixed = true;
-
-				// Set offsetChild to previous offsetParent unless it is the body element
-				offsetChild  = /^body$/i.test(offsetParent.tagName) ? offsetChild : offsetParent;
-				// Get next offsetParent
-				offsetParent = offsetParent.offsetParent;
-			}
-
-			// Get parent scroll offsets
-			while ( parent &amp;&amp; parent.tagName &amp;&amp; !/^body|html$/i.test(parent.tagName) ) {
-				// Remove parent scroll UNLESS that parent is inline or a table to work around Opera inline/table scrollLeft/Top bug
-				if ( !/^inline|table.*$/i.test(css(parent, &quot;display&quot;)) )
-					// Subtract parent scroll offsets
-					add( -parent.scrollLeft, -parent.scrollTop );
-
-				// Mozilla does not add the border for a parent that has overflow != visible
-				if ( mozilla &amp;&amp; css(parent, &quot;overflow&quot;) != &quot;visible&quot; )
-					border( parent );
-
-				// Get next parent
-				parent = parent.parentNode;
-			}
-
-			// Safari &lt;= 2 doubles body offsets with a fixed position element/offsetParent or absolutely positioned offsetChild
-			// Mozilla doubles body offsets with a non-absolutely positioned offsetChild
-			if ( (safari2 &amp;&amp; (fixed || css(offsetChild, &quot;position&quot;) == &quot;absolute&quot;)) ||
-				(mozilla &amp;&amp; css(offsetChild, &quot;position&quot;) != &quot;absolute&quot;) )
-					add( -doc.body.offsetLeft, -doc.body.offsetTop );
-
-			// Add the document scroll offsets if position is fixed
-			if ( fixed )
-				add(Math.max(doc.documentElement.scrollLeft, doc.body.scrollLeft),
-					Math.max(doc.documentElement.scrollTop,  doc.body.scrollTop));
-		}
-
-		// Return an object with top and left properties
-		results = { top: top, left: left };
-	}
-
-	function border(elem) {
-		add( jQuery.curCSS(elem, &quot;borderLeftWidth&quot;, true), jQuery.curCSS(elem, &quot;borderTopWidth&quot;, true) );
-	}
-
-	function add(l, t) {
-		left += parseInt(l, 10) || 0;
-		top += parseInt(t, 10) || 0;
-	}
-
-	return results;
-};
-
-
-jQuery.fn.extend({
-	position: function() {
-		var left = 0, top = 0, results;
-
-		if ( this[0] ) {
-			// Get *real* offsetParent
-			var offsetParent = this.offsetParent(),
-
-			// Get correct offsets
-			offset       = this.offset(),
-			parentOffset = /^body|html$/i.test(offsetParent[0].tagName) ? { top: 0, left: 0 } : offsetParent.offset();
-
-			// Subtract element margins
-			// note: when an element has margin: auto the offsetLeft and marginLeft 
-			// are the same in Safari causing offset.left to incorrectly be 0
-			offset.top  -= num( this, 'marginTop' );
-			offset.left -= num( this, 'marginLeft' );
-
-			// Add offsetParent borders
-			parentOffset.top  += num( offsetParent, 'borderTopWidth' );
-			parentOffset.left += num( offsetParent, 'borderLeftWidth' );
-
-			// Subtract the two offsets
-			results = {
-				top:  offset.top  - parentOffset.top,
-				left: offset.left - parentOffset.left
-			};
-		}
-
-		return results;
-	},
-
-	offsetParent: function() {
-		var offsetParent = this[0].offsetParent;
-		while ( offsetParent &amp;&amp; (!/^body|html$/i.test(offsetParent.tagName) &amp;&amp; jQuery.css(offsetParent, 'position') == 'static') )
-			offsetParent = offsetParent.offsetParent;
-		return jQuery(offsetParent);
-	}
-});
-
-
-// Create scrollLeft and scrollTop methods
-jQuery.each( ['Left', 'Top'], function(i, name) {
-	var method = 'scroll' + name;
-	
-	jQuery.fn[ method ] = function(val) {
-		if (!this[0]) return;
-
-		return val != undefined ?
-
-			// Set the scroll offset
-			this.each(function() {
-				this == window || this == document ?
-					window.scrollTo(
-						!i ? val : jQuery(window).scrollLeft(),
-						 i ? val : jQuery(window).scrollTop()
-					) :
-					this[ method ] = val;
-			}) :
-
-			// Return the scroll offset
-			this[0] == window || this[0] == document ?
-				self[ i ? 'pageYOffset' : 'pageXOffset' ] ||
-					jQuery.boxModel &amp;&amp; document.documentElement[ method ] ||
-					document.body[ method ] :
-				this[0][ method ];
-	};
-});
-// Create innerHeight, innerWidth, outerHeight and outerWidth methods
-jQuery.each([ &quot;Height&quot;, &quot;Width&quot; ], function(i, name){
-
-	var tl = i ? &quot;Left&quot;  : &quot;Top&quot;,  // top or left
-		br = i ? &quot;Right&quot; : &quot;Bottom&quot;; // bottom or right
-
-	// innerHeight and innerWidth
-	jQuery.fn[&quot;inner&quot; + name] = function(){
-		return this[ name.toLowerCase() ]() +
-			num(this, &quot;padding&quot; + tl) +
-			num(this, &quot;padding&quot; + br);
-	};
-
-	// outerHeight and outerWidth
-	jQuery.fn[&quot;outer&quot; + name] = function(margin) {
-		return this[&quot;inner&quot; + name]() +
-			num(this, &quot;border&quot; + tl + &quot;Width&quot;) +
-			num(this, &quot;border&quot; + br + &quot;Width&quot;) +
-			(margin ?
-				num(this, &quot;margin&quot; + tl) + num(this, &quot;margin&quot; + br) : 0);
-	};
-
-});})();
+(function(){var _jQuery=window.jQuery,_$=window.$;var jQuery=window.jQuery=window.$=function(selector,context){return new jQuery.fn.init(selector,context)};var quickExpr=/^[^&lt;]*(&lt;(.|\s)+&gt;)[^&gt;]*$|^#(\w+)$/,isSimple=/^.[^:#\[\.]*$/,undefined;jQuery.fn=jQuery.prototype={init:function(selector,context){selector=selector||document;if(selector.nodeType){this[0]=selector;this.length=1;return this}if(typeof selector==&quot;string&quot;){var match=quickExpr.exec(selector);if(match&amp;&amp;(match[1]||!context)){if(match[1]){selector=jQuery.clean([match[1]],context)}else{var elem=document.getElementById(match[3]);if(elem){if(elem.id!=match[3]){return jQuery().find(selector)}return jQuery(elem)}selector=[]}}else{return jQuery(context).find(selector)}}else{if(jQuery.isFunction(selector)){return jQuery(document)[jQuery.fn.ready?&quot;ready&quot;:&quot;load&quot;](selector)}}return this.setArray(jQuery.makeArray(selector))},jquery:&quot;1.2.6&quot;,size:function(){return this.length},length:0,get:function(num){return num==undefined?jQuery.makeArray(this):this[num]},pushStack:function(elems){var ret=jQuery(elems);ret.prevObject=this;return ret},setArray:function(elems){this.length=0;Array.prototype.push.apply(this,elems);return this},each:function(callback,args){return jQuery.each(this,callback,args)},index:function(elem){var ret=-1;return jQuery.inArray(elem&amp;&amp;elem.jquery?elem[0]:elem,this)},attr:function(name,value,type){var options=name;if(name.constructor==String){if(value===undefined){return this[0]&amp;&amp;jQuery[type||&quot;attr&quot;](this[0],name)}else{options={};options[name]=value}}return this.each(function(i){for(name in options){jQuery.attr(type?this.style:this,name,jQuery.prop(this,options[name],type,i,name))}})},css:function(key,value){if((key==&quot;width&quot;||key==&quot;height&quot;)&amp;&amp;parseFloat(value)&lt;0){value=undefined}return this.attr(key,value,&quot;curCSS&quot;)},text:function(text){if(typeof text!=&quot;object&quot;&amp;&amp;text!=null){return this.empty().append((this[0]&amp;&amp;this[0].ownerDocument||document).createTextNode(text))}var ret=&quot;&quot;;jQuery.each(text||this,function(){jQuery.each(this.childNodes,function(){if(this.nodeType!=8){ret+=this.nodeType!=1?this.nodeValue:jQuery.fn.text([this])}})});return ret},wrapAll:function(html){if(this[0]){jQuery(html,this[0].ownerDocument).clone().insertBefore(this[0]).map(function(){var elem=this;while(elem.firstChild){elem=elem.firstChild}return elem}).append(this)}return this},wrapInner:function(html){return this.each(function(){jQuery(this).contents().wrapAll(html)})},wrap:function(html){return this.each(function(){jQuery(this).wrapAll(html)})},append:function(){return this.domManip(arguments,true,false,function(elem){if(this.nodeType==1){this.appendChild(elem)}})},prepend:function(){return this.domManip(arguments,true,true,function(elem){if(this.nodeType==1){this.insertBefore(elem,this.firstChild)}})},before:function(){return this.domManip(arguments,false,false,function(elem){this.parentNode.insertBefore(elem,this)})},after:function(){return this.domManip(arguments,false,true,function(elem){this.parentNode.insertBefore(elem,this.nextSibling)})},end:function(){return this.prevObject||jQuery([])},find:function(selector){var elems=jQuery.map(this,function(elem){return jQuery.find(selector,elem)});return this.pushStack(/[^+&gt;] [^+&gt;]/.test(selector)||selector.indexOf(&quot;..&quot;)&gt;-1?jQuery.unique(elems):elems)},clone:function(events){var ret=this.map(function(){if(jQuery.browser.msie&amp;&amp;!jQuery.isXMLDoc(this)){var clone=this.cloneNode(true),container=document.createElement(&quot;div&quot;);container.appendChild(clone);return jQuery.clean([container.innerHTML])[0]}else{return this.cloneNode(true)}});var clone=ret.find(&quot;*&quot;).andSelf().each(function(){if(this[expando]!=undefined){this[expando]=null}});if(events===true){this.find(&quot;*&quot;).andSelf().each(function(i){if(this.nodeType==3){return}var events=jQuery.data(this,&quot;events&quot;);for(var type in events){for(var handler in events[type]){jQuery.event.add(clone[i],type,events[type][handler],events[type][handler].data)}}})}return ret},filter:function(selector){return this.pushStack(jQuery.isFunction(selector)&amp;&amp;jQuery.grep(this,function(elem,i){return selector.call(elem,i)})||jQuery.multiFilter(selector,this))},not:function(selector){if(selector.constructor==String){if(isSimple.test(selector)){return this.pushStack(jQuery.multiFilter(selector,this,true))}else{selector=jQuery.multiFilter(selector,this)}}var isArrayLike=selector.length&amp;&amp;selector[selector.length-1]!==undefined&amp;&amp;!selector.nodeType;return this.filter(function(){return isArrayLike?jQuery.inArray(this,selector)&lt;0:this!=selector})},add:function(selector){return this.pushStack(jQuery.unique(jQuery.merge(this.get(),typeof selector==&quot;string&quot;?jQuery(selector):jQuery.makeArray(selector))))},is:function(selector){return !!selector&amp;&amp;jQuery.multiFilter(selector,this).length&gt;0},hasClass:function(selector){return this.is(&quot;.&quot;+selector)},val:function(value){if(value==undefined){if(this.length){var elem=this[0];if(jQuery.nodeName(elem,&quot;select&quot;)){var index=elem.selectedIndex,values=[],options=elem.options,one=elem.type==&quot;select-one&quot;;if(index&lt;0){return null}for(var i=one?index:0,max=one?index+1:options.length;i&lt;max;i++){var option=options[i];if(option.selected){value=jQuery.browser.msie&amp;&amp;!option.attributes.value.specified?option.text:option.value;if(one){return value}values.push(value)}}return values}else{return(this[0].value||&quot;&quot;).replace(/\r/g,&quot;&quot;)}}return undefined}if(value.constructor==Number){value+=&quot;&quot;}return this.each(function(){if(this.nodeType!=1){return}if(value.constructor==Array&amp;&amp;/radio|checkbox/.test(this.type)){this.checked=(jQuery.inArray(this.value,value)&gt;=0||jQuery.inArray(this.name,value)&gt;=0)}else{if(jQuery.nodeName(this,&quot;select&quot;)){var values=jQuery.makeArray(value);jQuery(&quot;option&quot;,this).each(function(){this.selected=(jQuery.inArray(this.value,values)&gt;=0||jQuery.inArray(this.text,values)&gt;=0)});if(!values.length){this.selectedIndex=-1}}else{this.value=value}}})},html:function(value){return value==undefined?(this[0]?this[0].innerHTML:null):this.empty().append(value)},replaceWith:function(value){return this.after(value).remove()},eq:function(i){return this.slice(i,i+1)},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments))},map:function(callback){return this.pushStack(jQuery.map(this,function(elem,i){return callback.call(elem,i,elem)}))},andSelf:function(){return this.add(this.prevObject)},data:function(key,value){var parts=key.split(&quot;.&quot;);parts[1]=parts[1]?&quot;.&quot;+parts[1]:&quot;&quot;;if(value===undefined){var data=this.triggerHandler(&quot;getData&quot;+parts[1]+&quot;!&quot;,[parts[0]]);if(data===undefined&amp;&amp;this.length){data=jQuery.data(this[0],key)}return data===undefined&amp;&amp;parts[1]?this.data(parts[0]):data}else{return this.trigger(&quot;setData&quot;+parts[1]+&quot;!&quot;,[parts[0],value]).each(function(){jQuery.data(this,key,value)})}},removeData:function(key){return this.each(function(){jQuery.removeData(this,key)})},domManip:function(args,table,reverse,callback){var clone=this.length&gt;1,elems;return this.each(function(){if(!elems){elems=jQuery.clean(args,this.ownerDocument);if(reverse){elems.reverse()}}var obj=this;if(table&amp;&amp;jQuery.nodeName(this,&quot;table&quot;)&amp;&amp;jQuery.nodeName(elems[0],&quot;tr&quot;)){obj=this.getElementsByTagName(&quot;tbody&quot;)[0]||this.appendChild(this.ownerDocument.createElement(&quot;tbody&quot;))}var scripts=jQuery([]);jQuery.each(elems,function(){var elem=clone?jQuery(this).clone(true)[0]:this;if(jQuery.nodeName(elem,&quot;script&quot;)){scripts=scripts.add(elem)}else{if(elem.nodeType==1){scripts=scripts.add(jQuery(&quot;script&quot;,elem).remove())}callback.call(obj,elem)}});scripts.each(evalScript)})}};jQuery.fn.init.prototype=jQuery.fn;function evalScript(i,elem){if(elem.src){jQuery.ajax({url:elem.src,async:false,dataType:&quot;script&quot;})}else{jQuery.globalEval(elem.text||elem.textContent||elem.innerHTML||&quot;&quot;)}if(elem.parentNode){elem.parentNode.removeChild(elem)}}function now(){return +new Date}jQuery.extend=jQuery.fn.extend=function(){var target=arguments[0]||{},i=1,length=arguments.length,deep=false,options;if(target.constructor==Boolean){deep=target;target=arguments[1]||{};i=2}if(typeof target!=&quot;object&quot;&amp;&amp;typeof target!=&quot;function&quot;){target={}}if(length==i){target=this;--i}for(;i&lt;length;i++){if((options=arguments[i])!=null){for(var name in options){var src=target[name],copy=options[name];if(target===copy){continue}if(deep&amp;&amp;copy&amp;&amp;typeof copy==&quot;object&quot;&amp;&amp;!copy.nodeType){target[name]=jQuery.extend(deep,src||(copy.length!=null?[]:{}),copy)}else{if(copy!==undefined){target[name]=copy}}}}}return target};var expando=&quot;jQuery&quot;+now(),uuid=0,windowData={},exclude=/z-?index|font-?weight|opacity|zoom|line-?height/i,defaultView=document.defaultView||{};jQuery.extend({noConflict:function(deep){window.$=_$;if(deep){window.jQuery=_jQuery}return jQuery},isFunction:function(fn){return !!fn&amp;&amp;typeof fn!=&quot;string&quot;&amp;&amp;!fn.nodeName&amp;&amp;fn.constructor!=Array&amp;&amp;/^[\s[]?function/.test(fn+&quot;&quot;)},isXMLDoc:function(elem){return elem.documentElement&amp;&amp;!elem.body||elem.tagName&amp;&amp;elem.ownerDocument&amp;&amp;!elem.ownerDocument.body},globalEval:function(data){data=jQuery.trim(data);if(data){var head=document.getElementsByTagName(&quot;head&quot;)[0]||document.documentElement,script=document.createElement(&quot;script&quot;);script.type=&quot;text/javascript&quot;;if(jQuery.browser.msie){script.text=data}else{script.appendChild(document.createTextNode(data))}head.insertBefore(script,head.firstChild);head.removeChild(script)}},nodeName:function(elem,name){return elem.nodeName&amp;&amp;elem.nodeName.toUpperCase()==name.toUpperCase()},cache:{},data:function(elem,name,data){elem=elem==window?windowData:elem;var id=elem[expando];if(!id){id=elem[expando]=++uuid}if(name&amp;&amp;!jQuery.cache[id]){jQuery.cache[id]={}}if(data!==undefined){jQuery.cache[id][name]=data}return name?jQuery.cache[id][name]:id},removeData:function(elem,name){elem=elem==window?windowData:elem;var id=elem[expando];if(name){if(jQuery.cache[id]){delete jQuery.cache[id][name];name=&quot;&quot;;for(name in jQuery.cache[id]){break}if(!name){jQuery.removeData(elem)}}}else{try{delete elem[expando]}catch(e){if(elem.removeAttribute){elem.removeAttribute(expando)}}delete jQuery.cache[id]}},each:function(object,callback,args){var name,i=0,length=object.length;if(args){if(length==undefined){for(name in object){if(callback.apply(object[name],args)===false){break}}}else{for(;i&lt;length;){if(callback.apply(object[i++],args)===false){break}}}}else{if(length==undefined){for(name in object){if(callback.call(object[name],name,object[name])===false){break}}}else{for(var value=object[0];i&lt;length&amp;&amp;callback.call(value,i,value)!==false;value=object[++i]){}}}return object},prop:function(elem,value,type,i,name){if(jQuery.isFunction(value)){value=value.call(elem,i)}return value&amp;&amp;value.constructor==Number&amp;&amp;type==&quot;curCSS&quot;&amp;&amp;!exclude.test(name)?value+&quot;px&quot;:value},className:{add:function(elem,classNames){jQuery.each((classNames||&quot;&quot;).split(/\s+/),function(i,className){if(elem.nodeType==1&amp;&amp;!jQuery.className.has(elem.className,className)){elem.className+=(elem.className?&quot; &quot;:&quot;&quot;)+className}})},remove:function(elem,classNames){if(elem.nodeType==1){elem.className=classNames!=undefined?jQuery.grep(elem.className.split(/\s+/),function(className){return !jQuery.className.has(classNames,className)}).join(&quot; &quot;):&quot;&quot;}},has:function(elem,className){return jQuery.inArray(className,(elem.className||elem).toString().split(/\s+/))&gt;-1}},swap:function(elem,options,callback){var old={};for(var name in options){old[name]=elem.style[name];elem.style[name]=options[name]}callback.call(elem);for(var name in options){elem.style[name]=old[name]}},css:function(elem,name,force){if(name==&quot;width&quot;||name==&quot;height&quot;){var val,props={position:&quot;absolute&quot;,visibility:&quot;hidden&quot;,display:&quot;block&quot;},which=name==&quot;width&quot;?[&quot;Left&quot;,&quot;Right&quot;]:[&quot;Top&quot;,&quot;Bottom&quot;];function getWH(){val=name==&quot;width&quot;?elem.offsetWidth:elem.offsetHeight;var padding=0,border=0;jQuery.each(which,function(){padding+=parseFloat(jQuery.curCSS(elem,&quot;padding&quot;+this,true))||0;border+=parseFloat(jQuery.curCSS(elem,&quot;border&quot;+this+&quot;Width&quot;,true))||0});val-=Math.round(padding+border)}if(jQuery(elem).is(&quot;:visible&quot;)){getWH()}else{jQuery.swap(elem,props,getWH)}return Math.max(0,val)}return jQuery.curCSS(elem,name,force)},curCSS:function(elem,name,force){var ret,style=elem.style;function color(elem){if(!jQuery.browser.safari){return false}var ret=defaultView.getComputedStyle(elem,null);return !ret||ret.getPropertyValue(&quot;color&quot;)==&quot;&quot;}if(name==&quot;opacity&quot;&amp;&amp;jQuery.browser.msie){ret=jQuery.attr(style,&quot;opacity&quot;);return ret==&quot;&quot;?&quot;1&quot;:ret}if(jQuery.browser.opera&amp;&amp;name==&quot;display&quot;){var save=style.outline;style.outline=&quot;0 solid black&quot;;style.outline=save}if(name.match(/float/i)){name=styleFloat}if(!force&amp;&amp;style&amp;&amp;style[name]){ret=style[name]}else{if(defaultView.getComputedStyle){if(name.match(/float/i)){name=&quot;float&quot;}name=name.replace(/([A-Z])/g,&quot;-$1&quot;).toLowerCase();var computedStyle=defaultView.getComputedStyle(elem,null);if(computedStyle&amp;&amp;!color(elem)){ret=computedStyle.getPropertyValue(name)}else{var swap=[],stack=[],a=elem,i=0;for(;a&amp;&amp;color(a);a=a.parentNode){stack.unshift(a)}for(;i&lt;stack.length;i++){if(color(stack[i])){swap[i]=stack[i].style.display;stack[i].style.display=&quot;block&quot;}}ret=name==&quot;display&quot;&amp;&amp;swap[stack.length-1]!=null?&quot;none&quot;:(computedStyle&amp;&amp;computedStyle.getPropertyValue(name))||&quot;&quot;;for(i=0;i&lt;swap.length;i++){if(swap[i]!=null){stack[i].style.display=swap[i]}}}if(name==&quot;opacity&quot;&amp;&amp;ret==&quot;&quot;){ret=&quot;1&quot;}}else{if(elem.currentStyle){var camelCase=name.replace(/\-(\w)/g,function(all,letter){return letter.toUpperCase()});ret=elem.currentStyle[name]||elem.currentStyle[camelCase];if(!/^\d+(px)?$/i.test(ret)&amp;&amp;/^\d/.test(ret)){var left=style.left,rsLeft=elem.runtimeStyle.left;elem.runtimeStyle.left=elem.currentStyle.left;style.left=ret||0;ret=style.pixelLeft+&quot;px&quot;;style.left=left;elem.runtimeStyle.left=rsLeft}}}}return ret},clean:function(elems,context){var ret=[];context=context||document;if(typeof context.createElement==&quot;undefined&quot;){context=context.ownerDocument||context[0]&amp;&amp;context[0].ownerDocument||document}jQuery.each(elems,function(i,elem){if(!elem){return}if(elem.constructor==Number){elem+=&quot;&quot;}if(typeof elem==&quot;string&quot;){elem=elem.replace(/(&lt;(\w+)[^&gt;]*?)\/&gt;/g,function(all,front,tag){return tag.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?all:front+&quot;&gt;&lt;/&quot;+tag+&quot;&gt;&quot;});var tags=jQuery.trim(elem).toLowerCase(),div=context.createElement(&quot;div&quot;);var wrap=!tags.indexOf(&quot;&lt;opt&quot;)&amp;&amp;[1,&quot;&lt;select multiple='multiple'&gt;&quot;,&quot;&lt;/select&gt;&quot;]||!tags.indexOf(&quot;&lt;leg&quot;)&amp;&amp;[1,&quot;&lt;fieldset&gt;&quot;,&quot;&lt;/fieldset&gt;&quot;]||tags.match(/^&lt;(thead|tbody|tfoot|colg|cap)/)&amp;&amp;[1,&quot;&lt;table&gt;&quot;,&quot;&lt;/table&gt;&quot;]||!tags.indexOf(&quot;&lt;tr&quot;)&amp;&amp;[2,&quot;&lt;table&gt;&lt;tbody&gt;&quot;,&quot;&lt;/tbody&gt;&lt;/table&gt;&quot;]||(!tags.indexOf(&quot;&lt;td&quot;)||!tags.indexOf(&quot;&lt;th&quot;))&amp;&amp;[3,&quot;&lt;table&gt;&lt;tbody&gt;&lt;tr&gt;&quot;,&quot;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&quot;]||!tags.indexOf(&quot;&lt;col&quot;)&amp;&amp;[2,&quot;&lt;table&gt;&lt;tbody&gt;&lt;/tbody&gt;&lt;colgroup&gt;&quot;,&quot;&lt;/colgroup&gt;&lt;/table&gt;&quot;]||jQuery.browser.msie&amp;&amp;[1,&quot;div&lt;div&gt;&quot;,&quot;&lt;/div&gt;&quot;]||[0,&quot;&quot;,&quot;&quot;];div.innerHTML=wrap[1]+elem+wrap[2];while(wrap[0]--){div=div.lastChild}if(jQuery.browser.msie){var tbody=!tags.indexOf(&quot;&lt;table&quot;)&amp;&amp;tags.indexOf(&quot;&lt;tbody&quot;)&lt;0?div.firstChild&amp;&amp;div.firstChild.childNodes:wrap[1]==&quot;&lt;table&gt;&quot;&amp;&amp;tags.indexOf(&quot;&lt;tbody&quot;)&lt;0?div.childNodes:[];for(var j=tbody.length-1;j&gt;=0;--j){if(jQuery.nodeName(tbody[j],&quot;tbody&quot;)&amp;&amp;!tbody[j].childNodes.length){tbody[j].parentNode.removeChild(tbody[j])}}if(/^\s/.test(elem)){div.insertBefore(context.createTextNode(elem.match(/^\s*/)[0]),div.firstChild)}}elem=jQuery.makeArray(div.childNodes)}if(elem.length===0&amp;&amp;(!jQuery.nodeName(elem,&quot;form&quot;)&amp;&amp;!jQuery.nodeName(elem,&quot;select&quot;))){return}if(elem[0]==undefined||jQuery.nodeName(elem,&quot;form&quot;)||elem.options){ret.push(elem)}else{ret=jQuery.merge(ret,elem)}});return ret},attr:function(elem,name,value){if(!elem||elem.nodeType==3||elem.nodeType==8){return undefined}var notxml=!jQuery.isXMLDoc(elem),set=value!==undefined,msie=jQuery.browser.msie;name=notxml&amp;&amp;jQuery.props[name]||name;if(elem.tagName){var special=/href|src|style/.test(name);if(name==&quot;selected&quot;&amp;&amp;jQuery.browser.safari){elem.parentNode.selectedIndex}if(name in elem&amp;&amp;notxml&amp;&amp;!special){if(set){if(name==&quot;type&quot;&amp;&amp;jQuery.nodeName(elem,&quot;input&quot;)&amp;&amp;elem.parentNode){throw&quot;type property can't be changed&quot;}elem[name]=value}if(jQuery.nodeName(elem,&quot;form&quot;)&amp;&amp;elem.getAttributeNode(name)){return elem.getAttributeNode(name).nodeValue}return elem[name]}if(msie&amp;&amp;notxml&amp;&amp;name==&quot;style&quot;){return jQuery.attr(elem.style,&quot;cssText&quot;,value)}if(set){elem.setAttribute(name,&quot;&quot;+value)}var attr=msie&amp;&amp;notxml&amp;&amp;special?elem.getAttribute(name,2):elem.getAttribute(name);return attr===null?undefined:attr}if(msie&amp;&amp;name==&quot;opacity&quot;){if(set){elem.zoom=1;elem.filter=(elem.filter||&quot;&quot;).replace(/alpha\([^)]*\)/,&quot;&quot;)+(parseInt(value)+&quot;&quot;==&quot;NaN&quot;?&quot;&quot;:&quot;alpha(opacity=&quot;+value*100+&quot;)&quot;)}return elem.filter&amp;&amp;elem.filter.indexOf(&quot;opacity=&quot;)&gt;=0?(parseFloat(elem.filter.match(/opacity=([^)]*)/)[1])/100)+&quot;&quot;:&quot;&quot;}name=name.replace(/-([a-z])/ig,function(all,letter){return letter.toUpperCase()});if(set){elem[name]=value}return elem[name]},trim:function(text){return(text||&quot;&quot;).replace(/^\s+|\s+$/g,&quot;&quot;)},makeArray:function(array){var ret=[];if(array!=null){var i=array.length;if(i==null||array.split||array.setInterval||array.call){ret[0]=array}else{while(i){ret[--i]=array[i]}}}return ret},inArray:function(elem,array){for(var i=0,length=array.length;i&lt;length;i++){if(array[i]===elem){return i}}return -1},merge:function(first,second){var i=0,elem,pos=first.length;if(jQuery.browser.msie){while(elem=second[i++]){if(elem.nodeType!=8){first[pos++]=elem}}}else{while(elem=second[i++]){first[pos++]=elem}}return first},unique:function(array){var ret=[],done={};try{for(var i=0,length=array.length;i&lt;length;i++){var id=jQuery.data(array[i]);if(!done[id]){done[id]=true;ret.push(array[i])}}}catch(e){ret=array}return ret},grep:function(elems,callback,inv){var ret=[];for(var i=0,length=elems.length;i&lt;length;i++){if(!inv!=!callback(elems[i],i)){ret.push(elems[i])}}return ret},map:function(elems,callback){var ret=[];for(var i=0,length=elems.length;i&lt;length;i++){var value=callback(elems[i],i);if(value!=null){ret[ret.length]=value}}return ret.concat.apply([],ret)}});var userAgent=navigator.userAgent.toLowerCase();jQuery.browser={version:(userAgent.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[])[1],safari:/webkit/.test(userAgent),opera:/opera/.test(userAgent),msie:/msie/.test(userAgent)&amp;&amp;!/opera/.test(userAgent),mozilla:/mozilla/.test(userAgent)&amp;&amp;!/(compatible|webkit)/.test(userAgent)};var styleFloat=jQuery.browser.msie?&quot;styleFloat&quot;:&quot;cssFloat&quot;;jQuery.extend({boxModel:!jQuery.browser.msie||document.compatMode==&quot;CSS1Compat&quot;,props:{&quot;for&quot;:&quot;htmlFor&quot;,&quot;class&quot;:&quot;className&quot;,&quot;float&quot;:styleFloat,cssFloat:styleFloat,styleFloat:styleFloat,readonly:&quot;readOnly&quot;,maxlength:&quot;maxLength&quot;,cellspacing:&quot;cellSpacing&quot;}});jQuery.each({parent:function(elem){return elem.parentNode},parents:function(elem){return jQuery.dir(elem,&quot;parentNode&quot;)},next:function(elem){return jQuery.nth(elem,2,&quot;nextSibling&quot;)},prev:function(elem){return jQuery.nth(elem,2,&quot;previousSibling&quot;)},nextAll:function(elem){return jQuery.dir(elem,&quot;nextSibling&quot;)},prevAll:function(elem){return jQuery.dir(elem,&quot;previousSibling&quot;)},siblings:function(elem){return jQuery.sibling(elem.parentNode.firstChild,elem)},children:function(elem){return jQuery.sibling(elem.firstChild)},contents:function(elem){return jQuery.nodeName(elem,&quot;iframe&quot;)?elem.contentDocument||elem.contentWindow.document:jQuery.makeArray(elem.childNodes)}},function(name,fn){jQuery.fn[name]=function(selector){var ret=jQuery.map(this,fn);if(selector&amp;&amp;typeof selector==&quot;string&quot;){ret=jQuery.multiFilter(selector,ret)}return this.pushStack(jQuery.unique(ret))}});jQuery.each({appendTo:&quot;append&quot;,prependTo:&quot;prepend&quot;,insertBefore:&quot;before&quot;,insertAfter:&quot;after&quot;,replaceAll:&quot;replaceWith&quot;},function(name,original){jQuery.fn[name]=function(){var args=arguments;return this.each(function(){for(var i=0,length=args.length;i&lt;length;i++){jQuery(args[i])[original](this)}})}});jQuery.each({removeAttr:function(name){jQuery.attr(this,name,&quot;&quot;);if(this.nodeType==1){this.removeAttribute(name)}},addClass:function(classNames){jQuery.className.add(this,classNames)},removeClass:function(classNames){jQuery.className.remove(this,classNames)},toggleClass:function(classNames){jQuery.className[jQuery.className.has(this,classNames)?&quot;remove&quot;:&quot;add&quot;](this,classNames)},remove:function(selector){if(!selector||jQuery.filter(selector,[this]).r.length){jQuery(&quot;*&quot;,this).add(this).each(function(){jQuery.event.remove(this);jQuery.removeData(this)});if(this.parentNode){this.parentNode.removeChild(this)}}},empty:function(){jQuery(&quot;&gt;*&quot;,this).remove();while(this.firstChild){this.removeChild(this.firstChild)}}},function(name,fn){jQuery.fn[name]=function(){return this.each(fn,arguments)}});jQuery.each([&quot;Height&quot;,&quot;Width&quot;],function(i,name){var type=name.toLowerCase();jQuery.fn[type]=function(size){return this[0]==window?jQuery.browser.opera&amp;&amp;document.body[&quot;client&quot;+name]||jQuery.browser.safari&amp;&amp;window[&quot;inner&quot;+name]||document.compatMode==&quot;CSS1Compat&quot;&amp;&amp;document.documentElement[&quot;client&quot;+name]||document.body[&quot;client&quot;+name]:this[0]==document?Math.max(Math.max(document.body[&quot;scroll&quot;+name],document.documentElement[&quot;scroll&quot;+name]),Math.max(document.body[&quot;offset&quot;+name],document.documentElement[&quot;offset&quot;+name])):size==undefined?(this.length?jQuery.css(this[0],type):null):this.css(type,size.constructor==String?size:size+&quot;px&quot;)}});function num(elem,prop){return elem[0]&amp;&amp;parseInt(jQuery.curCSS(elem[0],prop,true),10)||0}var chars=jQuery.browser.safari&amp;&amp;parseInt(jQuery.browser.version)&lt;417?&quot;(?:[\\w*_-]|\\\\.)&quot;:&quot;(?:[\\w\u0128-\uFFFF*_-]|\\\\.)&quot;,quickChild=new RegExp(&quot;^&gt;\\s*(&quot;+chars+&quot;+)&quot;),quickID=new RegExp(&quot;^(&quot;+chars+&quot;+)(#)(&quot;+chars+&quot;+)&quot;),quickClass=new RegExp(&quot;^([#.]?)(&quot;+chars+&quot;*)&quot;);jQuery.extend({expr:{&quot;&quot;:function(a,i,m){return m[2]==&quot;*&quot;||jQuery.nodeName(a,m[2])},&quot;#&quot;:function(a,i,m){return a.getAttribute(&quot;id&quot;)==m[2]},&quot;:&quot;:{lt:function(a,i,m){return i&lt;m[3]-0},gt:function(a,i,m){return i&gt;m[3]-0},nth:function(a,i,m){return m[3]-0==i},eq:function(a,i,m){return m[3]-0==i},first:function(a,i){return i==0},last:function(a,i,m,r){return i==r.length-1},even:function(a,i){return i%2==0},odd:function(a,i){return i%2},&quot;first-child&quot;:function(a){return a.parentNode.getElementsByTagName(&quot;*&quot;)[0]==a},&quot;last-child&quot;:function(a){return jQuery.nth(a.parentNode.lastChild,1,&quot;previousSibling&quot;)==a},&quot;only-child&quot;:function(a){return !jQuery.nth(a.parentNode.lastChild,2,&quot;previousSibling&quot;)},parent:function(a){return a.firstChild},empty:function(a){return !a.firstChild},contains:function(a,i,m){return(a.textContent||a.innerText||jQuery(a).text()||&quot;&quot;).indexOf(m[3])&gt;=0},visible:function(a){return&quot;hidden&quot;!=a.type&amp;&amp;jQuery.css(a,&quot;display&quot;)!=&quot;none&quot;&amp;&amp;jQuery.css(a,&quot;visibility&quot;)!=&quot;hidden&quot;},hidden:function(a){return&quot;hidden&quot;==a.type||jQuery.css(a,&quot;display&quot;)==&quot;none&quot;||jQuery.css(a,&quot;visibility&quot;)==&quot;hidden&quot;},enabled:function(a){return !a.disabled},disabled:function(a){return a.disabled},checked:function(a){return a.checked},selected:function(a){return a.selected||jQuery.attr(a,&quot;selected&quot;)},text:function(a){return&quot;text&quot;==a.type},radio:function(a){return&quot;radio&quot;==a.type},checkbox:function(a){return&quot;checkbox&quot;==a.type},file:function(a){return&quot;file&quot;==a.type},password:function(a){return&quot;password&quot;==a.type},submit:function(a){return&quot;submit&quot;==a.type},image:function(a){return&quot;image&quot;==a.type},reset:function(a){return&quot;reset&quot;==a.type},button:function(a){return&quot;button&quot;==a.type||jQuery.nodeName(a,&quot;button&quot;)},input:function(a){return/input|select|textarea|button/i.test(a.nodeName)},has:function(a,i,m){return jQuery.find(m[3],a).length},header:function(a){return/h\d/i.test(a.nodeName)},animated:function(a){return jQuery.grep(jQuery.timers,function(fn){return a==fn.elem}).length}}},parse:[/^(\[) *@?([\w-]+) *([!*$^~=]*) *('?&quot;?)(.*?)\4 *\]/,/^(:)([\w-]+)\(&quot;?'?(.*?(\(.*?\))?[^(]*?)&quot;?'?\)/,new RegExp(&quot;^([:.#]*)(&quot;+chars+&quot;+)&quot;)],multiFilter:function(expr,elems,not){var old,cur=[];while(expr&amp;&amp;expr!=old){old=expr;var f=jQuery.filter(expr,elems,not);expr=f.t.replace(/^\s*,\s*/,&quot;&quot;);cur=not?elems=f.r:jQuery.merge(cur,f.r)}return cur},find:function(t,context){if(typeof t!=&quot;string&quot;){return[t]}if(context&amp;&amp;context.nodeType!=1&amp;&amp;context.nodeType!=9){return[]}context=context||document;var ret=[context],done=[],last,nodeName;while(t&amp;&amp;last!=t){var r=[];last=t;t=jQuery.trim(t);var foundToken=false,re=quickChild,m=re.exec(t);if(m){nodeName=m[1].toUpperCase();for(var i=0;ret[i];i++){for(var c=ret[i].firstChild;c;c=c.nextSibling){if(c.nodeType==1&amp;&amp;(nodeName==&quot;*&quot;||c.nodeName.toUpperCase()==nodeName)){r.push(c)}}}ret=r;t=t.replace(re,&quot;&quot;);if(t.indexOf(&quot; &quot;)==0){continue}foundToken=true}else{re=/^([&gt;+~])\s*(\w*)/i;if((m=re.exec(t))!=null){r=[];var merge={};nodeName=m[2].toUpperCase();m=m[1];for(var j=0,rl=ret.length;j&lt;rl;j++){var n=m==&quot;~&quot;||m==&quot;+&quot;?ret[j].nextSibling:ret[j].firstChild;for(;n;n=n.nextSibling){if(n.nodeType==1){var id=jQuery.data(n);if(m==&quot;~&quot;&amp;&amp;merge[id]){break}if(!nodeName||n.nodeName.toUpperCase()==nodeName){if(m==&quot;~&quot;){merge[id]=true}r.push(n)}if(m==&quot;+&quot;){break}}}}ret=r;t=jQuery.trim(t.replace(re,&quot;&quot;));foundToken=true}}if(t&amp;&amp;!foundToken){if(!t.indexOf(&quot;,&quot;)){if(context==ret[0]){ret.shift()}done=jQuery.merge(done,ret);r=ret=[context];t=&quot; &quot;+t.substr(1,t.length)}else{var re2=quickID;var m=re2.exec(t);if(m){m=[0,m[2],m[3],m[1]]}else{re2=quickClass;m=re2.exec(t)}m[2]=m[2].replace(/\\/g,&quot;&quot;);var elem=ret[ret.length-1];if(m[1]==&quot;#&quot;&amp;&amp;elem&amp;&amp;elem.getElementById&amp;&amp;!jQuery.isXMLDoc(elem)){var oid=elem.getElementById(m[2]);if((jQuery.browser.msie||jQuery.browser.opera)&amp;&amp;oid&amp;&amp;typeof oid.id==&quot;string&quot;&amp;&amp;oid.id!=m[2]){oid=jQuery('[@id=&quot;'+m[2]+'&quot;]',elem)[0]}ret=r=oid&amp;&amp;(!m[3]||jQuery.nodeName(oid,m[3]))?[oid]:[]}else{for(var i=0;ret[i];i++){var tag=m[1]==&quot;#&quot;&amp;&amp;m[3]?m[3]:m[1]!=&quot;&quot;||m[0]==&quot;&quot;?&quot;*&quot;:m[2];if(tag==&quot;*&quot;&amp;&amp;ret[i].nodeName.toLowerCase()==&quot;object&quot;){tag=&quot;param&quot;}r=jQuery.merge(r,ret[i].getElementsByTagName(tag))}if(m[1]==&quot;.&quot;){r=jQuery.classFilter(r,m[2])}if(m[1]==&quot;#&quot;){var tmp=[];for(var i=0;r[i];i++){if(r[i].getAttribute(&quot;id&quot;)==m[2]){tmp=[r[i]];break}}r=tmp}ret=r}t=t.replace(re2,&quot;&quot;)}}if(t){var val=jQuery.filter(t,r);ret=r=val.r;t=jQuery.trim(val.t)}}if(t){ret=[]}if(ret&amp;&amp;context==ret[0]){ret.shift()}done=jQuery.merge(done,ret);return done},classFilter:function(r,m,not){m=&quot; &quot;+m+&quot; &quot;;var tmp=[];for(var i=0;r[i];i++){var pass=(&quot; &quot;+r[i].className+&quot; &quot;).indexOf(m)&gt;=0;if(!not&amp;&amp;pass||not&amp;&amp;!pass){tmp.push(r[i])}}return tmp},filter:function(t,r,not){var last;while(t&amp;&amp;t!=last){last=t;var p=jQuery.parse,m;for(var i=0;p[i];i++){m=p[i].exec(t);if(m){t=t.substring(m[0].length);m[2]=m[2].replace(/\\/g,&quot;&quot;);break}}if(!m){break}if(m[1]==&quot;:&quot;&amp;&amp;m[2]==&quot;not&quot;){r=isSimple.test(m[3])?jQuery.filter(m[3],r,true).r:jQuery(r).not(m[3])}else{if(m[1]==&quot;.&quot;){r=jQuery.classFilter(r,m[2],not)}else{if(m[1]==&quot;[&quot;){var tmp=[],type=m[3];for(var i=0,rl=r.length;i&lt;rl;i++){var a=r[i],z=a[jQuery.props[m[2]]||m[2]];if(z==null||/href|src|selected/.test(m[2])){z=jQuery.attr(a,m[2])||&quot;&quot;}if((type==&quot;&quot;&amp;&amp;!!z||type==&quot;=&quot;&amp;&amp;z==m[5]||type==&quot;!=&quot;&amp;&amp;z!=m[5]||type==&quot;^=&quot;&amp;&amp;z&amp;&amp;!z.indexOf(m[5])||type==&quot;$=&quot;&amp;&amp;z.substr(z.length-m[5].length)==m[5]||(type==&quot;*=&quot;||type==&quot;~=&quot;)&amp;&amp;z.indexOf(m[5])&gt;=0)^not){tmp.push(a)}}r=tmp}else{if(m[1]==&quot;:&quot;&amp;&amp;m[2]==&quot;nth-child&quot;){var merge={},tmp=[],test=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(m[3]==&quot;even&quot;&amp;&amp;&quot;2n&quot;||m[3]==&quot;odd&quot;&amp;&amp;&quot;2n+1&quot;||!/\D/.test(m[3])&amp;&amp;&quot;0n+&quot;+m[3]||m[3]),first=(test[1]+(test[2]||1))-0,last=test[3]-0;for(var i=0,rl=r.length;i&lt;rl;i++){var node=r[i],parentNode=node.parentNode,id=jQuery.data(parentNode);if(!merge[id]){var c=1;for(var n=parentNode.firstChild;n;n=n.nextSibling){if(n.nodeType==1){n.nodeIndex=c++}}merge[id]=true}var add=false;if(first==0){if(node.nodeIndex==last){add=true}}else{if((node.nodeIndex-last)%first==0&amp;&amp;(node.nodeIndex-last)/first&gt;=0){add=true}}if(add^not){tmp.push(node)}}r=tmp}else{var fn=jQuery.expr[m[1]];if(typeof fn==&quot;object&quot;){fn=fn[m[2]]}if(typeof fn==&quot;string&quot;){fn=eval(&quot;false||function(a,i){return &quot;+fn+&quot;;}&quot;)}r=jQuery.grep(r,function(elem,i){return fn(elem,i,m,r)},not)}}}}}return{r:r,t:t}},dir:function(elem,dir){var matched=[],cur=elem[dir];while(cur&amp;&amp;cur!=document){if(cur.nodeType==1){matched.push(cur)}cur=cur[dir]}return matched},nth:function(cur,result,dir,elem){result=result||1;var num=0;for(;cur;cur=cur[dir]){if(cur.nodeType==1&amp;&amp;++num==result){break}}return cur},sibling:function(n,elem){var r=[];for(;n;n=n.nextSibling){if(n.nodeType==1&amp;&amp;n!=elem){r.push(n)}}return r}});jQuery.event={add:function(elem,types,handler,data){if(elem.nodeType==3||elem.nodeType==8){return}if(jQuery.browser.msie&amp;&amp;elem.setInterval){elem=window}if(!handler.guid){handler.guid=this.guid++}if(data!=undefined){var fn=handler;handler=this.proxy(fn,function(){return fn.apply(this,arguments)});handler.data=data}var events=jQuery.data(elem,&quot;events&quot;)||jQuery.data(elem,&quot;events&quot;,{}),handle=jQuery.data(elem,&quot;handle&quot;)||jQuery.data(elem,&quot;handle&quot;,function(){if(typeof jQuery!=&quot;undefined&quot;&amp;&amp;!jQuery.event.triggered){return jQuery.event.handle.apply(arguments.callee.elem,arguments)}});handle.elem=elem;jQuery.each(types.split(/\s+/),function(index,type){var parts=type.split(&quot;.&quot;);type=parts[0];handler.type=parts[1];var handlers=events[type];if(!handlers){handlers=events[type]={};if(!jQuery.event.special[type]||jQuery.event.special[type].setup.call(elem)===false){if(elem.addEventListener){elem.addEventListener(type,handle,false)}else{if(elem.attachEvent){elem.attachEvent(&quot;on&quot;+type,handle)}}}}handlers[handler.guid]=handler;jQuery.event.global[type]=true});elem=null},guid:1,global:{},remove:function(elem,types,handler){if(elem.nodeType==3||elem.nodeType==8){return}var events=jQuery.data(elem,&quot;events&quot;),ret,index;if(events){if(types==undefined||(typeof types==&quot;string&quot;&amp;&amp;types.charAt(0)==&quot;.&quot;)){for(var type in events){this.remove(elem,type+(types||&quot;&quot;))}}else{if(types.type){handler=types.handler;types=types.type}jQuery.each(types.split(/\s+/),function(index,type){var parts=type.split(&quot;.&quot;);type=parts[0];if(events[type]){if(handler){delete events[type][handler.guid]}else{for(handler in events[type]){if(!parts[1]||events[type][handler].type==parts[1]){delete events[type][handler]}}}for(ret in events[type]){break}if(!ret){if(!jQuery.event.special[type]||jQuery.event.special[type].teardown.call(elem)===false){if(elem.removeEventListener){elem.removeEventListener(type,jQuery.data(elem,&quot;handle&quot;),false)}else{if(elem.detachEvent){elem.detachEvent(&quot;on&quot;+type,jQuery.data(elem,&quot;handle&quot;))}}}ret=null;delete events[type]}}})}for(ret in events){break}if(!ret){var handle=jQuery.data(elem,&quot;handle&quot;);if(handle){handle.elem=null}jQuery.removeData(elem,&quot;events&quot;);jQuery.removeData(elem,&quot;handle&quot;)}}},trigger:function(type,data,elem,donative,extra){data=jQuery.makeArray(data);if(type.indexOf(&quot;!&quot;)&gt;=0){type=type.slice(0,-1);var exclusive=true}if(!elem){if(this.global[type]){jQuery(&quot;*&quot;).add([window,document]).trigger(type,data)}}else{if(elem.nodeType==3||elem.nodeType==8){return undefined}var val,ret,fn=jQuery.isFunction(elem[type]||null),event=!data[0]||!data[0].preventDefault;if(event){data.unshift({type:type,target:elem,preventDefault:function(){},stopPropagation:function(){},timeStamp:now()});data[0][expando]=true}data[0].type=type;if(exclusive){data[0].exclusive=true}var handle=jQuery.data(elem,&quot;handle&quot;);if(handle){val=handle.apply(elem,data)}if((!fn||(jQuery.nodeName(elem,&quot;a&quot;)&amp;&amp;type==&quot;click&quot;))&amp;&amp;elem[&quot;on&quot;+type]&amp;&amp;elem[&quot;on&quot;+type].apply(elem,data)===false){val=false}if(event){data.shift()}if(extra&amp;&amp;jQuery.isFunction(extra)){ret=extra.apply(elem,val==null?data:data.concat(val));if(ret!==undefined){val=ret}}if(fn&amp;&amp;donative!==false&amp;&amp;val!==false&amp;&amp;!(jQuery.nodeName(elem,&quot;a&quot;)&amp;&amp;type==&quot;click&quot;)){this.triggered=true;try{elem[type]()}catch(e){}}this.triggered=false}return val},handle:function(event){var val,ret,namespace,all,handlers;event=arguments[0]=jQuery.event.fix(event||window.event);namespace=event.type.split(&quot;.&quot;);event.type=namespace[0];namespace=namespace[1];all=!namespace&amp;&amp;!event.exclusive;handlers=(jQuery.data(this,&quot;events&quot;)||{})[event.type];for(var j in handlers){var handler=handlers[j];if(all||handler.type==namespace){event.handler=handler;event.data=handler.data;ret=handler.apply(this,arguments);if(val!==false){val=ret}if(ret===false){event.preventDefault();event.stopPropagation()}}}return val},fix:function(event){if(event[expando]==true){return event}var originalEvent=event;event={originalEvent:originalEvent};var props=&quot;altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target timeStamp toElement type view wheelDelta which&quot;.split(&quot; &quot;);for(var i=props.length;i;i--){event[props[i]]=originalEvent[props[i]]}event[expando]=true;event.preventDefault=function(){if(originalEvent.preventDefault){originalEvent.preventDefault()}originalEvent.returnValue=false};event.stopPropagation=function(){if(originalEvent.stopPropagation){originalEvent.stopPropagation()}originalEvent.cancelBubble=true};event.timeStamp=event.timeStamp||now();if(!event.target){event.target=event.srcElement||document}if(event.target.nodeType==3){event.target=event.target.parentNode}if(!event.relatedTarget&amp;&amp;event.fromElement){event.relatedTarget=event.fromElement==event.target?event.toElement:event.fromElement}if(event.pageX==null&amp;&amp;event.clientX!=null){var doc=document.documentElement,body=document.body;event.pageX=event.clientX+(doc&amp;&amp;doc.scrollLeft||body&amp;&amp;body.scrollLeft||0)-(doc.clientLeft||0);event.pageY=event.clientY+(doc&amp;&amp;doc.scrollTop||body&amp;&amp;body.scrollTop||0)-(doc.clientTop||0)}if(!event.which&amp;&amp;((event.charCode||event.charCode===0)?event.charCode:event.keyCode)){event.which=event.charCode||event.keyCode}if(!event.metaKey&amp;&amp;event.ctrlKey){event.metaKey=event.ctrlKey}if(!event.which&amp;&amp;event.button){event.which=(event.button&amp;1?1:(event.button&amp;2?3:(event.button&amp;4?2:0)))}return event},proxy:function(fn,proxy){proxy.guid=fn.guid=fn.guid||proxy.guid||this.guid++;return proxy},special:{ready:{setup:function(){bindReady();return},teardown:function(){return}},mouseenter:{setup:function(){if(jQuery.browser.msie){return false}jQuery(this).bind(&quot;mouseover&quot;,jQuery.event.special.mouseenter.handler);return true},teardown:function(){if(jQuery.browser.msie){return false}jQuery(this).unbind(&quot;mouseover&quot;,jQuery.event.special.mouseenter.handler);return true},handler:function(event){if(withinElement(event,this)){return true}event.type=&quot;mouseenter&quot;;return jQuery.event.handle.apply(this,arguments)}},mouseleave:{setup:function(){if(jQuery.browser.msie){return false}jQuery(this).bind(&quot;mouseout&quot;,jQuery.event.special.mouseleave.handler);return true},teardown:function(){if(jQuery.browser.msie){return false}jQuery(this).unbind(&quot;mouseout&quot;,jQuery.event.special.mouseleave.handler);return true},handler:function(event){if(withinElement(event,this)){return true}event.type=&quot;mouseleave&quot;;return jQuery.event.handle.apply(this,arguments)}}}};jQuery.fn.extend({bind:function(type,data,fn){return type==&quot;unload&quot;?this.one(type,data,fn):this.each(function(){jQuery.event.add(this,type,fn||data,fn&amp;&amp;data)})},one:function(type,data,fn){var one=jQuery.event.proxy(fn||data,function(event){jQuery(this).unbind(event,one);return(fn||data).apply(this,arguments)});return this.each(function(){jQuery.event.add(this,type,one,fn&amp;&amp;data)})},unbind:function(type,fn){return this.each(function(){jQuery.event.remove(this,type,fn)})},trigger:function(type,data,fn){return this.each(function(){jQuery.event.trigger(type,data,this,true,fn)})},triggerHandler:function(type,data,fn){return this[0]&amp;&amp;jQuery.event.trigger(type,data,this[0],false,fn)},toggle:function(fn){var args=arguments,i=1;while(i&lt;args.length){jQuery.event.proxy(fn,args[i++])}return this.click(jQuery.event.proxy(fn,function(event){this.lastToggle=(this.lastToggle||0)%i;event.preventDefault();return args[this.lastToggle++].apply(this,arguments)||false}))},hover:function(fnOver,fnOut){return this.bind(&quot;mouseenter&quot;,fnOver).bind(&quot;mouseleave&quot;,fnOut)},ready:function(fn){bindReady();if(jQuery.isReady){fn.call(document,jQuery)}else{jQuery.readyList.push(function(){return fn.call(this,jQuery)})}return this}});jQuery.extend({isReady:false,readyList:[],ready:function(){if(!jQuery.isReady){jQuery.isReady=true;if(jQuery.readyList){jQuery.each(jQuery.readyList,function(){this.call(document)});jQuery.readyList=null}jQuery(document).triggerHandler(&quot;ready&quot;)}}});var readyBound=false;function bindReady(){if(readyBound){return}readyBound=true;if(document.addEventListener&amp;&amp;!jQuery.browser.opera){document.addEventListener(&quot;DOMContentLoaded&quot;,jQuery.ready,false)}if(jQuery.browser.msie&amp;&amp;window==top){(function(){if(jQuery.isReady){return}try{document.documentElement.doScroll(&quot;left&quot;)}catch(error){setTimeout(arguments.callee,0);return}jQuery.ready()})()}if(jQuery.browser.opera){document.addEventListener(&quot;DOMContentLoaded&quot;,function(){if(jQuery.isReady){return}for(var i=0;i&lt;document.styleSheets.length;i++){if(document.styleSheets[i].disabled){setTimeout(arguments.callee,0);return}}jQuery.ready()},false)}if(jQuery.browser.safari){var numStyles;(function(){if(jQuery.isReady){return}if(document.readyState!=&quot;loaded&quot;&amp;&amp;document.readyState!=&quot;complete&quot;){setTimeout(arguments.callee,0);return}if(numStyles===undefined){numStyles=jQuery(&quot;style, link[rel=stylesheet]&quot;).length}if(document.styleSheets.length!=numStyles){setTimeout(arguments.callee,0);return}jQuery.ready()})()}jQuery.event.add(window,&quot;load&quot;,jQuery.ready)}jQuery.each((&quot;blur,focus,load,resize,scroll,unload,click,dblclick,mousedown,mouseup,mousemove,mouseover,mouseout,change,select,submit,keydown,keypress,keyup,error&quot;).split(&quot;,&quot;),function(i,name){jQuery.fn[name]=function(fn){return fn?this.bind(name,fn):this.trigger(name)}});var withinElement=function(event,elem){var parent=event.relatedTarget;while(parent&amp;&amp;parent!=elem){try{parent=parent.parentNode}catch(error){parent=elem}}return parent==elem};jQuery(window).bind(&quot;unload&quot;,function(){jQuery(&quot;*&quot;).add(document).unbind()});jQuery.fn.extend({_load:jQuery.fn.load,load:function(url,params,callback){if(typeof url!=&quot;string&quot;){return this._load(url)}var off=url.indexOf(&quot; &quot;);if(off&gt;=0){var selector=url.slice(off,url.length);url=url.slice(0,off)}callback=callback||function(){};var type=&quot;GET&quot;;if(params){if(jQuery.isFunction(params)){callback=params;params=null}else{params=jQuery.param(params);type=&quot;POST&quot;}}var self=this;jQuery.ajax({url:url,type:type,dataType:&quot;html&quot;,data:params,complete:function(res,status){if(status==&quot;success&quot;||status==&quot;notmodified&quot;){self.html(selector?jQuery(&quot;&lt;div/&gt;&quot;).append(res.responseText.replace(/&lt;script(.|\s)*?\/script&gt;/g,&quot;&quot;)).find(selector):res.responseText)}self.each(callback,[res.responseText,status,res])}});return this},serialize:function(){return jQuery.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return jQuery.nodeName(this,&quot;form&quot;)?jQuery.makeArray(this.elements):this}).filter(function(){return this.name&amp;&amp;!this.disabled&amp;&amp;(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password/i.test(this.type))}).map(function(i,elem){var val=jQuery(this).val();return val==null?null:val.constructor==Array?jQuery.map(val,function(val,i){return{name:elem.name,value:val}}):{name:elem.name,value:val}}).get()}});jQuery.each(&quot;ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend&quot;.split(&quot;,&quot;),function(i,o){jQuery.fn[o]=function(f){return this.bind(o,f)}});var jsc=now();jQuery.extend({get:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data=null}return jQuery.ajax({type:&quot;GET&quot;,url:url,data:data,success:callback,dataType:type})},getScript:function(url,callback){return jQuery.get(url,null,callback,&quot;script&quot;)},getJSON:function(url,data,callback){return jQuery.get(url,data,callback,&quot;json&quot;)},post:function(url,data,callback,type){if(jQuery.isFunction(data)){callback=data;data={}}return jQuery.ajax({type:&quot;POST&quot;,url:url,data:data,success:callback,dataType:type})},ajaxSetup:function(settings){jQuery.extend(jQuery.ajaxSettings,settings)},ajaxSettings:{url:location.href,global:true,type:&quot;GET&quot;,timeout:0,contentType:&quot;application/x-www-form-urlencoded&quot;,processData:true,async:true,data:null,username:null,password:null,accepts:{xml:&quot;application/xml, text/xml&quot;,html:&quot;text/html&quot;,script:&quot;text/javascript, application/javascript&quot;,json:&quot;application/json, text/javascript&quot;,text:&quot;text/plain&quot;,_default:&quot;*/*&quot;}},lastModified:{},ajax:function(s){s=jQuery.extend(true,s,jQuery.extend(true,{},jQuery.ajaxSettings,s));var jsonp,jsre=/=\?(&amp;|$)/g,status,data,type=s.type.toUpperCase();if(s.data&amp;&amp;s.processData&amp;&amp;typeof s.data!=&quot;string&quot;){s.data=jQuery.param(s.data)}if(s.dataType==&quot;jsonp&quot;){if(type==&quot;GET&quot;){if(!s.url.match(jsre)){s.url+=(s.url.match(/\?/)?&quot;&amp;&quot;:&quot;?&quot;)+(s.jsonp||&quot;callback&quot;)+&quot;=?&quot;}}else{if(!s.data||!s.data.match(jsre)){s.data=(s.data?s.data+&quot;&amp;&quot;:&quot;&quot;)+(s.jsonp||&quot;callback&quot;)+&quot;=?&quot;}}s.dataType=&quot;json&quot;}if(s.dataType==&quot;json&quot;&amp;&amp;(s.data&amp;&amp;s.data.match(jsre)||s.url.match(jsre))){jsonp=&quot;jsonp&quot;+jsc++;if(s.data){s.data=(s.data+&quot;&quot;).replace(jsre,&quot;=&quot;+jsonp+&quot;$1&quot;)}s.url=s.url.replace(jsre,&quot;=&quot;+jsonp+&quot;$1&quot;);s.dataType=&quot;script&quot;;window[jsonp]=function(tmp){data=tmp;success();complete();window[jsonp]=undefined;try{delete window[jsonp]}catch(e){}if(head){head.removeChild(script)}}}if(s.dataType==&quot;script&quot;&amp;&amp;s.cache==null){s.cache=false}if(s.cache===false&amp;&amp;type==&quot;GET&quot;){var ts=now();var ret=s.url.replace(/(\?|&amp;)_=.*?(&amp;|$)/,&quot;$1_=&quot;+ts+&quot;$2&quot;);s.url=ret+((ret==s.url)?(s.url.match(/\?/)?&quot;&amp;&quot;:&quot;?&quot;)+&quot;_=&quot;+ts:&quot;&quot;)}if(s.data&amp;&amp;type==&quot;GET&quot;){s.url+=(s.url.match(/\?/)?&quot;&amp;&quot;:&quot;?&quot;)+s.data;s.data=null}if(s.global&amp;&amp;!jQuery.active++){jQuery.event.trigger(&quot;ajaxStart&quot;)}var remote=/^(?:\w+:)?\/\/([^\/?#]+)/;if(s.dataType==&quot;script&quot;&amp;&amp;type==&quot;GET&quot;&amp;&amp;remote.test(s.url)&amp;&amp;remote.exec(s.url)[1]!=location.host){var head=document.getElementsByTagName(&quot;head&quot;)[0];var script=document.createElement(&quot;script&quot;);script.src=s.url;if(s.scriptCharset){script.charset=s.scriptCharset}if(!jsonp){var done=false;script.onload=script.onreadystatechange=function(){if(!done&amp;&amp;(!this.readyState||this.readyState==&quot;loaded&quot;||this.readyState==&quot;complete&quot;)){done=true;success();complete();head.removeChild(script)}}}head.appendChild(script);return undefined}var requestDone=false;var xhr=window.ActiveXObject?new ActiveXObject(&quot;Microsoft.XMLHTTP&quot;):new XMLHttpRequest();if(s.username){xhr.open(type,s.url,s.async,s.username,s.password)}else{xhr.open(type,s.url,s.async)}try{if(s.data){xhr.setRequestHeader(&quot;Content-Type&quot;,s.contentType)}if(s.ifModified){xhr.setRequestHeader(&quot;If-Modified-Since&quot;,jQuery.lastModified[s.url]||&quot;Thu, 01 Jan 1970 00:00:00 GMT&quot;)}xhr.setRequestHeader(&quot;X-Requested-With&quot;,&quot;XMLHttpRequest&quot;);xhr.setRequestHeader(&quot;Accept&quot;,s.dataType&amp;&amp;s.accepts[s.dataType]?s.accepts[s.dataType]+&quot;, */*&quot;:s.accepts._default)}catch(e){}if(s.beforeSend&amp;&amp;s.beforeSend(xhr,s)===false){s.global&amp;&amp;jQuery.active--;xhr.abort();return false}if(s.global){jQuery.event.trigger(&quot;ajaxSend&quot;,[xhr,s])}var onreadystatechange=function(isTimeout){if(!requestDone&amp;&amp;xhr&amp;&amp;(xhr.readyState==4||isTimeout==&quot;timeout&quot;)){requestDone=true;if(ival){clearInterval(ival);ival=null}status=isTimeout==&quot;timeout&quot;&amp;&amp;&quot;timeout&quot;||!jQuery.httpSuccess(xhr)&amp;&amp;&quot;error&quot;||s.ifModified&amp;&amp;jQuery.httpNotModified(xhr,s.url)&amp;&amp;&quot;notmodified&quot;||&quot;success&quot;;if(status==&quot;success&quot;){try{data=jQuery.httpData(xhr,s.dataType,s.dataFilter)}catch(e){status=&quot;parsererror&quot;}}if(status==&quot;success&quot;){var modRes;try{modRes=xhr.getResponseHeader(&quot;Last-Modified&quot;)}catch(e){}if(s.ifModified&amp;&amp;modRes){jQuery.lastModified[s.url]=modRes}if(!jsonp){success()}}else{jQuery.handleError(s,xhr,status)}complete();if(s.async){xhr=null}}};if(s.async){var ival=setInterval(onreadystatechange,13);if(s.timeout&gt;0){setTimeout(function(){if(xhr){xhr.abort();if(!requestDone){onreadystatechange(&quot;timeout&quot;)}}},s.timeout)}}try{xhr.send(s.data)}catch(e){jQuery.handleError(s,xhr,null,e)}if(!s.async){onreadystatechange()}function success(){if(s.success){s.success(data,status)}if(s.global){jQuery.event.trigger(&quot;ajaxSuccess&quot;,[xhr,s])}}function complete(){if(s.complete){s.complete(xhr,status)}if(s.global){jQuery.event.trigger(&quot;ajaxComplete&quot;,[xhr,s])}if(s.global&amp;&amp;!--jQuery.active){jQuery.event.trigger(&quot;ajaxStop&quot;)}}return xhr},handleError:function(s,xhr,status,e){if(s.error){s.error(xhr,status,e)}if(s.global){jQuery.event.trigger(&quot;ajaxError&quot;,[xhr,s,e])}},active:0,httpSuccess:function(xhr){try{return !xhr.status&amp;&amp;location.protocol==&quot;file:&quot;||(xhr.status&gt;=200&amp;&amp;xhr.status&lt;300)||xhr.status==304||xhr.status==1223||jQuery.browser.safari&amp;&amp;xhr.status==undefined}catch(e){}return false},httpNotModified:function(xhr,url){try{var xhrRes=xhr.getResponseHeader(&quot;Last-Modified&quot;);return xhr.status==304||xhrRes==jQuery.lastModified[url]||jQuery.browser.safari&amp;&amp;xhr.status==undefined}catch(e){}return false},httpData:function(xhr,type,filter){var ct=xhr.getResponseHeader(&quot;content-type&quot;),xml=type==&quot;xml&quot;||!type&amp;&amp;ct&amp;&amp;ct.indexOf(&quot;xml&quot;)&gt;=0,data=xml?xhr.responseXML:xhr.responseText;if(xml&amp;&amp;data.documentElement.tagName==&quot;parsererror&quot;){throw&quot;parsererror&quot;}if(filter){data=filter(data,type)}if(type==&quot;script&quot;){jQuery.globalEval(data)}if(type==&quot;json&quot;){data=eval(&quot;(&quot;+data+&quot;)&quot;)}return data},param:function(a){var s=[];if(a.constructor==Array||a.jquery){jQuery.each(a,function(){s.push(encodeURIComponent(this.name)+&quot;=&quot;+encodeURIComponent(this.value))})}else{for(var j in a){if(a[j]&amp;&amp;a[j].constructor==Array){jQuery.each(a[j],function(){s.push(encodeURIComponent(j)+&quot;=&quot;+encodeURIComponent(this))})}else{s.push(encodeURIComponent(j)+&quot;=&quot;+encodeURIComponent(jQuery.isFunction(a[j])?a[j]():a[j]))}}}return s.join(&quot;&amp;&quot;).replace(/%20/g,&quot;+&quot;)}});jQuery.fn.extend({show:function(speed,callback){return speed?this.animate({height:&quot;show&quot;,width:&quot;show&quot;,opacity:&quot;show&quot;},speed,callback):this.filter(&quot;:hidden&quot;).each(function(){this.style.display=this.oldblock||&quot;&quot;;if(jQuery.css(this,&quot;display&quot;)==&quot;none&quot;){var elem=jQuery(&quot;&lt;&quot;+this.tagName+&quot; /&gt;&quot;).appendTo(&quot;body&quot;);this.style.display=elem.css(&quot;display&quot;);if(this.style.display==&quot;none&quot;){this.style.display=&quot;block&quot;}elem.remove()}}).end()},hide:function(speed,callback){return speed?this.animate({height:&quot;hide&quot;,width:&quot;hide&quot;,opacity:&quot;hide&quot;},speed,callback):this.filter(&quot;:visible&quot;).each(function(){this.oldblock=this.oldblock||jQuery.css(this,&quot;display&quot;);this.style.display=&quot;none&quot;}).end()},_toggle:jQuery.fn.toggle,toggle:function(fn,fn2){return jQuery.isFunction(fn)&amp;&amp;jQuery.isFunction(fn2)?this._toggle.apply(this,arguments):fn?this.animate({height:&quot;toggle&quot;,width:&quot;toggle&quot;,opacity:&quot;toggle&quot;},fn,fn2):this.each(function(){jQuery(this)[jQuery(this).is(&quot;:hidden&quot;)?&quot;show&quot;:&quot;hide&quot;]()})},slideDown:function(speed,callback){return this.animate({height:&quot;show&quot;},speed,callback)},slideUp:function(speed,callback){return this.animate({height:&quot;hide&quot;},speed,callback)},slideToggle:function(speed,callback){return this.animate({height:&quot;toggle&quot;},speed,callback)},fadeIn:function(speed,callback){return this.animate({opacity:&quot;show&quot;},speed,callback)},fadeOut:function(speed,callback){return this.animate({opacity:&quot;hide&quot;},speed,callback)},fadeTo:function(speed,to,callback){return this.animate({opacity:to},speed,callback)},animate:function(prop,speed,easing,callback){var optall=jQuery.speed(speed,easing,callback);return this[optall.queue===false?&quot;each&quot;:&quot;queue&quot;](function(){if(this.nodeType!=1){return false}var opt=jQuery.extend({},optall),p,hidden=jQuery(this).is(&quot;:hidden&quot;),self=this;for(p in prop){if(prop[p]==&quot;hide&quot;&amp;&amp;hidden||prop[p]==&quot;show&quot;&amp;&amp;!hidden){return opt.complete.call(this)}if(p==&quot;height&quot;||p==&quot;width&quot;){opt.display=jQuery.css(this,&quot;display&quot;);opt.overflow=this.style.overflow}}if(opt.overflow!=null){this.style.overflow=&quot;hidden&quot;}opt.curAnim=jQuery.extend({},prop);jQuery.each(prop,function(name,val){var e=new jQuery.fx(self,opt,name);if(/toggle|show|hide/.test(val)){e[val==&quot;toggle&quot;?hidden?&quot;show&quot;:&quot;hide&quot;:val](prop)}else{var parts=val.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),start=e.cur(true)||0;if(parts){var end=parseFloat(parts[2]),unit=parts[3]||&quot;px&quot;;if(unit!=&quot;px&quot;){self.style[name]=(end||1)+unit;start=((end||1)/e.cur(true))*start;self.style[name]=start+unit}if(parts[1]){end=((parts[1]==&quot;-=&quot;?-1:1)*end)+start}e.custom(start,end,unit)}else{e.custom(start,val,&quot;&quot;)}}});return true})},queue:function(type,fn){if(jQuery.isFunction(type)||(type&amp;&amp;type.constructor==Array)){fn=type;type=&quot;fx&quot;}if(!type||(typeof type==&quot;string&quot;&amp;&amp;!fn)){return queue(this[0],type)}return this.each(function(){if(fn.constructor==Array){queue(this,type,fn)}else{queue(this,type).push(fn);if(queue(this,type).length==1){fn.call(this)}}})},stop:function(clearQueue,gotoEnd){var timers=jQuery.timers;if(clearQueue){this.queue([])}this.each(function(){for(var i=timers.length-1;i&gt;=0;i--){if(timers[i].elem==this){if(gotoEnd){timers[i](true)}timers.splice(i,1)}}});if(!gotoEnd){this.dequeue()}return this}});var queue=function(elem,type,array){if(elem){type=type||&quot;fx&quot;;var q=jQuery.data(elem,type+&quot;queue&quot;);if(!q||array){q=jQuery.data(elem,type+&quot;queue&quot;,jQuery.makeArray(array))}}return q};jQuery.fn.dequeue=function(type){type=type||&quot;fx&quot;;return this.each(function(){var q=queue(this,type);q.shift();if(q.length){q[0].call(this)}})};jQuery.extend({speed:function(speed,easing,fn){var opt=speed&amp;&amp;speed.constructor==Object?speed:{complete:fn||!fn&amp;&amp;easing||jQuery.isFunction(speed)&amp;&amp;speed,duration:speed,easing:fn&amp;&amp;easing||easing&amp;&amp;easing.constructor!=Function&amp;&amp;easing};opt.duration=(opt.duration&amp;&amp;opt.duration.constructor==Number?opt.duration:jQuery.fx.speeds[opt.duration])||jQuery.fx.speeds.def;opt.old=opt.complete;opt.complete=function(){if(opt.queue!==false){jQuery(this).dequeue()}if(jQuery.isFunction(opt.old)){opt.old.call(this)}};return opt},easing:{linear:function(p,n,firstNum,diff){return firstNum+diff*p},swing:function(p,n,firstNum,diff){return((-Math.cos(p*Math.PI)/2)+0.5)*diff+firstNum}},timers:[],timerId:null,fx:function(elem,options,prop){this.options=options;this.elem=elem;this.prop=prop;if(!options.orig){options.orig={}}}});jQuery.fx.prototype={update:function(){if(this.options.step){this.options.step.call(this.elem,this.now,this)}(jQuery.fx.step[this.prop]||jQuery.fx.step._default)(this);if(this.prop==&quot;height&quot;||this.prop==&quot;width&quot;){this.elem.style.display=&quot;block&quot;}},cur:function(force){if(this.elem[this.prop]!=null&amp;&amp;this.elem.style[this.prop]==null){return this.elem[this.prop]}var r=parseFloat(jQuery.css(this.elem,this.prop,force));return r&amp;&amp;r&gt;-10000?r:parseFloat(jQuery.curCSS(this.elem,this.prop))||0},custom:function(from,to,unit){this.startTime=now();this.start=from;this.end=to;this.unit=unit||this.unit||&quot;px&quot;;this.now=this.start;this.pos=this.state=0;this.update();var self=this;function t(gotoEnd){return self.step(gotoEnd)}t.elem=this.elem;jQuery.timers.push(t);if(jQuery.timerId==null){jQuery.timerId=setInterval(function(){var timers=jQuery.timers;for(var i=0;i&lt;timers.length;i++){if(!timers[i]()){timers.splice(i--,1)}}if(!timers.length){clearInterval(jQuery.timerId);jQuery.timerId=null}},13)}},show:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.show=true;this.custom(0,this.cur());if(this.prop==&quot;width&quot;||this.prop==&quot;height&quot;){this.elem.style[this.prop]=&quot;1px&quot;}jQuery(this.elem).show()},hide:function(){this.options.orig[this.prop]=jQuery.attr(this.elem.style,this.prop);this.options.hide=true;this.custom(this.cur(),0)},step:function(gotoEnd){var t=now();if(gotoEnd||t&gt;this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var done=true;for(var i in this.options.curAnim){if(this.options.curAnim[i]!==true){done=false}}if(done){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(jQuery.css(this.elem,&quot;display&quot;)==&quot;none&quot;){this.elem.style.display=&quot;block&quot;}}if(this.options.hide){this.elem.style.display=&quot;none&quot;}if(this.options.hide||this.options.show){for(var p in this.options.curAnim){jQuery.attr(this.elem.style,p,this.options.orig[p])}}}if(done){this.options.complete.call(this.elem)}return false}else{var n=t-this.startTime;this.state=n/this.options.duration;this.pos=jQuery.easing[this.options.easing||(jQuery.easing.swing?&quot;swing&quot;:&quot;linear&quot;)](this.state,n,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update()}return true}};jQuery.extend(jQuery.fx,{speeds:{slow:600,fast:200,def:400},step:{scrollLeft:function(fx){fx.elem.scrollLeft=fx.now},scrollTop:function(fx){fx.elem.scrollTop=fx.now},opacity:function(fx){jQuery.attr(fx.elem.style,&quot;opacity&quot;,fx.now)},_default:function(fx){fx.elem.style[fx.prop]=fx.now+fx.unit}}});jQuery.fn.offset=function(){var left=0,top=0,elem=this[0],results;if(elem){with(jQuery.browser){var parent=elem.parentNode,offsetChild=elem,offsetParent=elem.offsetParent,doc=elem.ownerDocument,safari2=safari&amp;&amp;parseInt(version)&lt;522&amp;&amp;!/adobeair/i.test(userAgent),css=jQuery.curCSS,fixed=css(elem,&quot;position&quot;)==&quot;fixed&quot;;if(elem.getBoundingClientRect){var box=elem.getBoundingClientRect();add(box.left+Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),box.top+Math.max(doc.documentElement.scrollTop,doc.body.scrollTop));add(-doc.documentElement.clientLeft,-doc.documentElement.clientTop)}else{add(elem.offsetLeft,elem.offsetTop);while(offsetParent){add(offsetParent.offsetLeft,offsetParent.offsetTop);if(mozilla&amp;&amp;!/^t(able|d|h)$/i.test(offsetParent.tagName)||safari&amp;&amp;!safari2){border(offsetParent)}if(!fixed&amp;&amp;css(offsetParent,&quot;position&quot;)==&quot;fixed&quot;){fixed=true}offsetChild=/^body$/i.test(offsetParent.tagName)?offsetChild:offsetParent;offsetParent=offsetParent.offsetParent}while(parent&amp;&amp;parent.tagName&amp;&amp;!/^body|html$/i.test(parent.tagName)){if(!/^inline|table.*$/i.test(css(parent,&quot;display&quot;))){add(-parent.scrollLeft,-parent.scrollTop)}if(mozilla&amp;&amp;css(parent,&quot;overflow&quot;)!=&quot;visible&quot;){border(parent)}parent=parent.parentNode}if((safari2&amp;&amp;(fixed||css(offsetChild,&quot;position&quot;)==&quot;absolute&quot;))||(mozilla&amp;&amp;css(offsetChild,&quot;position&quot;)!=&quot;absolute&quot;)){add(-doc.body.offsetLeft,-doc.body.offsetTop)}if(fixed){add(Math.max(doc.documentElement.scrollLeft,doc.body.scrollLeft),Math.max(doc.documentElement.scrollTop,doc.body.scrollTop))}}results={top:top,left:left}}}function border(elem){add(jQuery.curCSS(elem,&quot;borderLeftWidth&quot;,true),jQuery.curCSS(elem,&quot;borderTopWidth&quot;,true))}function add(l,t){left+=parseInt(l,10)||0;top+=parseInt(t,10)||0}return results};jQuery.fn.extend({position:function(){var left=0,top=0,results;if(this[0]){var offsetParent=this.offsetParent(),offset=this.offset(),parentOffset=/^body|html$/i.test(offsetParent[0].tagName)?{top:0,left:0}:offsetParent.offset();offset.top-=num(this,&quot;marginTop&quot;);offset.left-=num(this,&quot;marginLeft&quot;);parentOffset.top+=num(offsetParent,&quot;borderTopWidth&quot;);parentOffset.left+=num(offsetParent,&quot;borderLeftWidth&quot;);results={top:offset.top-parentOffset.top,left:offset.left-parentOffset.left}}return results},offsetParent:function(){var offsetParent=this[0].offsetParent;while(offsetParent&amp;&amp;(!/^body|html$/i.test(offsetParent.tagName)&amp;&amp;jQuery.css(offsetParent,&quot;position&quot;)==&quot;static&quot;)){offsetParent=offsetParent.offsetParent}return jQuery(offsetParent)}});jQuery.each([&quot;Left&quot;,&quot;Top&quot;],function(i,name){var method=&quot;scroll&quot;+name;jQuery.fn[method]=function(val){if(!this[0]){return}return val!=undefined?this.each(function(){this==window||this==document?window.scrollTo(!i?val:jQuery(window).scrollLeft(),i?val:jQuery(window).scrollTop()):this[method]=val}):this[0]==window||this[0]==document?self[i?&quot;pageYOffset&quot;:&quot;pageXOffset&quot;]||jQuery.boxModel&amp;&amp;document.documentElement[method]||document.body[method]:this[0][method]}});jQuery.each([&quot;Height&quot;,&quot;Width&quot;],function(i,name){var tl=i?&quot;Left&quot;:&quot;Top&quot;,br=i?&quot;Right&quot;:&quot;Bottom&quot;;jQuery.fn[&quot;inner&quot;+name]=function(){return this[name.toLowerCase()]()+num(this,&quot;padding&quot;+tl)+num(this,&quot;padding&quot;+br)};jQuery.fn[&quot;outer&quot;+name]=function(margin){return this[&quot;inner&quot;+name]()+num(this,&quot;border&quot;+tl+&quot;Width&quot;)+num(this,&quot;border&quot;+br+&quot;Width&quot;)+(margin?num(this,&quot;margin&quot;+tl)+num(this,&quot;margin&quot;+br):0)}})})();
\ No newline at end of file</diff>
      <filename>test/data/javascripts/jquery-1.2.6.js</filename>
    </modified>
    <modified>
      <diff>@@ -1,4221 +1 @@
-/*  Prototype JavaScript framework, version 1.6.0.2
- *  (c) 2005-2008 Sam Stephenson
- *
- *  Prototype is freely distributable under the terms of an MIT-style license.
- *  For details, see the Prototype web site: http://www.prototypejs.org/
- *
- *--------------------------------------------------------------------------*/
-
-var Prototype = {
-  Version: '1.6.0.2',
-
-  Browser: {
-    IE:     !!(window.attachEvent &amp;&amp; !window.opera),
-    Opera:  !!window.opera,
-    WebKit: navigator.userAgent.indexOf('AppleWebKit/') &gt; -1,
-    Gecko:  navigator.userAgent.indexOf('Gecko') &gt; -1 &amp;&amp; navigator.userAgent.indexOf('KHTML') == -1,
-    MobileSafari: !!navigator.userAgent.match(/Apple.*Mobile.*Safari/)
-  },
-
-  BrowserFeatures: {
-    XPath: !!document.evaluate,
-    ElementExtensions: !!window.HTMLElement,
-    SpecificElementExtensions:
-      document.createElement('div').__proto__ &amp;&amp;
-      document.createElement('div').__proto__ !==
-        document.createElement('form').__proto__
-  },
-
-  ScriptFragment: '&lt;script[^&gt;]*&gt;([\\S\\s]*?)&lt;\/script&gt;',
-  JSONFilter: /^\/\*-secure-([\s\S]*)\*\/\s*$/,
-
-  emptyFunction: function() { },
-  K: function(x) { return x }
-};
-
-if (Prototype.Browser.MobileSafari)
-  Prototype.BrowserFeatures.SpecificElementExtensions = false;
-
-
-/* Based on Alex Arnell's inheritance implementation. */
-var Class = {
-  create: function() {
-    var parent = null, properties = $A(arguments);
-    if (Object.isFunction(properties[0]))
-      parent = properties.shift();
-
-    function klass() {
-      this.initialize.apply(this, arguments);
-    }
-
-    Object.extend(klass, Class.Methods);
-    klass.superclass = parent;
-    klass.subclasses = [];
-
-    if (parent) {
-      var subclass = function() { };
-      subclass.prototype = parent.prototype;
-      klass.prototype = new subclass;
-      parent.subclasses.push(klass);
-    }
-
-    for (var i = 0; i &lt; properties.length; i++)
-      klass.addMethods(properties[i]);
-
-    if (!klass.prototype.initialize)
-      klass.prototype.initialize = Prototype.emptyFunction;
-
-    klass.prototype.constructor = klass;
-
-    return klass;
-  }
-};
-
-Class.Methods = {
-  addMethods: function(source) {
-    var ancestor   = this.superclass &amp;&amp; this.superclass.prototype;
-    var properties = Object.keys(source);
-
-    if (!Object.keys({ toString: true }).length)
-      properties.push(&quot;toString&quot;, &quot;valueOf&quot;);
-
-    for (var i = 0, length = properties.length; i &lt; length; i++) {
-      var property = properties[i], value = source[property];
-      if (ancestor &amp;&amp; Object.isFunction(value) &amp;&amp;
-          value.argumentNames().first() == &quot;$super&quot;) {
-        var method = value, value = Object.extend((function(m) {
-          return function() { return ancestor[m].apply(this, arguments) };
-        })(property).wrap(method), {
-          valueOf:  function() { return method },
-          toString: function() { return method.toString() }
-        });
-      }
-      this.prototype[property] = value;
-    }
-
-    return this;
-  }
-};
-
-var Abstract = { };
-
-Object.extend = function(destination, source) {
-  for (var property in source)
-    destination[property] = source[property];
-  return destination;
-};
-
-Object.extend(Object, {
-  inspect: function(object) {
-    try {
-      if (Object.isUndefined(object)) return 'undefined';
-      if (object === null) return 'null';
-      return object.inspect ? object.inspect() : String(object);
-    } catch (e) {
-      if (e instanceof RangeError) return '...';
-      throw e;
-    }
-  },
-
-  toJSON: function(object) {
-    var type = typeof object;
-    switch (type) {
-      case 'undefined':
-      case 'function':
-      case 'unknown': return;
-      case 'boolean': return object.toString();
-    }
-
-    if (object === null) return 'null';
-    if (object.toJSON) return object.toJSON();
-    if (Object.isElement(object)) return;
-
-    var results = [];
-    for (var property in object) {
-      var value = Object.toJSON(object[property]);
-      if (!Object.isUndefined(value))
-        results.push(property.toJSON() + ': ' + value);
-    }
-
-    return '{' + results.join(', ') + '}';
-  },
-
-  toQueryString: function(object) {
-    return $H(object).toQueryString();
-  },
-
-  toHTML: function(object) {
-    return object &amp;&amp; object.toHTML ? object.toHTML() : String.interpret(object);
-  },
-
-  keys: function(object) {
-    var keys = [];
-    for (var property in object)
-      keys.push(property);
-    return keys;
-  },
-
-  values: function(object) {
-    var values = [];
-    for (var property in object)
-      values.push(object[property]);
-    return values;
-  },
-
-  clone: function(object) {
-    return Object.extend({ }, object);
-  },
-
-  isElement: function(object) {
-    return object &amp;&amp; object.nodeType == 1;
-  },
-
-  isArray: function(object) {
-    return object != null &amp;&amp; typeof object == &quot;object&quot; &amp;&amp;
-      'splice' in object &amp;&amp; 'join' in object;
-  },
-
-  isHash: function(object) {
-    return object instanceof Hash;
-  },
-
-  isFunction: function(object) {
-    return typeof object == &quot;function&quot;;
-  },
-
-  isString: function(object) {
-    return typeof object == &quot;string&quot;;
-  },
-
-  isNumber: function(object) {
-    return typeof object == &quot;number&quot;;
-  },
-
-  isUndefined: function(object) {
-    return typeof object == &quot;undefined&quot;;
-  }
-});
-
-Object.extend(Function.prototype, {
-  argumentNames: function() {
-    var names = this.toString().match(/^[\s\(]*function[^(]*\((.*?)\)/)[1].split(&quot;,&quot;).invoke(&quot;strip&quot;);
-    return names.length == 1 &amp;&amp; !names[0] ? [] : names;
-  },
-
-  bind: function() {
-    if (arguments.length &lt; 2 &amp;&amp; Object.isUndefined(arguments[0])) return this;
-    var __method = this, args = $A(arguments), object = args.shift();
-    return function() {
-      return __method.apply(object, args.concat($A(arguments)));
-    }
-  },
-
-  bindAsEventListener: function() {
-    var __method = this, args = $A(arguments), object = args.shift();
-    return function(event) {
-      return __method.apply(object, [event || window.event].concat(args));
-    }
-  },
-
-  curry: function() {
-    if (!arguments.length) return this;
-    var __method = this, args = $A(arguments);
-    return function() {
-      return __method.apply(this, args.concat($A(arguments)));
-    }
-  },
-
-  delay: function() {
-    var __method = this, args = $A(arguments), timeout = args.shift() * 1000;
-    return window.setTimeout(function() {
-      return __method.apply(__method, args);
-    }, timeout);
-  },
-
-  wrap: function(wrapper) {
-    var __method = this;
-    return function() {
-      return wrapper.apply(this, [__method.bind(this)].concat($A(arguments)));
-    }
-  },
-
-  methodize: function() {
-    if (this._methodized) return this._methodized;
-    var __method = this;
-    return this._methodized = function() {
-      return __method.apply(null, [this].concat($A(arguments)));
-    };
-  }
-});
-
-Function.prototype.defer = Function.prototype.delay.curry(0.01);
-
-Date.prototype.toJSON = function() {
-  return '&quot;' + this.getUTCFullYear() + '-' +
-    (this.getUTCMonth() + 1).toPaddedString(2) + '-' +
-    this.getUTCDate().toPaddedString(2) + 'T' +
-    this.getUTCHours().toPaddedString(2) + ':' +
-    this.getUTCMinutes().toPaddedString(2) + ':' +
-    this.getUTCSeconds().toPaddedString(2) + 'Z&quot;';
-};
-
-var Try = {
-  these: function() {
-    var returnValue;
-
-    for (var i = 0, length = arguments.length; i &lt; length; i++) {
-      var lambda = arguments[i];
-      try {
-        returnValue = lambda();
-        break;
-      } catch (e) { }
-    }
-
-    return returnValue;
-  }
-};
-
-RegExp.prototype.match = RegExp.prototype.test;
-
-RegExp.escape = function(str) {
-  return String(str).replace(/([.*+?^=!:${}()|[\]\/\\])/g, '\\$1');
-};
-
-/*--------------------------------------------------------------------------*/
-
-var PeriodicalExecuter = Class.create({
-  initialize: function(callback, frequency) {
-    this.callback = callback;
-    this.frequency = frequency;
-    this.currentlyExecuting = false;
-
-    this.registerCallback();
-  },
-
-  registerCallback: function() {
-    this.timer = setInterval(this.onTimerEvent.bind(this), this.frequency * 1000);
-  },
-
-  execute: function() {
-    this.callback(this);
-  },
-
-  stop: function() {
-    if (!this.timer) return;
-    clearInterval(this.timer);
-    this.timer = null;
-  },
-
-  onTimerEvent: function() {
-    if (!this.currentlyExecuting) {
-      try {
-        this.currentlyExecuting = true;
-        this.execute();
-      } finally {
-        this.currentlyExecuting = false;
-      }
-    }
-  }
-});
-Object.extend(String, {
-  interpret: function(value) {
-    return value == null ? '' : String(value);
-  },
-  specialChar: {
-    '\b': '\\b',
-    '\t': '\\t',
-    '\n': '\\n',
-    '\f': '\\f',
-    '\r': '\\r',
-    '\\': '\\\\'
-  }
-});
-
-Object.extend(String.prototype, {
-  gsub: function(pattern, replacement) {
-    var result = '', source = this, match;
-    replacement = arguments.callee.prepareReplacement(replacement);
-
-    while (source.length &gt; 0) {
-      if (match = source.match(pattern)) {
-        result += source.slice(0, match.index);
-        result += String.interpret(replacement(match));
-        source  = source.slice(match.index + match[0].length);
-      } else {
-        result += source, source = '';
-      }
-    }
-    return result;
-  },
-
-  sub: function(pattern, replacement, count) {
-    replacement = this.gsub.prepareReplacement(replacement);
-    count = Object.isUndefined(count) ? 1 : count;
-
-    return this.gsub(pattern, function(match) {
-      if (--count &lt; 0) return match[0];
-      return replacement(match);
-    });
-  },
-
-  scan: function(pattern, iterator) {
-    this.gsub(pattern, iterator);
-    return String(this);
-  },
-
-  truncate: function(length, truncation) {
-    length = length || 30;
-    truncation = Object.isUndefined(truncation) ? '...' : truncation;
-    return this.length &gt; length ?
-      this.slice(0, length - truncation.length) + truncation : String(this);
-  },
-
-  strip: function() {
-    return this.replace(/^\s+/, '').replace(/\s+$/, '');
-  },
-
-  stripTags: function() {
-    return this.replace(/&lt;\/?[^&gt;]+&gt;/gi, '');
-  },
-
-  stripScripts: function() {
-    return this.replace(new RegExp(Prototype.ScriptFragment, 'img'), '');
-  },
-
-  extractScripts: function() {
-    var matchAll = new RegExp(Prototype.ScriptFragment, 'img');
-    var matchOne = new RegExp(Prototype.ScriptFragment, 'im');
-    return (this.match(matchAll) || []).map(function(scriptTag) {
-      return (scriptTag.match(matchOne) || ['', ''])[1];
-    });
-  },
-
-  evalScripts: function() {
-    return this.extractScripts().map(function(script) { return eval(script) });
-  },
-
-  escapeHTML: function() {
-    var self = arguments.callee;
-    self.text.data = this;
-    return self.div.innerHTML;
-  },
-
-  unescapeHTML: function() {
-    var div = new Element('div');
-    div.innerHTML = this.stripTags();
-    return div.childNodes[0] ? (div.childNodes.length &gt; 1 ?
-      $A(div.childNodes).inject('', function(memo, node) { return memo+node.nodeValue }) :
-      div.childNodes[0].nodeValue) : '';
-  },
-
-  toQueryParams: function(separator) {
-    var match = this.strip().match(/([^?#]*)(#.*)?$/);
-    if (!match) return { };
-
-    return match[1].split(separator || '&amp;').inject({ }, function(hash, pair) {
-      if ((pair = pair.split('='))[0]) {
-        var key = decodeURIComponent(pair.shift());
-        var value = pair.length &gt; 1 ? pair.join('=') : pair[0];
-        if (value != undefined) value = decodeURIComponent(value);
-
-        if (key in hash) {
-          if (!Object.isArray(hash[key])) hash[key] = [hash[key]];
-          hash[key].push(value);
-        }
-        else hash[key] = value;
-      }
-      return hash;
-    });
-  },
-
-  toArray: function() {
-    return this.split('');
-  },
-
-  succ: function() {
-    return this.slice(0, this.length - 1) +
-      String.fromCharCode(this.charCodeAt(this.length - 1) + 1);
-  },
-
-  times: function(count) {
-    return count &lt; 1 ? '' : new Array(count + 1).join(this);
-  },
-
-  camelize: function() {
-    var parts = this.split('-'), len = parts.length;
-    if (len == 1) return parts[0];
-
-    var camelized = this.charAt(0) == '-'
-      ? parts[0].charAt(0).toUpperCase() + parts[0].substring(1)
-      : parts[0];
-
-    for (var i = 1; i &lt; len; i++)
-      camelized += parts[i].charAt(0).toUpperCase() + parts[i].substring(1);
-
-    return camelized;
-  },
-
-  capitalize: function() {
-    return this.charAt(0).toUpperCase() + this.substring(1).toLowerCase();
-  },
-
-  underscore: function() {
-    return this.gsub(/::/, '/').gsub(/([A-Z]+)([A-Z][a-z])/,'#{1}_#{2}').gsub(/([a-z\d])([A-Z])/,'#{1}_#{2}').gsub(/-/,'_').toLowerCase();
-  },
-
-  dasherize: function() {
-    return this.gsub(/_/,'-');
-  },
-
-  inspect: function(useDoubleQuotes) {
-    var escapedString = this.gsub(/[\x00-\x1f\\]/, function(match) {
-      var character = String.specialChar[match[0]];
-      return character ? character : '\\u00' + match[0].charCodeAt().toPaddedString(2, 16);
-    });
-    if (useDoubleQuotes) return '&quot;' + escapedString.replace(/&quot;/g, '\\&quot;') + '&quot;';
-    return &quot;'&quot; + escapedString.replace(/'/g, '\\\'') + &quot;'&quot;;
-  },
-
-  toJSON: function() {
-    return this.inspect(true);
-  },
-
-  unfilterJSON: function(filter) {
-    return this.sub(filter || Prototype.JSONFilter, '#{1}');
-  },
-
-  isJSON: function() {
-    var str = this;
-    if (str.blank()) return false;
-    str = this.replace(/\\./g, '@').replace(/&quot;[^&quot;\\\n\r]*&quot;/g, '');
-    return (/^[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]*$/).test(str);
-  },
-
-  evalJSON: function(sanitize) {
-    var json = this.unfilterJSON();
-    try {
-      if (!sanitize || json.isJSON()) return eval('(' + json + ')');
-    } catch (e) { }
-    throw new SyntaxError('Badly formed JSON string: ' + this.inspect());
-  },
-
-  include: function(pattern) {
-    return this.indexOf(pattern) &gt; -1;
-  },
-
-  startsWith: function(pattern) {
-    return this.indexOf(pattern) === 0;
-  },
-
-  endsWith: function(pattern) {
-    var d = this.length - pattern.length;
-    return d &gt;= 0 &amp;&amp; this.lastIndexOf(pattern) === d;
-  },
-
-  empty: function() {
-    return this == '';
-  },
-
-  blank: function() {
-    return /^\s*$/.test(this);
-  },
-
-  interpolate: function(object, pattern) {
-    return new Template(this, pattern).evaluate(object);
-  }
-});
-
-if (Prototype.Browser.WebKit || Prototype.Browser.IE) Object.extend(String.prototype, {
-  escapeHTML: function() {
-    return this.replace(/&amp;/g,'&amp;amp;').replace(/&lt;/g,'&amp;lt;').replace(/&gt;/g,'&amp;gt;');
-  },
-  unescapeHTML: function() {
-    return this.replace(/&amp;amp;/g,'&amp;').replace(/&amp;lt;/g,'&lt;').replace(/&amp;gt;/g,'&gt;');
-  }
-});
-
-String.prototype.gsub.prepareReplacement = function(replacement) {
-  if (Object.isFunction(replacement)) return replacement;
-  var template = new Template(replacement);
-  return function(match) { return template.evaluate(match) };
-};
-
-String.prototype.parseQuery = String.prototype.toQueryParams;
-
-Object.extend(String.prototype.escapeHTML, {
-  div:  document.createElement('div'),
-  text: document.createTextNode('')
-});
-
-with (String.prototype.escapeHTML) div.appendChild(text);
-
-var Template = Class.create({
-  initialize: function(template, pattern) {
-    this.template = template.toString();
-    this.pattern = pattern || Template.Pattern;
-  },
-
-  evaluate: function(object) {
-    if (Object.isFunction(object.toTemplateReplacements))
-      object = object.toTemplateReplacements();
-
-    return this.template.gsub(this.pattern, function(match) {
-      if (object == null) return '';
-
-      var before = match[1] || '';
-      if (before == '\\') return match[2];
-
-      var ctx = object, expr = match[3];
-      var pattern = /^([^.[]+|\[((?:.*?[^\\])?)\])(\.|\[|$)/;
-      match = pattern.exec(expr);
-      if (match == null) return before;
-
-      while (match != null) {
-        var comp = match[1].startsWith('[') ? match[2].gsub('\\\\]', ']') : match[1];
-        ctx = ctx[comp];
-        if (null == ctx || '' == match[3]) break;
-        expr = expr.substring('[' == match[3] ? match[1].length : match[0].length);
-        match = pattern.exec(expr);
-      }
-
-      return before + String.interpret(ctx);
-    });
-  }
-});
-Template.Pattern = /(^|.|\r|\n)(#\{(.*?)\})/;
-
-var $break = { };
-
-var Enumerable = {
-  each: function(iterator, context) {
-    var index = 0;
-    iterator = iterator.bind(context);
-    try {
-      this._each(function(value) {
-        iterator(value, index++);
-      });
-    } catch (e) {
-      if (e != $break) throw e;
-    }
-    return this;
-  },
-
-  eachSlice: function(number, iterator, context) {
-    iterator = iterator ? iterator.bind(context) : Prototype.K;
-    var index = -number, slices = [], array = this.toArray();
-    while ((index += number) &lt; array.length)
-      slices.push(array.slice(index, index+number));
-    return slices.collect(iterator, context);
-  },
-
-  all: function(iterator, context) {
-    iterator = iterator ? iterator.bind(context) : Prototype.K;
-    var result = true;
-    this.each(function(value, index) {
-      result = result &amp;&amp; !!iterator(value, index);
-      if (!result) throw $break;
-    });
-    return result;
-  },
-
-  any: function(iterator, context) {
-    iterator = iterator ? iterator.bind(context) : Prototype.K;
-    var result = false;
-    this.each(function(value, index) {
-      if (result = !!iterator(value, index))
-        throw $break;
-    });
-    return result;
-  },
-
-  collect: function(iterator, context) {
-    iterator = iterator ? iterator.bind(context) : Prototype.K;
-    var results = [];
-    this.each(function(value, index) {
-      results.push(iterator(value, index));
-    });
-    return results;
-  },
-
-  detect: function(iterator, context) {
-    iterator = iterator.bind(context);
-    var result;
-    this.each(function(value, index) {
-      if (iterator(value, index)) {
-        result = value;
-        throw $break;
-      }
-    });
-    return result;
-  },
-
-  findAll: function(iterator, context) {
-    iterator = iterator.bind(context);
-    var results = [];
-    this.each(function(value, index) {
-      if (iterator(value, index))
-        results.push(value);
-    });
-    return results;
-  },
-
-  grep: function(filter, iterator, context) {
-    iterator = iterator ? iterator.bind(context) : Prototype.K;
-    var results = [];
-
-    if (Object.isString(filter))
-      filter = new RegExp(filter);
-
-    this.each(function(value, index) {
-      if (filter.match(value))
-        results.push(iterator(value, index));
-    });
-    return results;
-  },
-
-  include: function(object) {
-    if (Object.isFunction(this.indexOf))
-      if (this.indexOf(object) != -1) return true;
-
-    var found = false;
-    this.each(function(value) {
-      if (value == object) {
-        found = true;
-        throw $break;
-      }
-    });
-    return found;
-  },
-
-  inGroupsOf: function(number, fillWith) {
-    fillWith = Object.isUndefined(fillWith) ? null : fillWith;
-    return this.eachSlice(number, function(slice) {
-      while(slice.length &lt; number) slice.push(fillWith);
-      return slice;
-    });
-  },
-
-  inject: function(memo, iterator, context) {
-    iterator = iterator.bind(context);
-    this.each(function(value, index) {
-      memo = iterator(memo, value, index);
-    });
-    return memo;
-  },
-
-  invoke: function(method) {
-    var args = $A(arguments).slice(1);
-    return this.map(function(value) {
-      return value[method].apply(value, args);
-    });
-  },
-
-  max: function(iterator, context) {
-    iterator = iterator ? iterator.bind(context) : Prototype.K;
-    var result;
-    this.each(function(value, index) {
-      value = iterator(value, index);
-      if (result == null || value &gt;= result)
-        result = value;
-    });
-    return result;
-  },
-
-  min: function(iterator, context) {
-    iterator = iterator ? iterator.bind(context) : Prototype.K;
-    var result;
-    this.each(function(value, index) {
-      value = iterator(value, index);
-      if (result == null || value &lt; result)
-        result = value;
-    });
-    return result;
-  },
-
-  partition: function(iterator, context) {
-    iterator = iterator ? iterator.bind(context) : Prototype.K;
-    var trues = [], falses = [];
-    this.each(function(value, index) {
-      (iterator(value, index) ?
-        trues : falses).push(value);
-    });
-    return [trues, falses];
-  },
-
-  pluck: function(property) {
-    var results = [];
-    this.each(function(value) {
-      results.push(value[property]);
-    });
-    return results;
-  },
-
-  reject: function(iterator, context) {
-    iterator = iterator.bind(context);
-    var results = [];
-    this.each(function(value, index) {
-      if (!iterator(value, index))
-        results.push(value);
-    });
-    return results;
-  },
-
-  sortBy: function(iterator, context) {
-    iterator = iterator.bind(context);
-    return this.map(function(value, index) {
-      return {value: value, criteria: iterator(value, index)};
-    }).sort(function(left, right) {
-      var a = left.criteria, b = right.criteria;
-      return a &lt; b ? -1 : a &gt; b ? 1 : 0;
-    }).pluck('value');
-  },
-
-  toArray: function() {
-    return this.map();
-  },
-
-  zip: function() {
-    var iterator = Prototype.K, args = $A(arguments);
-    if (Object.isFunction(args.last()))
-      iterator = args.pop();
-
-    var collections = [this].concat(args).map($A);
-    return this.map(function(value, index) {
-      return iterator(collections.pluck(index));
-    });
-  },
-
-  size: function() {
-    return this.toArray().length;
-  },
-
-  inspect: function() {
-    return '#&lt;Enumerable:' + this.toArray().inspect() + '&gt;';
-  }
-};
-
-Object.extend(Enumerable, {
-  map:     Enumerable.collect,
-  find:    Enumerable.detect,
-  select:  Enumerable.findAll,
-  filter:  Enumerable.findAll,
-  member:  Enumerable.include,
-  entries: Enumerable.toArray,
-  every:   Enumerable.all,
-  some:    Enumerable.any
-});
-function $A(iterable) {
-  if (!iterable) return [];
-  if (iterable.toArray) return iterable.toArray();
-  var length = iterable.length || 0, results = new Array(length);
-  while (length--) results[length] = iterable[length];
-  return results;
-}
-
-if (Prototype.Browser.WebKit) {
-  $A = function(iterable) {
-    if (!iterable) return [];
-    if (!(Object.isFunction(iterable) &amp;&amp; iterable == '[object NodeList]') &amp;&amp;
-        iterable.toArray) return iterable.toArray();
-    var length = iterable.length || 0, results = new Array(length);
-    while (length--) results[length] = iterable[length];
-    return results;
-  };
-}
-
-Array.from = $A;
-
-Object.extend(Array.prototype, Enumerable);
-
-if (!Array.prototype._reverse) Array.prototype._reverse = Array.prototype.reverse;
-
-Object.extend(Array.prototype, {
-  _each: function(iterator) {
-    for (var i = 0, length = this.length; i &lt; length; i++)
-      iterator(this[i]);
-  },
-
-  clear: function() {
-    this.length = 0;
-    return this;
-  },
-
-  first: function() {
-    return this[0];
-  },
-
-  last: function() {
-    return this[this.length - 1];
-  },
-
-  compact: function() {
-    return this.select(function(value) {
-      return value != null;
-    });
-  },
-
-  flatten: function() {
-    return this.inject([], function(array, value) {
-      return array.concat(Object.isArray(value) ?
-        value.flatten() : [value]);
-    });
-  },
-
-  without: function() {
-    var values = $A(arguments);
-    return this.select(function(value) {
-      return !values.include(value);
-    });
-  },
-
-  reverse: function(inline) {
-    return (inline !== false ? this : this.toArray())._reverse();
-  },
-
-  reduce: function() {
-    return this.length &gt; 1 ? this : this[0];
-  },
-
-  uniq: function(sorted) {
-    return this.inject([], function(array, value, index) {
-      if (0 == index || (sorted ? array.last() != value : !array.include(value)))
-        array.push(value);
-      return array;
-    });
-  },
-
-  intersect: function(array) {
-    return this.uniq().findAll(function(item) {
-      return array.detect(function(value) { return item === value });
-    });
-  },
-
-  clone: function() {
-    return [].concat(this);
-  },
-
-  size: function() {
-    return this.length;
-  },
-
-  inspect: function() {
-    return '[' + this.map(Object.inspect).join(', ') + ']';
-  },
-
-  toJSON: function() {
-    var results = [];
-    this.each(function(object) {
-      var value = Object.toJSON(object);
-      if (!Object.isUndefined(value)) results.push(value);
-    });
-    return '[' + results.join(', ') + ']';
-  }
-});
-
-// use native browser JS 1.6 implementation if available
-if (Object.isFunction(Array.prototype.forEach))
-  Array.prototype._each = Array.prototype.forEach;
-
-if (!Array.prototype.indexOf) Array.prototype.indexOf = function(item, i) {
-  i || (i = 0);
-  var length = this.length;
-  if (i &lt; 0) i = length + i;
-  for (; i &lt; length; i++)
-    if (this[i] === item) return i;
-  return -1;
-};
-
-if (!Array.prototype.lastIndexOf) Array.prototype.lastIndexOf = function(item, i) {
-  i = isNaN(i) ? this.length : (i &lt; 0 ? this.length + i : i) + 1;
-  var n = this.slice(0, i).reverse().indexOf(item);
-  return (n &lt; 0) ? n : i - n - 1;
-};
-
-Array.prototype.toArray = Array.prototype.clone;
-
-function $w(string) {
-  if (!Object.isString(string)) return [];
-  string = string.strip();
-  return string ? string.split(/\s+/) : [];
-}
-
-if (Prototype.Browser.Opera){
-  Array.prototype.concat = function() {
-    var array = [];
-    for (var i = 0, length = this.length; i &lt; length; i++) array.push(this[i]);
-    for (var i = 0, length = arguments.length; i &lt; length; i++) {
-      if (Object.isArray(arguments[i])) {
-        for (var j = 0, arrayLength = arguments[i].length; j &lt; arrayLength; j++)
-          array.push(arguments[i][j]);
-      } else {
-        array.push(arguments[i]);
-      }
-    }
-    return array;
-  };
-}
-Object.extend(Number.prototype, {
-  toColorPart: function() {
-    return this.toPaddedString(2, 16);
-  },
-
-  succ: function() {
-    return this + 1;
-  },
-
-  times: function(iterator) {
-    $R(0, this, true).each(iterator);
-    return this;
-  },
-
-  toPaddedString: function(length, radix) {
-    var string = this.toString(radix || 10);
-    return '0'.times(length - string.length) + string;
-  },
-
-  toJSON: function() {
-    return isFinite(this) ? this.toString() : 'null';
-  }
-});
-
-$w('abs round ceil floor').each(function(method){
-  Number.prototype[method] = Math[method].methodize();
-});
-function $H(object) {
-  return new Hash(object);
-};
-
-var Hash = Class.create(Enumerable, (function() {
-
-  function toQueryPair(key, value) {
-    if (Object.isUndefined(value)) return key;
-    return key + '=' + encodeURIComponent(String.interpret(value));
-  }
-
-  return {
-    initialize: function(object) {
-      this._object = Object.isHash(object) ? object.toObject() : Object.clone(object);
-    },
-
-    _each: function(iterator) {
-      for (var key in this._object) {
-        var value = this._object[key], pair = [key, value];
-        pair.key = key;
-        pair.value = value;
-        iterator(pair);
-      }
-    },
-
-    set: function(key, value) {
-      return this._object[key] = value;
-    },
-
-    get: function(key) {
-      return this._object[key];
-    },
-
-    unset: function(key) {
-      var value = this._object[key];
-      delete this._object[key];
-      return value;
-    },
-
-    toObject: function() {
-      return Object.clone(this._object);
-    },
-
-    keys: function() {
-      return this.pluck('key');
-    },
-
-    values: function() {
-      return this.pluck('value');
-    },
-
-    index: function(value) {
-      var match = this.detect(function(pair) {
-        return pair.value === value;
-      });
-      return match &amp;&amp; match.key;
-    },
-
-    merge: function(object) {
-      return this.clone().update(object);
-    },
-
-    update: function(object) {
-      return new Hash(object).inject(this, function(result, pair) {
-        result.set(pair.key, pair.value);
-        return result;
-      });
-    },
-
-    toQueryString: function() {
-      return this.map(function(pair) {
-        var key = encodeURIComponent(pair.key), values = pair.value;
-
-        if (values &amp;&amp; typeof values == 'object') {
-          if (Object.isArray(values))
-            return values.map(toQueryPair.curry(key)).join('&amp;');
-        }
-        return toQueryPair(key, values);
-      }).join('&amp;');
-    },
-
-    inspect: function() {
-      return '#&lt;Hash:{' + this.map(function(pair) {
-        return pair.map(Object.inspect).join(': ');
-      }).join(', ') + '}&gt;';
-    },
-
-    toJSON: function() {
-      return Object.toJSON(this.toObject());
-    },
-
-    clone: function() {
-      return new Hash(this);
-    }
-  }
-})());
-
-Hash.prototype.toTemplateReplacements = Hash.prototype.toObject;
-Hash.from = $H;
-var ObjectRange = Class.create(Enumerable, {
-  initialize: function(start, end, exclusive) {
-    this.start = start;
-    this.end = end;
-    this.exclusive = exclusive;
-  },
-
-  _each: function(iterator) {
-    var value = this.start;
-    while (this.include(value)) {
-      iterator(value);
-      value = value.succ();
-    }
-  },
-
-  include: function(value) {
-    if (value &lt; this.start)
-      return false;
-    if (this.exclusive)
-      return value &lt; this.end;
-    return value &lt;= this.end;
-  }
-});
-
-var $R = function(start, end, exclusive) {
-  return new ObjectRange(start, end, exclusive);
-};
-
-var Ajax = {
-  getTransport: function() {
-    return Try.these(
-      function() {return new XMLHttpRequest()},
-      function() {return new ActiveXObject('Msxml2.XMLHTTP')},
-      function() {return new ActiveXObject('Microsoft.XMLHTTP')}
-    ) || false;
-  },
-
-  activeRequestCount: 0
-};
-
-Ajax.Responders = {
-  responders: [],
-
-  _each: function(iterator) {
-    this.responders._each(iterator);
-  },
-
-  register: function(responder) {
-    if (!this.include(responder))
-      this.responders.push(responder);
-  },
-
-  unregister: function(responder) {
-    this.responders = this.responders.without(responder);
-  },
-
-  dispatch: function(callback, request, transport, json) {
-    this.each(function(responder) {
-      if (Object.isFunction(responder[callback])) {
-        try {
-          responder[callback].apply(responder, [request, transport, json]);
-        } catch (e) { }
-      }
-    });
-  }
-};
-
-Object.extend(Ajax.Responders, Enumerable);
-
-Ajax.Responders.register({
-  onCreate:   function() { Ajax.activeRequestCount++ },
-  onComplete: function() { Ajax.activeRequestCount-- }
-});
-
-Ajax.Base = Class.create({
-  initialize: function(options) {
-    this.options = {
-      method:       'post',
-      asynchronous: true,
-      contentType:  'application/x-www-form-urlencoded',
-      encoding:     'UTF-8',
-      parameters:   '',
-      evalJSON:     true,
-      evalJS:       true
-    };
-    Object.extend(this.options, options || { });
-
-    this.options.method = this.options.method.toLowerCase();
-
-    if (Object.isString(this.options.parameters))
-      this.options.parameters = this.options.parameters.toQueryParams();
-    else if (Object.isHash(this.options.parameters))
-      this.options.parameters = this.options.parameters.toObject();
-  }
-});
-
-Ajax.Request = Class.create(Ajax.Base, {
-  _complete: false,
-
-  initialize: function($super, url, options) {
-    $super(options);
-    this.transport = Ajax.getTransport();
-    this.request(url);
-  },
-
-  request: function(url) {
-    this.url = url;
-    this.method = this.options.method;
-    var params = Object.clone(this.options.parameters);
-
-    if (!['get', 'post'].include(this.method)) {
-      // simulate other verbs over post
-      params['_method'] = this.method;
-      this.method = 'post';
-    }
-
-    this.parameters = params;
-
-    if (params = Object.toQueryString(params)) {
-      // when GET, append parameters to URL
-      if (this.method == 'get')
-        this.url += (this.url.include('?') ? '&amp;' : '?') + params;
-      else if (/Konqueror|Safari|KHTML/.test(navigator.userAgent))
-        params += '&amp;_=';
-    }
-
-    try {
-      var response = new Ajax.Response(this);
-      if (this.options.onCreate) this.options.onCreate(response);
-      Ajax.Responders.dispatch('onCreate', this, response);
-
-      this.transport.open(this.method.toUpperCase(), this.url,
-        this.options.asynchronous);
-
-      if (this.options.asynchronous) this.respondToReadyState.bind(this).defer(1);
-
-      this.transport.onreadystatechange = this.onStateChange.bind(this);
-      this.setRequestHeaders();
-
-      this.body = this.method == 'post' ? (this.options.postBody || params) : null;
-      this.transport.send(this.body);
-
-      /* Force Firefox to handle ready state 4 for synchronous requests */
-      if (!this.options.asynchronous &amp;&amp; this.transport.overrideMimeType)
-        this.onStateChange();
-
-    }
-    catch (e) {
-      this.dispatchException(e);
-    }
-  },
-
-  onStateChange: function() {
-    var readyState = this.transport.readyState;
-    if (readyState &gt; 1 &amp;&amp; !((readyState == 4) &amp;&amp; this._complete))
-      this.respondToReadyState(this.transport.readyState);
-  },
-
-  setRequestHeaders: function() {
-    var headers = {
-      'X-Requested-With': 'XMLHttpRequest',
-      'X-Prototype-Version': Prototype.Version,
-      'Accept': 'text/javascript, text/html, application/xml, text/xml, */*'
-    };
-
-    if (this.method == 'post') {
-      headers['Content-type'] = this.options.contentType +
-        (this.options.encoding ? '; charset=' + this.options.encoding : '');
-
-      /* Force &quot;Connection: close&quot; for older Mozilla browsers to work
-       * around a bug where XMLHttpRequest sends an incorrect
-       * Content-length header. See Mozilla Bugzilla #246651.
-       */
-      if (this.transport.overrideMimeType &amp;&amp;
-          (navigator.userAgent.match(/Gecko\/(\d{4})/) || [0,2005])[1] &lt; 2005)
-            headers['Connection'] = 'close';
-    }
-
-    // user-defined headers
-    if (typeof this.options.requestHeaders == 'object') {
-      var extras = this.options.requestHeaders;
-
-      if (Object.isFunction(extras.push))
-        for (var i = 0, length = extras.length; i &lt; length; i += 2)
-          headers[extras[i]] = extras[i+1];
-      else
-        $H(extras).each(function(pair) { headers[pair.key] = pair.value });
-    }
-
-    for (var name in headers)
-      this.transport.setRequestHeader(name, headers[name]);
-  },
-
-  success: function() {
-    var status = this.getStatus();
-    return !status || (status &gt;= 200 &amp;&amp; status &lt; 300);
-  },
-
-  getStatus: function() {
-    try {
-      return this.transport.status || 0;
-    } catch (e) { return 0 }
-  },
-
-  respondToReadyState: function(readyState) {
-    var state = Ajax.Request.Events[readyState], response = new Ajax.Response(this);
-
-    if (state == 'Complete') {
-      try {
-        this._complete = true;
-        (this.options['on' + response.status]
-         || this.options['on' + (this.success() ? 'Success' : 'Failure')]
-         || Prototype.emptyFunction)(response, response.headerJSON);
-      } catch (e) {
-        this.dispatchException(e);
-      }
-
-      var contentType = response.getHeader('Content-type');
-      if (this.options.evalJS == 'force'
-          || (this.options.evalJS &amp;&amp; this.isSameOrigin() &amp;&amp; contentType
-          &amp;&amp; contentType.match(/^\s*(text|application)\/(x-)?(java|ecma)script(;.*)?\s*$/i)))
-        this.evalResponse();
-    }
-
-    try {
-      (this.options['on' + state] || Prototype.emptyFunction)(response, response.headerJSON);
-      Ajax.Responders.dispatch('on' + state, this, response, response.headerJSON);
-    } catch (e) {
-      this.dispatchException(e);
-    }
-
-    if (state == 'Complete') {
-      // avoid memory leak in MSIE: clean up
-      this.transport.onreadystatechange = Prototype.emptyFunction;
-    }
-  },
-
-  isSameOrigin: function() {
-    var m = this.url.match(/^\s*https?:\/\/[^\/]*/);
-    return !m || (m[0] == '#{protocol}//#{domain}#{port}'.interpolate({
-      protocol: location.protocol,
-      domain: document.domain,
-      port: location.port ? ':' + location.port : ''
-    }));
-  },
-
-  getHeader: function(name) {
-    try {
-      return this.transport.getResponseHeader(name) || null;
-    } catch (e) { return null }
-  },
-
-  evalResponse: function() {
-    try {
-      return eval((this.transport.responseText || '').unfilterJSON());
-    } catch (e) {
-      this.dispatchException(e);
-    }
-  },
-
-  dispatchException: function(exception) {
-    (this.options.onException || Prototype.emptyFunction)(this, exception);
-    Ajax.Responders.dispatch('onException', this, exception);
-  }
-});
-
-Ajax.Request.Events =
-  ['Uninitialized', 'Loading', 'Loaded', 'Interactive', 'Complete'];
-
-Ajax.Response = Class.create({
-  initialize: function(request){
-    this.request = request;
-    var transport  = this.transport  = request.transport,
-        readyState = this.readyState = transport.readyState;
-
-    if((readyState &gt; 2 &amp;&amp; !Prototype.Browser.IE) || readyState == 4) {
-      this.status       = this.getStatus();
-      this.statusText   = this.getStatusText();
-      this.responseText = String.interpret(transport.responseText);
-      this.headerJSON   = this._getHeaderJSON();
-    }
-
-    if(readyState == 4) {
-      var xml = transport.responseXML;
-      this.responseXML  = Object.isUndefined(xml) ? null : xml;
-      this.responseJSON = this._getResponseJSON();
-    }
-  },
-
-  status:      0,
-  statusText: '',
-
-  getStatus: Ajax.Request.prototype.getStatus,
-
-  getStatusText: function() {
-    try {
-      return this.transport.statusText || '';
-    } catch (e) { return '' }
-  },
-
-  getHeader: Ajax.Request.prototype.getHeader,
-
-  getAllHeaders: function() {
-    try {
-      return this.getAllResponseHeaders();
-    } catch (e) { return null }
-  },
-
-  getResponseHeader: function(name) {
-    return this.transport.getResponseHeader(name);
-  },
-
-  getAllResponseHeaders: function() {
-    return this.transport.getAllResponseHeaders();
-  },
-
-  _getHeaderJSON: function() {
-    var json = this.getHeader('X-JSON');
-    if (!json) return null;
-    json = decodeURIComponent(escape(json));
-    try {
-      return json.evalJSON(this.request.options.sanitizeJSON ||
-        !this.request.isSameOrigin());
-    } catch (e) {
-      this.request.dispatchException(e);
-    }
-  },
-
-  _getResponseJSON: function() {
-    var options = this.request.options;
-    if (!options.evalJSON || (options.evalJSON != 'force' &amp;&amp;
-      !(this.getHeader('Content-type') || '').include('application/json')) ||
-        this.responseText.blank())
-          return null;
-    try {
-      return this.responseText.evalJSON(options.sanitizeJSON ||
-        !this.request.isSameOrigin());
-    } catch (e) {
-      this.request.dispatchException(e);
-    }
-  }
-});
-
-Ajax.Updater = Class.create(Ajax.Request, {
-  initialize: function($super, container, url, options) {
-    this.container = {
-      success: (container.success || container),
-      failure: (container.failure || (container.success ? null : container))
-    };
-
-    options = Object.clone(options);
-    var onComplete = options.onComplete;
-    options.onComplete = (function(response, json) {
-      this.updateContent(response.responseText);
-      if (Object.isFunction(onComplete)) onComplete(response, json);
-    }).bind(this);
-
-    $super(url, options);
-  },
-
-  updateContent: function(responseText) {
-    var receiver = this.container[this.success() ? 'success' : 'failure'],
-        options = this.options;
-
-    if (!options.evalScripts) responseText = responseText.stripScripts();
-
-    if (receiver = $(receiver)) {
-      if (options.insertion) {
-        if (Object.isString(options.insertion)) {
-          var insertion = { }; insertion[options.insertion] = responseText;
-          receiver.insert(insertion);
-        }
-        else options.insertion(receiver, responseText);
-      }
-      else receiver.update(responseText);
-    }
-  }
-});
-
-Ajax.PeriodicalUpdater = Class.create(Ajax.Base, {
-  initialize: function($super, container, url, options) {
-    $super(options);
-    this.onComplete = this.options.onComplete;
-
-    this.frequency = (this.options.frequency || 2);
-    this.decay = (this.options.decay || 1);
-
-    this.updater = { };
-    this.container = container;
-    this.url = url;
-
-    this.start();
-  },
-
-  start: function() {
-    this.options.onComplete = this.updateComplete.bind(this);
-    this.onTimerEvent();
-  },
-
-  stop: function() {
-    this.updater.options.onComplete = undefined;
-    clearTimeout(this.timer);
-    (this.onComplete || Prototype.emptyFunction).apply(this, arguments);
-  },
-
-  updateComplete: function(response) {
-    if (this.options.decay) {
-      this.decay = (response.responseText == this.lastText ?
-        this.decay * this.options.decay : 1);
-
-      this.lastText = response.responseText;
-    }
-    this.timer = this.onTimerEvent.bind(this).delay(this.decay * this.frequency);
-  },
-
-  onTimerEvent: function() {
-    this.updater = new Ajax.Updater(this.container, this.url, this.options);
-  }
-});
-function $(element) {
-  if (arguments.length &gt; 1) {
-    for (var i = 0, elements = [], length = arguments.length; i &lt; length; i++)
-      elements.push($(arguments[i]));
-    return elements;
-  }
-  if (Object.isString(element))
-    element = document.getElementById(element);
-  return Element.extend(element);
-}
-
-if (Prototype.BrowserFeatures.XPath) {
-  document._getElementsByXPath = function(expression, parentElement) {
-    var results = [];
-    var query = document.evaluate(expression, $(parentElement) || document,
-      null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null);
-    for (var i = 0, length = query.snapshotLength; i &lt; length; i++)
-      results.push(Element.extend(query.snapshotItem(i)));
-    return results;
-  };
-}
-
-/*--------------------------------------------------------------------------*/
-
-if (!window.Node) var Node = { };
-
-if (!Node.ELEMENT_NODE) {
-  // DOM level 2 ECMAScript Language Binding
-  Object.extend(Node, {
-    ELEMENT_NODE: 1,
-    ATTRIBUTE_NODE: 2,
-    TEXT_NODE: 3,
-    CDATA_SECTION_NODE: 4,
-    ENTITY_REFERENCE_NODE: 5,
-    ENTITY_NODE: 6,
-    PROCESSING_INSTRUCTION_NODE: 7,
-    COMMENT_NODE: 8,
-    DOCUMENT_NODE: 9,
-    DOCUMENT_TYPE_NODE: 10,
-    DOCUMENT_FRAGMENT_NODE: 11,
-    NOTATION_NODE: 12
-  });
-}
-
-(function() {
-  var element = this.Element;
-  this.Element = function(tagName, attributes) {
-    attributes = attributes || { };
-    tagName = tagName.toLowerCase();
-    var cache = Element.cache;
-    if (Prototype.Browser.IE &amp;&amp; attributes.name) {
-      tagName = '&lt;' + tagName + ' name=&quot;' + attributes.name + '&quot;&gt;';
-      delete attributes.name;
-      return Element.writeAttribute(document.createElement(tagName), attributes);
-    }
-    if (!cache[tagName]) cache[tagName] = Element.extend(document.createElement(tagName));
-    return Element.writeAttribute(cache[tagName].cloneNode(false), attributes);
-  };
-  Object.extend(this.Element, element || { });
-}).call(window);
-
-Element.cache = { };
-
-Element.Methods = {
-  visible: function(element) {
-    return $(element).style.display != 'none';
-  },
-
-  toggle: function(element) {
-    element = $(element);
-    Element[Element.visible(element) ? 'hide' : 'show'](element);
-    return element;
-  },
-
-  hide: function(element) {
-    $(element).style.display = 'none';
-    return element;
-  },
-
-  show: function(element) {
-    $(element).style.display = '';
-    return element;
-  },
-
-  remove: function(element) {
-    element = $(element);
-    element.parentNode.removeChild(element);
-    return element;
-  },
-
-  update: function(element, content) {
-    element = $(element);
-    if (content &amp;&amp; content.toElement) content = content.toElement();
-    if (Object.isElement(content)) return element.update().insert(content);
-    content = Object.toHTML(content);
-    element.innerHTML = content.stripScripts();
-    content.evalScripts.bind(content).defer();
-    return element;
-  },
-
-  replace: function(element, content) {
-    element = $(element);
-    if (content &amp;&amp; content.toElement) content = content.toElement();
-    else if (!Object.isElement(content)) {
-      content = Object.toHTML(content);
-      var range = element.ownerDocument.createRange();
-      range.selectNode(element);
-      content.evalScripts.bind(content).defer();
-      content = range.createContextualFragment(content.stripScripts());
-    }
-    element.parentNode.replaceChild(content, element);
-    return element;
-  },
-
-  insert: function(element, insertions) {
-    element = $(element);
-
-    if (Object.isString(insertions) || Object.isNumber(insertions) ||
-        Object.isElement(insertions) || (insertions &amp;&amp; (insertions.toElement || insertions.toHTML)))
-          insertions = {bottom:insertions};
-
-    var content, insert, tagName, childNodes;
-
-    for (var position in insertions) {
-      content  = insertions[position];
-      position = position.toLowerCase();
-      insert = Element._insertionTranslations[position];
-
-      if (content &amp;&amp; content.toElement) content = content.toElement();
-      if (Object.isElement(content)) {
-        insert(element, content);
-        continue;
-      }
-
-      content = Object.toHTML(content);
-
-      tagName = ((position == 'before' || position == 'after')
-        ? element.parentNode : element).tagName.toUpperCase();
-
-      childNodes = Element._getContentFromAnonymousElement(tagName, content.stripScripts());
-
-      if (position == 'top' || position == 'after') childNodes.reverse();
-      childNodes.each(insert.curry(element));
-
-      content.evalScripts.bind(content).defer();
-    }
-
-    return element;
-  },
-
-  wrap: function(element, wrapper, attributes) {
-    element = $(element);
-    if (Object.isElement(wrapper))
-      $(wrapper).writeAttribute(attributes || { });
-    else if (Object.isString(wrapper)) wrapper = new Element(wrapper, attributes);
-    else wrapper = new Element('div', wrapper);
-    if (element.parentNode)
-      element.parentNode.replaceChild(wrapper, element);
-    wrapper.appendChild(element);
-    return wrapper;
-  },
-
-  inspect: function(element) {
-    element = $(element);
-    var result = '&lt;' + element.tagName.toLowerCase();
-    $H({'id': 'id', 'className': 'class'}).each(function(pair) {
-      var property = pair.first(), attribute = pair.last();
-      var value = (element[property] || '').toString();
-      if (value) result += ' ' + attribute + '=' + value.inspect(true);
-    });
-    return result + '&gt;';
-  },
-
-  recursivelyCollect: function(element, property) {
-    element = $(element);
-    var elements = [];
-    while (element = element[property])
-      if (element.nodeType == 1)
-        elements.push(Element.extend(element));
-    return elements;
-  },
-
-  ancestors: function(element) {
-    return $(element).recursivelyCollect('parentNode');
-  },
-
-  descendants: function(element) {
-    return $(element).select(&quot;*&quot;);
-  },
-
-  firstDescendant: function(element) {
-    element = $(element).firstChild;
-    while (element &amp;&amp; element.nodeType != 1) element = element.nextSibling;
-    return $(element);
-  },
-
-  immediateDescendants: function(element) {
-    if (!(element = $(element).firstChild)) return [];
-    while (element &amp;&amp; element.nodeType != 1) element = element.nextSibling;
-    if (element) return [element].concat($(element).nextSiblings());
-    return [];
-  },
-
-  previousSiblings: function(element) {
-    return $(element).recursivelyCollect('previousSibling');
-  },
-
-  nextSiblings: function(element) {
-    return $(element).recursivelyCollect('nextSibling');
-  },
-
-  siblings: function(element) {
-    element = $(element);
-    return element.previousSiblings().reverse().concat(element.nextSiblings());
-  },
-
-  match: function(element, selector) {
-    if (Object.isString(selector))
-      selector = new Selector(selector);
-    return selector.match($(element));
-  },
-
-  up: function(element, expression, index) {
-    element = $(element);
-    if (arguments.length == 1) return $(element.parentNode);
-    var ancestors = element.ancestors();
-    return Object.isNumber(expression) ? ancestors[expression] :
-      Selector.findElement(ancestors, expression, index);
-  },
-
-  down: function(element, expression, index) {
-    element = $(element);
-    if (arguments.length == 1) return element.firstDescendant();
-    return Object.isNumber(expression) ? element.descendants()[expression] :
-      element.select(expression)[index || 0];
-  },
-
-  previous: function(element, expression, index) {
-    element = $(element);
-    if (arguments.length == 1) return $(Selector.handlers.previousElementSibling(element));
-    var previousSiblings = element.previousSiblings();
-    return Object.isNumber(expression) ? previousSiblings[expression] :
-      Selector.findElement(previousSiblings, expression, index);
-  },
-
-  next: function(element, expression, index) {
-    element = $(element);
-    if (arguments.length == 1) return $(Selector.handlers.nextElementSibling(element));
-    var nextSiblings = element.nextSiblings();
-    return Object.isNumber(expression) ? nextSiblings[expression] :
-      Selector.findElement(nextSiblings, expression, index);
-  },
-
-  select: function() {
-    var args = $A(arguments), element = $(args.shift());
-    return Selector.findChildElements(element, args);
-  },
-
-  adjacent: function() {
-    var args = $A(arguments), element = $(args.shift());
-    return Selector.findChildElements(element.parentNode, args).without(element);
-  },
-
-  identify: function(element) {
-    element = $(element);
-    var id = element.readAttribute('id'), self = arguments.callee;
-    if (id) return id;
-    do { id = 'anonymous_element_' + self.counter++ } while ($(id));
-    element.writeAttribute('id', id);
-    return id;
-  },
-
-  readAttribute: function(element, name) {
-    element = $(element);
-    if (Prototype.Browser.IE) {
-      var t = Element._attributeTranslations.read;
-      if (t.values[name]) return t.values[name](element, name);
-      if (t.names[name]) name = t.names[name];
-      if (name.include(':')) {
-        return (!element.attributes || !element.attributes[name]) ? null :
-         element.attributes[name].value;
-      }
-    }
-    return element.getAttribute(name);
-  },
-
-  writeAttribute: function(element, name, value) {
-    element = $(element);
-    var attributes = { }, t = Element._attributeTranslations.write;
-
-    if (typeof name == 'object') attributes = name;
-    else attributes[name] = Object.isUndefined(value) ? true : value;
-
-    for (var attr in attributes) {
-      name = t.names[attr] || attr;
-      value = attributes[attr];
-      if (t.values[attr]) name = t.values[attr](element, value);
-      if (value === false || value === null)
-        element.removeAttribute(name);
-      else if (value === true)
-        element.setAttribute(name, name);
-      else element.setAttribute(name, value);
-    }
-    return element;
-  },
-
-  getHeight: function(element) {
-    return $(element).getDimensions().height;
-  },
-
-  getWidth: function(element) {
-    return $(element).getDimensions().width;
-  },
-
-  classNames: function(element) {
-    return new Element.ClassNames(element);
-  },
-
-  hasClassName: function(element, className) {
-    if (!(element = $(element))) return;
-    var elementClassName = element.className;
-    return (elementClassName.length &gt; 0 &amp;&amp; (elementClassName == className ||
-      new RegExp(&quot;(^|\\s)&quot; + className + &quot;(\\s|$)&quot;).test(elementClassName)));
-  },
-
-  addClassName: function(element, className) {
-    if (!(element = $(element))) return;
-    if (!element.hasClassName(className))
-      element.className += (element.className ? ' ' : '') + className;
-    return element;
-  },
-
-  removeClassName: function(element, className) {
-    if (!(element = $(element))) return;
-    element.className = element.className.replace(
-      new RegExp(&quot;(^|\\s+)&quot; + className + &quot;(\\s+|$)&quot;), ' ').strip();
-    return element;
-  },
-
-  toggleClassName: function(element, className) {
-    if (!(element = $(element))) return;
-    return element[element.hasClassName(className) ?
-      'removeClassName' : 'addClassName'](className);
-  },
-
-  // removes whitespace-only text node children
-  cleanWhitespace: function(element) {
-    element = $(element);
-    var node = element.firstChild;
-    while (node) {
-      var nextNode = node.nextSibling;
-      if (node.nodeType == 3 &amp;&amp; !/\S/.test(node.nodeValue))
-        element.removeChild(node);
-      node = nextNode;
-    }
-    return element;
-  },
-
-  empty: function(element) {
-    return $(element).innerHTML.blank();
-  },
-
-  descendantOf: function(element, ancestor) {
-    element = $(element), ancestor = $(ancestor);
-    var originalAncestor = ancestor;
-
-    if (element.compareDocumentPosition)
-      return (element.compareDocumentPosition(ancestor) &amp; 8) === 8;
-
-    if (element.sourceIndex &amp;&amp; !Prototype.Browser.Opera) {
-      var e = element.sourceIndex, a = ancestor.sourceIndex,
-       nextAncestor = ancestor.nextSibling;
-      if (!nextAncestor) {
-        do { ancestor = ancestor.parentNode; }
-        while (!(nextAncestor = ancestor.nextSibling) &amp;&amp; ancestor.parentNode);
-      }
-      if (nextAncestor &amp;&amp; nextAncestor.sourceIndex)
-       return (e &gt; a &amp;&amp; e &lt; nextAncestor.sourceIndex);
-    }
-
-    while (element = element.parentNode)
-      if (element == originalAncestor) return true;
-    return false;
-  },
-
-  scrollTo: function(element) {
-    element = $(element);
-    var pos = element.cumulativeOffset();
-    window.scrollTo(pos[0], pos[1]);
-    return element;
-  },
-
-  getStyle: function(element, style) {
-    element = $(element);
-    style = style == 'float' ? 'cssFloat' : style.camelize();
-    var value = element.style[style];
-    if (!value) {
-      var css = document.defaultView.getComputedStyle(element, null);
-      value = css ? css[style] : null;
-    }
-    if (style == 'opacity') return value ? parseFloat(value) : 1.0;
-    return value == 'auto' ? null : value;
-  },
-
-  getOpacity: function(element) {
-    return $(element).getStyle('opacity');
-  },
-
-  setStyle: function(element, styles) {
-    element = $(element);
-    var elementStyle = element.style, match;
-    if (Object.isString(styles)) {
-      element.style.cssText += ';' + styles;
-      return styles.include('opacity') ?
-        element.setOpacity(styles.match(/opacity:\s*(\d?\.?\d*)/)[1]) : element;
-    }
-    for (var property in styles)
-      if (property == 'opacity') element.setOpacity(styles[property]);
-      else
-        elementStyle[(property == 'float' || property == 'cssFloat') ?
-          (Object.isUndefined(elementStyle.styleFloat) ? 'cssFloat' : 'styleFloat') :
-            property] = styles[property];
-
-    return element;
-  },
-
-  setOpacity: function(element, value) {
-    element = $(element);
-    element.style.opacity = (value == 1 || value === '') ? '' :
-      (value &lt; 0.00001) ? 0 : value;
-    return element;
-  },
-
-  getDimensions: function(element) {
-    element = $(element);
-    var display = $(element).getStyle('display');
-    if (display != 'none' &amp;&amp; display != null) // Safari bug
-      return {width: element.offsetWidth, height: element.offsetHeight};
-
-    // All *Width and *Height properties give 0 on elements with display none,
-    // so enable the element temporarily
-    var els = element.style;
-    var originalVisibility = els.visibility;
-    var originalPosition = els.position;
-    var originalDisplay = els.display;
-    els.visibility = 'hidden';
-    els.position = 'absolute';
-    els.display = 'block';
-    var originalWidth = element.clientWidth;
-    var originalHeight = element.clientHeight;
-    els.display = originalDisplay;
-    els.position = originalPosition;
-    els.visibility = originalVisibility;
-    return {width: originalWidth, height: originalHeight};
-  },
-
-  makePositioned: function(element) {
-    element = $(element);
-    var pos = Element.getStyle(element, 'position');
-    if (pos == 'static' || !pos) {
-      element._madePositioned = true;
-      element.style.position = 'relative';
-      // Opera returns the offset relative to the positioning context, when an
-      // element is position relative but top and left have not been defined
-      if (window.opera) {
-        element.style.top = 0;
-        element.style.left = 0;
-      }
-    }
-    return element;
-  },
-
-  undoPositioned: function(element) {
-    element = $(element);
-    if (element._madePositioned) {
-      element._madePositioned = undefined;
-      element.style.position =
-        element.style.top =
-        element.style.left =
-        element.style.bottom =
-        element.style.right = '';
-    }
-    return element;
-  },
-
-  makeClipping: function(element) {
-    element = $(element);
-    if (element._overflow) return element;
-    element._overflow = Element.getStyle(element, 'overflow') || 'auto';
-    if (element._overflow !== 'hidden')
-      element.style.overflow = 'hidden';
-    return element;
-  },
-
-  undoClipping: function(element) {
-    element = $(element);
-    if (!element._overflow) return element;
-    element.style.overflow = element._overflow == 'auto' ? '' : element._overflow;
-    element._overflow = null;
-    return element;
-  },
-
-  cumulativeOffset: function(element) {
-    var valueT = 0, valueL = 0;
-    do {
-      valueT += element.offsetTop  || 0;
-      valueL += element.offsetLeft || 0;
-      element = element.offsetParent;
-    } while (element);
-    return Element._returnOffset(valueL, valueT);
-  },
-
-  positionedOffset: function(element) {
-    var valueT = 0, valueL = 0;
-    do {
-      valueT += element.offsetTop  || 0;
-      valueL += element.offsetLeft || 0;
-      element = element.offsetParent;
-      if (element) {
-        if (element.tagName == 'BODY') break;
-        var p = Element.getStyle(element, 'position');
-        if (p !== 'static') break;
-      }
-    } while (element);
-    return Element._returnOffset(valueL, valueT);
-  },
-
-  absolutize: function(element) {
-    element = $(element);
-    if (element.getStyle('position') == 'absolute') return;
-    // Position.prepare(); // To be done manually by Scripty when it needs it.
-
-    var offsets = element.positionedOffset();
-    var top     = offsets[1];
-    var left    = offsets[0];
-    var width   = element.clientWidth;
-    var height  = element.clientHeight;
-
-    element._originalLeft   = left - parseFloat(element.style.left  || 0);
-    element._originalTop    = top  - parseFloat(element.style.top || 0);
-    element._originalWidth  = element.style.width;
-    element._originalHeight = element.style.height;
-
-    element.style.position = 'absolute';
-    element.style.top    = top + 'px';
-    element.style.left   = left + 'px';
-    element.style.width  = width + 'px';
-    element.style.height = height + 'px';
-    return element;
-  },
-
-  relativize: function(element) {
-    element = $(element);
-    if (element.getStyle('position') == 'relative') return;
-    // Position.prepare(); // To be done manually by Scripty when it needs it.
-
-    element.style.position = 'relative';
-    var top  = parseFloat(element.style.top  || 0) - (element._originalTop || 0);
-    var left = parseFloat(element.style.left || 0) - (element._originalLeft || 0);
-
-    element.style.top    = top + 'px';
-    element.style.left   = left + 'px';
-    element.style.height = element._originalHeight;
-    element.style.width  = element._originalWidth;
-    return element;
-  },
-
-  cumulativeScrollOffset: function(element) {
-    var valueT = 0, valueL = 0;
-    do {
-      valueT += element.scrollTop  || 0;
-      valueL += element.scrollLeft || 0;
-      element = element.parentNode;
-    } while (element);
-    return Element._returnOffset(valueL, valueT);
-  },
-
-  getOffsetParent: function(element) {
-    if (element.offsetParent) return $(element.offsetParent);
-    if (element == document.body) return $(element);
-
-    while ((element = element.parentNode) &amp;&amp; element != document.body)
-      if (Element.getStyle(element, 'position') != 'static')
-        return $(element);
-
-    return $(document.body);
-  },
-
-  viewportOffset: function(forElement) {
-    var valueT = 0, valueL = 0;
-
-    var element = forElement;
-    do {
-      valueT += element.offsetTop  || 0;
-      valueL += element.offsetLeft || 0;
-
-      // Safari fix
-      if (element.offsetParent == document.body &amp;&amp;
-        Element.getStyle(element, 'position') == 'absolute') break;
-
-    } while (element = element.offsetParent);
-
-    element = forElement;
-    do {
-      if (!Prototype.Browser.Opera || element.tagName == 'BODY') {
-        valueT -= element.scrollTop  || 0;
-        valueL -= element.scrollLeft || 0;
-      }
-    } while (element = element.parentNode);
-
-    return Element._returnOffset(valueL, valueT);
-  },
-
-  clonePosition: function(element, source) {
-    var options = Object.extend({
-      setLeft:    true,
-      setTop:     true,
-      setWidth:   true,
-      setHeight:  true,
-      offsetTop:  0,
-      offsetLeft: 0
-    }, arguments[2] || { });
-
-    // find page position of source
-    source = $(source);
-    var p = source.viewportOffset();
-
-    // find coordinate system to use
-    element = $(element);
-    var delta = [0, 0];
-    var parent = null;
-    // delta [0,0] will do fine with position: fixed elements,
-    // position:absolute needs offsetParent deltas
-    if (Element.getStyle(element, 'position') == 'absolute') {
-      parent = element.getOffsetParent();
-      delta = parent.viewportOffset();
-    }
-
-    // correct by body offsets (fixes Safari)
-    if (parent == document.body) {
-      delta[0] -= document.body.offsetLeft;
-      delta[1] -= document.body.offsetTop;
-    }
-
-    // set position
-    if (options.setLeft)   element.style.left  = (p[0] - delta[0] + options.offsetLeft) + 'px';
-    if (options.setTop)    element.style.top   = (p[1] - delta[1] + options.offsetTop) + 'px';
-    if (options.setWidth)  element.style.width = source.offsetWidth + 'px';
-    if (options.setHeight) element.style.height = source.offsetHeight + 'px';
-    return element;
-  }
-};
-
-Element.Methods.identify.counter = 1;
-
-Object.extend(Element.Methods, {
-  getElementsBySelector: Element.Methods.select,
-  childElements: Element.Methods.immediateDescendants
-});
-
-Element._attributeTranslations = {
-  write: {
-    names: {
-      className: 'class',
-      htmlFor:   'for'
-    },
-    values: { }
-  }
-};
-
-if (Prototype.Browser.Opera) {
-  Element.Methods.getStyle = Element.Methods.getStyle.wrap(
-    function(proceed, element, style) {
-      switch (style) {
-        case 'left': case 'top': case 'right': case 'bottom':
-          if (proceed(element, 'position') === 'static') return null;
-        case 'height': case 'width':
-          // returns '0px' for hidden elements; we want it to return null
-          if (!Element.visible(element)) return null;
-
-          // returns the border-box dimensions rather than the content-box
-          // dimensions, so we subtract padding and borders from the value
-          var dim = parseInt(proceed(element, style), 10);
-
-          if (dim !== element['offset' + style.capitalize()])
-            return dim + 'px';
-
-          var properties;
-          if (style === 'height') {
-            properties = ['border-top-width', 'padding-top',
-             'padding-bottom', 'border-bottom-width'];
-          }
-          else {
-            properties = ['border-left-width', 'padding-left',
-             'padding-right', 'border-right-width'];
-          }
-          return properties.inject(dim, function(memo, property) {
-            var val = proceed(element, property);
-            return val === null ? memo : memo - parseInt(val, 10);
-          }) + 'px';
-        default: return proceed(element, style);
-      }
-    }
-  );
-
-  Element.Methods.readAttribute = Element.Methods.readAttribute.wrap(
-    function(proceed, element, attribute) {
-      if (attribute === 'title') return element.title;
-      return proceed(element, attribute);
-    }
-  );
-}
-
-else if (Prototype.Browser.IE) {
-  // IE doesn't report offsets correctly for static elements, so we change them
-  // to &quot;relative&quot; to get the values, then change them back.
-  Element.Methods.getOffsetParent = Element.Methods.getOffsetParent.wrap(
-    function(proceed, element) {
-      element = $(element);
-      var position = element.getStyle('position');
-      if (position !== 'static') return proceed(element);
-      element.setStyle({ position: 'relative' });
-      var value = proceed(element);
-      element.setStyle({ position: position });
-      return value;
-    }
-  );
-
-  $w('positionedOffset viewportOffset').each(function(method) {
-    Element.Methods[method] = Element.Methods[method].wrap(
-      function(proceed, element) {
-        element = $(element);
-        var position = element.getStyle('position');
-        if (position !== 'static') return proceed(element);
-        // Trigger hasLayout on the offset parent so that IE6 reports
-        // accurate offsetTop and offsetLeft values for position: fixed.
-        var offsetParent = element.getOffsetParent();
-        if (offsetParent &amp;&amp; offsetParent.getStyle('position') === 'fixed')
-          offsetParent.setStyle({ zoom: 1 });
-        element.setStyle({ position: 'relative' });
-        var value = proceed(element);
-        element.setStyle({ position: position });
-        return value;
-      }
-    );
-  });
-
-  Element.Methods.getStyle = function(element, style) {
-    element = $(element);
-    style = (style == 'float' || style == 'cssFloat') ? 'styleFloat' : style.camelize();
-    var value = element.style[style];
-    if (!value &amp;&amp; element.currentStyle) value = element.currentStyle[style];
-
-    if (style == 'opacity') {
-      if (value = (element.getStyle('filter') || '').match(/alpha\(opacity=(.*)\)/))
-        if (value[1]) return parseFloat(value[1]) / 100;
-      return 1.0;
-    }
-
-    if (value == 'auto') {
-      if ((style == 'width' || style == 'height') &amp;&amp; (element.getStyle('display') != 'none'))
-        return element['offset' + style.capitalize()] + 'px';
-      return null;
-    }
-    return value;
-  };
-
-  Element.Methods.setOpacity = function(element, value) {
-    function stripAlpha(filter){
-      return filter.replace(/alpha\([^\)]*\)/gi,'');
-    }
-    element = $(element);
-    var currentStyle = element.currentStyle;
-    if ((currentStyle &amp;&amp; !currentStyle.hasLayout) ||
-      (!currentStyle &amp;&amp; element.style.zoom == 'normal'))
-        element.style.zoom = 1;
-
-    var filter = element.getStyle('filter'), style = element.style;
-    if (value == 1 || value === '') {
-      (filter = stripAlpha(filter)) ?
-        style.filter = filter : style.removeAttribute('filter');
-      return element;
-    } else if (value &lt; 0.00001) value = 0;
-    style.filter = stripAlpha(filter) +
-      'alpha(opacity=' + (value * 100) + ')';
-    return element;
-  };
-
-  Element._attributeTranslations = {
-    read: {
-      names: {
-        'class': 'className',
-        'for':   'htmlFor'
-      },
-      values: {
-        _getAttr: function(element, attribute) {
-          return element.getAttribute(attribute, 2);
-        },
-        _getAttrNode: function(element, attribute) {
-          var node = element.getAttributeNode(attribute);
-          return node ? node.value : &quot;&quot;;
-        },
-        _getEv: function(element, attribute) {
-          attribute = element.getAttribute(attribute);
-          return attribute ? attribute.toString().slice(23, -2) : null;
-        },
-        _flag: function(element, attribute) {
-          return $(element).hasAttribute(attribute) ? attribute : null;
-        },
-        style: function(element) {
-          return element.style.cssText.toLowerCase();
-        },
-        title: function(element) {
-          return element.title;
-        }
-      }
-    }
-  };
-
-  Element._attributeTranslations.write = {
-    names: Object.extend({
-      cellpadding: 'cellPadding',
-      cellspacing: 'cellSpacing'
-    }, Element._attributeTranslations.read.names),
-    values: {
-      checked: function(element, value) {
-        element.checked = !!value;
-      },
-
-      style: function(element, value) {
-        element.style.cssText = value ? value : '';
-      }
-    }
-  };
-
-  Element._attributeTranslations.has = {};
-
-  $w('colSpan rowSpan vAlign dateTime accessKey tabIndex ' +
-      'encType maxLength readOnly longDesc').each(function(attr) {
-    Element._attributeTranslations.write.names[attr.toLowerCase()] = attr;
-    Element._attributeTranslations.has[attr.toLowerCase()] = attr;
-  });
-
-  (function(v) {
-    Object.extend(v, {
-      href:        v._getAttr,
-      src:         v._getAttr,
-      type:        v._getAttr,
-      action:      v._getAttrNode,
-      disabled:    v._flag,
-      checked:     v._flag,
-      readonly:    v._flag,
-      multiple:    v._flag,
-      onload:      v._getEv,
-      onunload:    v._getEv,
-      onclick:     v._getEv,
-      ondblclick:  v._getEv,
-      onmousedown: v._getEv,
-      onmouseup:   v._getEv,
-      onmouseover: v._getEv,
-      onmousemove: v._getEv,
-      onmouseout:  v._getEv,
-      onfocus:     v._getEv,
-      onblur:      v._getEv,
-      onkeypress:  v._getEv,
-      onkeydown:   v._getEv,
-      onkeyup:     v._getEv,
-      onsubmit:    v._getEv,
-      onreset:     v._getEv,
-      onselect:    v._getEv,
-      onchange:    v._getEv
-    });
-  })(Element._attributeTranslations.read.values);
-}
-
-else if (Prototype.Browser.Gecko &amp;&amp; /rv:1\.8\.0/.test(navigator.userAgent)) {
-  Element.Methods.setOpacity = function(element, value) {
-    element = $(element);
-    element.style.opacity = (value == 1) ? 0.999999 :
-      (value === '') ? '' : (value &lt; 0.00001) ? 0 : value;
-    return element;
-  };
-}
-
-else if (Prototype.Browser.WebKit) {
-  Element.Methods.setOpacity = function(element, value) {
-    element = $(element);
-    element.style.opacity = (value == 1 || value === '') ? '' :
-      (value &lt; 0.00001) ? 0 : value;
-
-    if (value == 1)
-      if(element.tagName == 'IMG' &amp;&amp; element.width) {
-        element.width++; element.width--;
-      } else try {
-        var n = document.createTextNode(' ');
-        element.appendChild(n);
-        element.removeChild(n);
-      } catch (e) { }
-
-    return element;
-  };
-
-  // Safari returns margins on body which is incorrect if the child is absolutely
-  // positioned.  For performance reasons, redefine Element#cumulativeOffset for
-  // KHTML/WebKit only.
-  Element.Methods.cumulativeOffset = function(element) {
-    var valueT = 0, valueL = 0;
-    do {
-      valueT += element.offsetTop  || 0;
-      valueL += element.offsetLeft || 0;
-      if (element.offsetParent == document.body)
-        if (Element.getStyle(element, 'position') == 'absolute') break;
-
-      element = element.offsetParent;
-    } while (element);
-
-    return Element._returnOffset(valueL, valueT);
-  };
-}
-
-if (Prototype.Browser.IE || Prototype.Browser.Opera) {
-  // IE and Opera are missing .innerHTML support for TABLE-related and SELECT elements
-  Element.Methods.update = function(element, content) {
-    element = $(element);
-
-    if (content &amp;&amp; content.toElement) content = content.toElement();
-    if (Object.isElement(content)) return element.update().insert(content);
-
-    content = Object.toHTML(content);
-    var tagName = element.tagName.toUpperCase();
-
-    if (tagName in Element._insertionTranslations.tags) {
-      $A(element.childNodes).each(function(node) { element.removeChild(node) });
-      Element._getContentFromAnonymousElement(tagName, content.stripScripts())
-        .each(function(node) { element.appendChild(node) });
-    }
-    else element.innerHTML = content.stripScripts();
-
-    content.evalScripts.bind(content).defer();
-    return element;
-  };
-}
-
-if ('outerHTML' in document.createElement('div')) {
-  Element.Methods.replace = function(element, content) {
-    element = $(element);
-
-    if (content &amp;&amp; content.toElement) content = content.toElement();
-    if (Object.isElement(content)) {
-      element.parentNode.replaceChild(content, element);
-      return element;
-    }
-
-    content = Object.toHTML(content);
-    var parent = element.parentNode, tagName = parent.tagName.toUpperCase();
-
-    if (Element._insertionTranslations.tags[tagName]) {
-      var nextSibling = element.next();
-      var fragments = Element._getContentFromAnonymousElement(tagName, content.stripScripts());
-      parent.removeChild(element);
-      if (nextSibling)
-        fragments.each(function(node) { parent.insertBefore(node, nextSibling) });
-      else
-        fragments.each(function(node) { parent.appendChild(node) });
-    }
-    else element.outerHTML = content.stripScripts();
-
-    content.evalScripts.bind(content).defer();
-    return element;
-  };
-}
-
-Element._returnOffset = function(l, t) {
-  var result = [l, t];
-  result.left = l;
-  result.top = t;
-  return result;
-};
-
-Element._getContentFromAnonymousElement = function(tagName, html) {
-  var div = new Element('div'), t = Element._insertionTranslations.tags[tagName];
-  if (t) {
-    div.innerHTML = t[0] + html + t[1];
-    t[2].times(function() { div = div.firstChild });
-  } else div.innerHTML = html;
-  return $A(div.childNodes);
-};
-
-Element._insertionTranslations = {
-  before: function(element, node) {
-    element.parentNode.insertBefore(node, element);
-  },
-  top: function(element, node) {
-    element.insertBefore(node, element.firstChild);
-  },
-  bottom: function(element, node) {
-    element.appendChild(node);
-  },
-  after: function(element, node) {
-    element.parentNode.insertBefore(node, element.nextSibling);
-  },
-  tags: {
-    TABLE:  ['&lt;table&gt;',                '&lt;/table&gt;',                   1],
-    TBODY:  ['&lt;table&gt;&lt;tbody&gt;',         '&lt;/tbody&gt;&lt;/table&gt;',           2],
-    TR:     ['&lt;table&gt;&lt;tbody&gt;&lt;tr&gt;',     '&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;',      3],
-    TD:     ['&lt;table&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;', '&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;', 4],
-    SELECT: ['&lt;select&gt;',               '&lt;/select&gt;',                  1]
-  }
-};
-
-(function() {
-  Object.extend(this.tags, {
-    THEAD: this.tags.TBODY,
-    TFOOT: this.tags.TBODY,
-    TH:    this.tags.TD
-  });
-}).call(Element._insertionTranslations);
-
-Element.Methods.Simulated = {
-  hasAttribute: function(element, attribute) {
-    attribute = Element._attributeTranslations.has[attribute] || attribute;
-    var node = $(element).getAttributeNode(attribute);
-    return node &amp;&amp; node.specified;
-  }
-};
-
-Element.Methods.ByTag = { };
-
-Object.extend(Element, Element.Methods);
-
-if (!Prototype.BrowserFeatures.ElementExtensions &amp;&amp;
-    document.createElement('div').__proto__) {
-  window.HTMLElement = { };
-  window.HTMLElement.prototype = document.createElement('div').__proto__;
-  Prototype.BrowserFeatures.ElementExtensions = true;
-}
-
-Element.extend = (function() {
-  if (Prototype.BrowserFeatures.SpecificElementExtensions)
-    return Prototype.K;
-
-  var Methods = { }, ByTag = Element.Methods.ByTag;
-
-  var extend = Object.extend(function(element) {
-    if (!element || element._extendedByPrototype ||
-        element.nodeType != 1 || element == window) return element;
-
-    var methods = Object.clone(Methods),
-      tagName = element.tagName, property, value;
-
-    // extend methods for specific tags
-    if (ByTag[tagName]) Object.extend(methods, ByTag[tagName]);
-
-    for (property in methods) {
-      value = methods[property];
-      if (Object.isFunction(value) &amp;&amp; !(property in element))
-        element[property] = value.methodize();
-    }
-
-    element._extendedByPrototype = Prototype.emptyFunction;
-    return element;
-
-  }, {
-    refresh: function() {
-      // extend methods for all tags (Safari doesn't need this)
-      if (!Prototype.BrowserFeatures.ElementExtensions) {
-        Object.extend(Methods, Element.Methods);
-        Object.extend(Methods, Element.Methods.Simulated);
-      }
-    }
-  });
-
-  extend.refresh();
-  return extend;
-})();
-
-Element.hasAttribute = function(element, attribute) {
-  if (element.hasAttribute) return element.hasAttribute(attribute);
-  return Element.Methods.Simulated.hasAttribute(element, attribute);
-};
-
-Element.addMethods = function(methods) {
-  var F = Prototype.BrowserFeatures, T = Element.Methods.ByTag;
-
-  if (!methods) {
-    Object.extend(Form, Form.Methods);
-    Object.extend(Form.Element, Form.Element.Methods);
-    Object.extend(Element.Methods.ByTag, {
-      &quot;FORM&quot;:     Object.clone(Form.Methods),
-      &quot;INPUT&quot;:    Object.clone(Form.Element.Methods),
-      &quot;SELECT&quot;:   Object.clone(Form.Element.Methods),
-      &quot;TEXTAREA&quot;: Object.clone(Form.Element.Methods)
-    });
-  }
-
-  if (arguments.length == 2) {
-    var tagName = methods;
-    methods = arguments[1];
-  }
-
-  if (!tagName) Object.extend(Element.Methods, methods || { });
-  else {
-    if (Object.isArray(tagName)) tagName.each(extend);
-    else extend(tagName);
-  }
-
-  function extend(tagName) {
-    tagName = tagName.toUpperCase();
-    if (!Element.Methods.ByTag[tagName])
-      Element.Methods.ByTag[tagName] = { };
-    Object.extend(Element.Methods.ByTag[tagName], methods);
-  }
-
-  function copy(methods, destination, onlyIfAbsent) {
-    onlyIfAbsent = onlyIfAbsent || false;
-    for (var property in methods) {
-      var value = methods[property];
-      if (!Object.isFunction(value)) continue;
-      if (!onlyIfAbsent || !(property in destination))
-        destination[property] = value.methodize();
-    }
-  }
-
-  function findDOMClass(tagName) {
-    var klass;
-    var trans = {
-      &quot;OPTGROUP&quot;: &quot;OptGroup&quot;, &quot;TEXTAREA&quot;: &quot;TextArea&quot;, &quot;P&quot;: &quot;Paragraph&quot;,
-      &quot;FIELDSET&quot;: &quot;FieldSet&quot;, &quot;UL&quot;: &quot;UList&quot;, &quot;OL&quot;: &quot;OList&quot;, &quot;DL&quot;: &quot;DList&quot;,
-      &quot;DIR&quot;: &quot;Directory&quot;, &quot;H1&quot;: &quot;Heading&quot;, &quot;H2&quot;: &quot;Heading&quot;, &quot;H3&quot;: &quot;Heading&quot;,
-      &quot;H4&quot;: &quot;Heading&quot;, &quot;H5&quot;: &quot;Heading&quot;, &quot;H6&quot;: &quot;Heading&quot;, &quot;Q&quot;: &quot;Quote&quot;,
-      &quot;INS&quot;: &quot;Mod&quot;, &quot;DEL&quot;: &quot;Mod&quot;, &quot;A&quot;: &quot;Anchor&quot;, &quot;IMG&quot;: &quot;Image&quot;, &quot;CAPTION&quot;:
-      &quot;TableCaption&quot;, &quot;COL&quot;: &quot;TableCol&quot;, &quot;COLGROUP&quot;: &quot;TableCol&quot;, &quot;THEAD&quot;:
-      &quot;TableSection&quot;, &quot;TFOOT&quot;: &quot;TableSection&quot;, &quot;TBODY&quot;: &quot;TableSection&quot;, &quot;TR&quot;:
-      &quot;TableRow&quot;, &quot;TH&quot;: &quot;TableCell&quot;, &quot;TD&quot;: &quot;TableCell&quot;, &quot;FRAMESET&quot;:
-      &quot;FrameSet&quot;, &quot;IFRAME&quot;: &quot;IFrame&quot;
-    };
-    if (trans[tagName]) klass = 'HTML' + trans[tagName] + 'Element';
-    if (window[klass]) return window[klass];
-    klass = 'HTML' + tagName + 'Element';
-    if (window[klass]) return window[klass];
-    klass = 'HTML' + tagName.capitalize() + 'Element';
-    if (window[klass]) return window[klass];
-
-    window[klass] = { };
-    window[klass].prototype = document.createElement(tagName).__proto__;
-    return window[klass];
-  }
-
-  if (F.ElementExtensions) {
-    copy(Element.Methods, HTMLElement.prototype);
-    copy(Element.Methods.Simulated, HTMLElement.prototype, true);
-  }
-
-  if (F.SpecificElementExtensions) {
-    for (var tag in Element.Methods.ByTag) {
-      var klass = findDOMClass(tag);
-      if (Object.isUndefined(klass)) continue;
-      copy(T[tag], klass.prototype);
-    }
-  }
-
-  Object.extend(Element, Element.Methods);
-  delete Element.ByTag;
-
-  if (Element.extend.refresh) Element.extend.refresh();
-  Element.cache = { };
-};
-
-document.viewport = {
-  getDimensions: function() {
-    var dimensions = { };
-    var B = Prototype.Browser;
-    $w('width height').each(function(d) {
-      var D = d.capitalize();
-      dimensions[d] = (B.WebKit &amp;&amp; !document.evaluate) ? self['inner' + D] :
-        (B.Opera) ? document.body['client' + D] : document.documentElement['client' + D];
-    });
-    return dimensions;
-  },
-
-  getWidth: function() {
-    return this.getDimensions().width;
-  },
-
-  getHeight: function() {
-    return this.getDimensions().height;
-  },
-
-  getScrollOffsets: function() {
-    return Element._returnOffset(
-      window.pageXOffset || document.documentElement.scrollLeft || document.body.scrollLeft,
-      window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop);
-  }
-};
-/* Portions of the Selector class are derived from Jack Slocum&#226;&#8364;&#8482;s DomQuery,
- * part of YUI-Ext version 0.40, distributed under the terms of an MIT-style
- * license.  Please see http://www.yui-ext.com/ for more information. */
-
-var Selector = Class.create({
-  initialize: function(expression) {
-    this.expression = expression.strip();
-    this.compileMatcher();
-  },
-
-  shouldUseXPath: function() {
-    if (!Prototype.BrowserFeatures.XPath) return false;
-
-    var e = this.expression;
-
-    // Safari 3 chokes on :*-of-type and :empty
-    if (Prototype.Browser.WebKit &amp;&amp;
-     (e.include(&quot;-of-type&quot;) || e.include(&quot;:empty&quot;)))
-      return false;
-
-    // XPath can't do namespaced attributes, nor can it read
-    // the &quot;checked&quot; property from DOM nodes
-    if ((/(\[[\w-]*?:|:checked)/).test(this.expression))
-      return false;
-
-    return true;
-  },
-
-  compileMatcher: function() {
-    if (this.shouldUseXPath())
-      return this.compileXPathMatcher();
-
-    var e = this.expression, ps = Selector.patterns, h = Selector.handlers,
-        c = Selector.criteria, le, p, m;
-
-    if (Selector._cache[e]) {
-      this.matcher = Selector._cache[e];
-      return;
-    }
-
-    this.matcher = [&quot;this.matcher = function(root) {&quot;,
-                    &quot;var r = root, h = Selector.handlers, c = false, n;&quot;];
-
-    while (e &amp;&amp; le != e &amp;&amp; (/\S/).test(e)) {
-      le = e;
-      for (var i in ps) {
-        p = ps[i];
-        if (m = e.match(p)) {
-          this.matcher.push(Object.isFunction(c[i]) ? c[i](m) :
-    	      new Template(c[i]).evaluate(m));
-          e = e.replace(m[0], '');
-          break;
-        }
-      }
-    }
-
-    this.matcher.push(&quot;return h.unique(n);\n}&quot;);
-    eval(this.matcher.join('\n'));
-    Selector._cache[this.expression] = this.matcher;
-  },
-
-  compileXPathMatcher: function() {
-    var e = this.expression, ps = Selector.patterns,
-        x = Selector.xpath, le, m;
-
-    if (Selector._cache[e]) {
-      this.xpath = Selector._cache[e]; return;
-    }
-
-    this.matcher = ['.//*'];
-    while (e &amp;&amp; le != e &amp;&amp; (/\S/).test(e)) {
-      le = e;
-      for (var i in ps) {
-        if (m = e.match(ps[i])) {
-          this.matcher.push(Object.isFunction(x[i]) ? x[i](m) :
-            new Template(x[i]).evaluate(m));
-          e = e.replace(m[0], '');
-          break;
-        }
-      }
-    }
-
-    this.xpath = this.matcher.join('');
-    Selector._cache[this.expression] = this.xpath;
-  },
-
-  findElements: function(root) {
-    root = root || document;
-    if (this.xpath) return document._getElementsByXPath(this.xpath, root);
-    return this.matcher(root);
-  },
-
-  match: function(element) {
-    this.tokens = [];
-
-    var e = this.expression, ps = Selector.patterns, as = Selector.assertions;
-    var le, p, m;
-
-    while (e &amp;&amp; le !== e &amp;&amp; (/\S/).test(e)) {
-      le = e;
-      for (var i in ps) {
-        p = ps[i];
-        if (m = e.match(p)) {
-          // use the Selector.assertions methods unless the selector
-          // is too complex.
-          if (as[i]) {
-            this.tokens.push([i, Object.clone(m)]);
-            e = e.replace(m[0], '');
-          } else {
-            // reluctantly do a document-wide search
-            // and look for a match in the array
-            return this.findElements(document).include(element);
-          }
-        }
-      }
-    }
-
-    var match = true, name, matches;
-    for (var i = 0, token; token = this.tokens[i]; i++) {
-      name = token[0], matches = token[1];
-      if (!Selector.assertions[name](element, matches)) {
-        match = false; break;
-      }
-    }
-
-    return match;
-  },
-
-  toString: function() {
-    return this.expression;
-  },
-
-  inspect: function() {
-    return &quot;#&lt;Selector:&quot; + this.expression.inspect() + &quot;&gt;&quot;;
-  }
-});
-
-Object.extend(Selector, {
-  _cache: { },
-
-  xpath: {
-    descendant:   &quot;//*&quot;,
-    child:        &quot;/*&quot;,
-    adjacent:     &quot;/following-sibling::*[1]&quot;,
-    laterSibling: '/following-sibling::*',
-    tagName:      function(m) {
-      if (m[1] == '*') return '';
-      return &quot;[local-name()='&quot; + m[1].toLowerCase() +
-             &quot;' or local-name()='&quot; + m[1].toUpperCase() + &quot;']&quot;;
-    },
-    className:    &quot;[contains(concat(' ', @class, ' '), ' #{1} ')]&quot;,
-    id:           &quot;[@id='#{1}']&quot;,
-    attrPresence: function(m) {
-      m[1] = m[1].toLowerCase();
-      return new Template(&quot;[@#{1}]&quot;).evaluate(m);
-    },
-    attr: function(m) {
-      m[1] = m[1].toLowerCase();
-      m[3] = m[5] || m[6];
-      return new Template(Selector.xpath.operators[m[2]]).evaluate(m);
-    },
-    pseudo: function(m) {
-      var h = Selector.xpath.pseudos[m[1]];
-      if (!h) return '';
-      if (Object.isFunction(h)) return h(m);
-      return new Template(Selector.xpath.pseudos[m[1]]).evaluate(m);
-    },
-    operators: {
-      '=':  &quot;[@#{1}='#{3}']&quot;,
-      '!=': &quot;[@#{1}!='#{3}']&quot;,
-      '^=': &quot;[starts-with(@#{1}, '#{3}')]&quot;,
-      '$=': &quot;[substring(@#{1}, (string-length(@#{1}) - string-length('#{3}') + 1))='#{3}']&quot;,
-      '*=': &quot;[contains(@#{1}, '#{3}')]&quot;,
-      '~=': &quot;[contains(concat(' ', @#{1}, ' '), ' #{3} ')]&quot;,
-      '|=': &quot;[contains(concat('-', @#{1}, '-'), '-#{3}-')]&quot;
-    },
-    pseudos: {
-      'first-child': '[not(preceding-sibling::*)]',
-      'last-child':  '[not(following-sibling::*)]',
-      'only-child':  '[not(preceding-sibling::* or following-sibling::*)]',
-      'empty':       &quot;[count(*) = 0 and (count(text()) = 0 or translate(text(), ' \t\r\n', '') = '')]&quot;,
-      'checked':     &quot;[@checked]&quot;,
-      'disabled':    &quot;[@disabled]&quot;,
-      'enabled':     &quot;[not(@disabled)]&quot;,
-      'not': function(m) {
-        var e = m[6], p = Selector.patterns,
-            x = Selector.xpath, le, v;
-
-        var exclusion = [];
-        while (e &amp;&amp; le != e &amp;&amp; (/\S/).test(e)) {
-          le = e;
-          for (var i in p) {
-            if (m = e.match(p[i])) {
-              v = Object.isFunction(x[i]) ? x[i](m) : new Template(x[i]).evaluate(m);
-              exclusion.push(&quot;(&quot; + v.substring(1, v.length - 1) + &quot;)&quot;);
-              e = e.replace(m[0], '');
-              break;
-            }
-          }
-        }
-        return &quot;[not(&quot; + exclusion.join(&quot; and &quot;) + &quot;)]&quot;;
-      },
-      'nth-child':      function(m) {
-        return Selector.xpath.pseudos.nth(&quot;(count(./preceding-sibling::*) + 1) &quot;, m);
-      },
-      'nth-last-child': function(m) {
-        return Selector.xpath.pseudos.nth(&quot;(count(./following-sibling::*) + 1) &quot;, m);
-      },
-      'nth-of-type':    function(m) {
-        return Selector.xpath.pseudos.nth(&quot;position() &quot;, m);
-      },
-      'nth-last-of-type': function(m) {
-        return Selector.xpath.pseudos.nth(&quot;(last() + 1 - position()) &quot;, m);
-      },
-      'first-of-type':  function(m) {
-        m[6] = &quot;1&quot;; return Selector.xpath.pseudos['nth-of-type'](m);
-      },
-      'last-of-type':   function(m) {
-        m[6] = &quot;1&quot;; return Selector.xpath.pseudos['nth-last-of-type'](m);
-      },
-      'only-of-type':   function(m) {
-        var p = Selector.xpath.pseudos; return p['first-of-type'](m) + p['last-of-type'](m);
-      },
-      nth: function(fragment, m) {
-        var mm, formula = m[6], predicate;
-        if (formula == 'even') formula = '2n+0';
-        if (formula == 'odd')  formula = '2n+1';
-        if (mm = formula.match(/^(\d+)$/)) // digit only
-          return '[' + fragment + &quot;= &quot; + mm[1] + ']';
-        if (mm = formula.match(/^(-?\d*)?n(([+-])(\d+))?/)) { // an+b
-          if (mm[1] == &quot;-&quot;) mm[1] = -1;
-          var a = mm[1] ? Number(mm[1]) : 1;
-          var b = mm[2] ? Number(mm[2]) : 0;
-          predicate = &quot;[((#{fragment} - #{b}) mod #{a} = 0) and &quot; +
-          &quot;((#{fragment} - #{b}) div #{a} &gt;= 0)]&quot;;
-          return new Template(predicate).evaluate({
-            fragment: fragment, a: a, b: b });
-        }
-      }
-    }
-  },
-
-  criteria: {
-    tagName:      'n = h.tagName(n, r, &quot;#{1}&quot;, c);      c = false;',
-    className:    'n = h.className(n, r, &quot;#{1}&quot;, c);    c = false;',
-    id:           'n = h.id(n, r, &quot;#{1}&quot;, c);           c = false;',
-    attrPresence: 'n = h.attrPresence(n, r, &quot;#{1}&quot;, c); c = false;',
-    attr: function(m) {
-      m[3] = (m[5] || m[6]);
-      return new Template('n = h.attr(n, r, &quot;#{1}&quot;, &quot;#{3}&quot;, &quot;#{2}&quot;, c); c = false;').evaluate(m);
-    },
-    pseudo: function(m) {
-      if (m[6]) m[6] = m[6].replace(/&quot;/g, '\\&quot;');
-      return new Template('n = h.pseudo(n, &quot;#{1}&quot;, &quot;#{6}&quot;, r, c); c = false;').evaluate(m);
-    },
-    descendant:   'c = &quot;descendant&quot;;',
-    child:        'c = &quot;child&quot;;',
-    adjacent:     'c = &quot;adjacent&quot;;',
-    laterSibling: 'c = &quot;laterSibling&quot;;'
-  },
-
-  patterns: {
-    // combinators must be listed first
-    // (and descendant needs to be last combinator)
-    laterSibling: /^\s*~\s*/,
-    child:        /^\s*&gt;\s*/,
-    adjacent:     /^\s*\+\s*/,
-    descendant:   /^\s/,
-
-    // selectors follow
-    tagName:      /^\s*(\*|[\w\-]+)(\b|$)?/,
-    id:           /^#([\w\-\*]+)(\b|$)/,
-    className:    /^\.([\w\-\*]+)(\b|$)/,
-    pseudo:
-/^:((first|last|nth|nth-last|only)(-child|-of-type)|empty|checked|(en|dis)abled|not)(\((.*?)\))?(\b|$|(?=\s|[:+~&gt;]))/,
-    attrPresence: /^\[([\w]+)\]/,
-    attr:         /\[((?:[\w-]*:)?[\w-]+)\s*(?:([!^$*~|]?=)\s*((['&quot;])([^\4]*?)\4|([^'&quot;][^\]]*?)))?\]/
-  },
-
-  // for Selector.match and Element#match
-  assertions: {
-    tagName: function(element, matches) {
-      return matches[1].toUpperCase() == element.tagName.toUpperCase();
-    },
-
-    className: function(element, matches) {
-      return Element.hasClassName(element, matches[1]);
-    },
-
-    id: function(element, matches) {
-      return element.id === matches[1];
-    },
-
-    attrPresence: function(element, matches) {
-      return Element.hasAttribute(element, matches[1]);
-    },
-
-    attr: function(element, matches) {
-      var nodeValue = Element.readAttribute(element, matches[1]);
-      return nodeValue &amp;&amp; Selector.operators[matches[2]](nodeValue, matches[5] || matches[6]);
-    }
-  },
-
-  handlers: {
-    // UTILITY FUNCTIONS
-    // joins two collections
-    concat: function(a, b) {
-      for (var i = 0, node; node = b[i]; i++)
-        a.push(node);
-      return a;
-    },
-
-    // marks an array of nodes for counting
-    mark: function(nodes) {
-      var _true = Prototype.emptyFunction;
-      for (var i = 0, node; node = nodes[i]; i++)
-        node._countedByPrototype = _true;
-      return nodes;
-    },
-
-    unmark: function(nodes) {
-      for (var i = 0, node; node = nodes[i]; i++)
-        node._countedByPrototype = undefined;
-      return nodes;
-    },
-
-    // mark each child node with its position (for nth calls)
-    // &quot;ofType&quot; flag indicates whether we're indexing for nth-of-type
-    // rather than nth-child
-    index: function(parentNode, reverse, ofType) {
-      parentNode._countedByPrototype = Prototype.emptyFunction;
-      if (reverse) {
-        for (var nodes = parentNode.childNodes, i = nodes.length - 1, j = 1; i &gt;= 0; i--) {
-          var node = nodes[i];
-          if (node.nodeType == 1 &amp;&amp; (!ofType || node._countedByPrototype)) node.nodeIndex = j++;
-        }
-      } else {
-        for (var i = 0, j = 1, nodes = parentNode.childNodes; node = nodes[i]; i++)
-          if (node.nodeType == 1 &amp;&amp; (!ofType || node._countedByPrototype)) node.nodeIndex = j++;
-      }
-    },
-
-    // filters out duplicates and extends all nodes
-    unique: function(nodes) {
-      if (nodes.length == 0) return nodes;
-      var results = [], n;
-      for (var i = 0, l = nodes.length; i &lt; l; i++)
-        if (!(n = nodes[i])._countedByPrototype) {
-          n._countedByPrototype = Prototype.emptyFunction;
-          results.push(Element.extend(n));
-        }
-      return Selector.handlers.unmark(results);
-    },
-
-    // COMBINATOR FUNCTIONS
-    descendant: function(nodes) {
-      var h = Selector.handlers;
-      for (var i = 0, results = [], node; node = nodes[i]; i++)
-        h.concat(results, node.getElementsByTagName('*'));
-      return results;
-    },
-
-    child: function(nodes) {
-      var h = Selector.handlers;
-      for (var i = 0, results = [], node; node = nodes[i]; i++) {
-        for (var j = 0, child; child = node.childNodes[j]; j++)
-          if (child.nodeType == 1 &amp;&amp; child.tagName != '!') results.push(child);
-      }
-      return results;
-    },
-
-    adjacent: function(nodes) {
-      for (var i = 0, results = [], node; node = nodes[i]; i++) {
-        var next = this.nextElementSibling(node);
-        if (next) results.push(next);
-      }
-      return results;
-    },
-
-    laterSibling: function(nodes) {
-      var h = Selector.handlers;
-      for (var i = 0, results = [], node; node = nodes[i]; i++)
-        h.concat(results, Element.nextSiblings(node));
-      return results;
-    },
-
-    nextElementSibling: function(node) {
-      while (node = node.nextSibling)
-	      if (node.nodeType == 1) return node;
-      return null;
-    },
-
-    previousElementSibling: function(node) {
-      while (node = node.previousSibling)
-        if (node.nodeType == 1) return node;
-      return null;
-    },
-
-    // TOKEN FUNCTIONS
-    tagName: function(nodes, root, tagName, combinator) {
-      var uTagName = tagName.toUpperCase();
-      var results = [], h = Selector.handlers;
-      if (nodes) {
-        if (combinator) {
-          // fastlane for ordinary descendant combinators
-          if (combinator == &quot;descendant&quot;) {
-            for (var i = 0, node; node = nodes[i]; i++)
-              h.concat(results, node.getElementsByTagName(tagName));
-            return results;
-          } else nodes = this[combinator](nodes);
-          if (tagName == &quot;*&quot;) return nodes;
-        }
-        for (var i = 0, node; node = nodes[i]; i++)
-          if (node.tagName.toUpperCase() === uTagName) results.push(node);
-        return results;
-      } else return root.getElementsByTagName(tagName);
-    },
-
-    id: function(nodes, root, id, combinator) {
-      var targetNode = $(id), h = Selector.handlers;
-      if (!targetNode) return [];
-      if (!nodes &amp;&amp; root == document) return [targetNode];
-      if (nodes) {
-        if (combinator) {
-          if (combinator == 'child') {
-            for (var i = 0, node; node = nodes[i]; i++)
-              if (targetNode.parentNode == node) return [targetNode];
-          } else if (combinator == 'descendant') {
-            for (var i = 0, node; node = nodes[i]; i++)
-              if (Element.descendantOf(targetNode, node)) return [targetNode];
-          } else if (combinator == 'adjacent') {
-            for (var i = 0, node; node = nodes[i]; i++)
-              if (Selector.handlers.previousElementSibling(targetNode) == node)
-                return [targetNode];
-          } else nodes = h[combinator](nodes);
-        }
-        for (var i = 0, node; node = nodes[i]; i++)
-          if (node == targetNode) return [targetNode];
-        return [];
-      }
-      return (targetNode &amp;&amp; Element.descendantOf(targetNode, root)) ? [targetNode] : [];
-    },
-
-    className: function(nodes, root, className, combinator) {
-      if (nodes &amp;&amp; combinator) nodes = this[combinator](nodes);
-      return Selector.handlers.byClassName(nodes, root, className);
-    },
-
-    byClassName: function(nodes, root, className) {
-      if (!nodes) nodes = Selector.handlers.descendant([root]);
-      var needle = ' ' + className + ' ';
-      for (var i = 0, results = [], node, nodeClassName; node = nodes[i]; i++) {
-        nodeClassName = node.className;
-        if (nodeClassName.length == 0) continue;
-        if (nodeClassName == className || (' ' + nodeClassName + ' ').include(needle))
-          results.push(node);
-      }
-      return results;
-    },
-
-    attrPresence: function(nodes, root, attr, combinator) {
-      if (!nodes) nodes = root.getElementsByTagName(&quot;*&quot;);
-      if (nodes &amp;&amp; combinator) nodes = this[combinator](nodes);
-      var results = [];
-      for (var i = 0, node; node = nodes[i]; i++)
-        if (Element.hasAttribute(node, attr)) results.push(node);
-      return results;
-    },
-
-    attr: function(nodes, root, attr, value, operator, combinator) {
-      if (!nodes) nodes = root.getElementsByTagName(&quot;*&quot;);
-      if (nodes &amp;&amp; combinator) nodes = this[combinator](nodes);
-      var handler = Selector.operators[operator], results = [];
-      for (var i = 0, node; node = nodes[i]; i++) {
-        var nodeValue = Element.readAttribute(node, attr);
-        if (nodeValue === null) continue;
-        if (handler(nodeValue, value)) results.push(node);
-      }
-      return results;
-    },
-
-    pseudo: function(nodes, name, value, root, combinator) {
-      if (nodes &amp;&amp; combinator) nodes = this[combinator](nodes);
-      if (!nodes) nodes = root.getElementsByTagName(&quot;*&quot;);
-      return Selector.pseudos[name](nodes, value, root);
-    }
-  },
-
-  pseudos: {
-    'first-child': function(nodes, value, root) {
-      for (var i = 0, results = [], node; node = nodes[i]; i++) {
-        if (Selector.handlers.previousElementSibling(node)) continue;
-          results.push(node);
-      }
-      return results;
-    },
-    'last-child': function(nodes, value, root) {
-      for (var i = 0, results = [], node; node = nodes[i]; i++) {
-        if (Selector.handlers.nextElementSibling(node)) continue;
-          results.push(node);
-      }
-      return results;
-    },
-    'only-child': function(nodes, value, root) {
-      var h = Selector.handlers;
-      for (var i = 0, results = [], node; node = nodes[i]; i++)
-        if (!h.previousElementSibling(node) &amp;&amp; !h.nextElementSibling(node))
-          results.push(node);
-      return results;
-    },
-    'nth-child':        function(nodes, formula, root) {
-      return Selector.pseudos.nth(nodes, formula, root);
-    },
-    'nth-last-child':   function(nodes, formula, root) {
-      return Selector.pseudos.nth(nodes, formula, root, true);
-    },
-    'nth-of-type':      function(nodes, formula, root) {
-      return Selector.pseudos.nth(nodes, formula, root, false, true);
-    },
-    'nth-last-of-type': function(nodes, formula, root) {
-      return Selector.pseudos.nth(nodes, formula, root, true, true);
-    },
-    'first-of-type':    function(nodes, formula, root) {
-      return Selector.pseudos.nth(nodes, &quot;1&quot;, root, false, true);
-    },
-    'last-of-type':     function(nodes, formula, root) {
-      return Selector.pseudos.nth(nodes, &quot;1&quot;, root, true, true);
-    },
-    'only-of-type':     function(nodes, formula, root) {
-      var p = Selector.pseudos;
-      return p['last-of-type'](p['first-of-type'](nodes, formula, root), formula, root);
-    },
-
-    // handles the an+b logic
-    getIndices: function(a, b, total) {
-      if (a == 0) return b &gt; 0 ? [b] : [];
-      return $R(1, total).inject([], function(memo, i) {
-        if (0 == (i - b) % a &amp;&amp; (i - b) / a &gt;= 0) memo.push(i);
-        return memo;
-      });
-    },
-
-    // handles nth(-last)-child, nth(-last)-of-type, and (first|last)-of-type
-    nth: function(nodes, formula, root, reverse, ofType) {
-      if (nodes.length == 0) return [];
-      if (formula == 'even') formula = '2n+0';
-      if (formula == 'odd')  formula = '2n+1';
-      var h = Selector.handlers, results = [], indexed = [], m;
-      h.mark(nodes);
-      for (var i = 0, node; node = nodes[i]; i++) {
-        if (!node.parentNode._countedByPrototype) {
-          h.index(node.parentNode, reverse, ofType);
-          indexed.push(node.parentNode);
-        }
-      }
-      if (formula.match(/^\d+$/)) { // just a number
-        formula = Number(formula);
-        for (var i = 0, node; node = nodes[i]; i++)
-          if (node.nodeIndex == formula) results.push(node);
-      } else if (m = formula.match(/^(-?\d*)?n(([+-])(\d+))?/)) { // an+b
-        if (m[1] == &quot;-&quot;) m[1] = -1;
-        var a = m[1] ? Number(m[1]) : 1;
-        var b = m[2] ? Number(m[2]) : 0;
-        var indices = Selector.pseudos.getIndices(a, b, nodes.length);
-        for (var i = 0, node, l = indices.length; node = nodes[i]; i++) {
-          for (var j = 0; j &lt; l; j++)
-            if (node.nodeIndex == indices[j]) results.push(node);
-        }
-      }
-      h.unmark(nodes);
-      h.unmark(indexed);
-      return results;
-    },
-
-    'empty': function(nodes, value, root) {
-      for (var i = 0, results = [], node; node = nodes[i]; i++) {
-        // IE treats comments as element nodes
-        if (node.tagName == '!' || (node.firstChild &amp;&amp; !node.innerHTML.match(/^\s*$/))) continue;
-        results.push(node);
-      }
-      return results;
-    },
-
-    'not': function(nodes, selector, root) {
-      var h = Selector.handlers, selectorType, m;
-      var exclusions = new Selector(selector).findElements(root);
-      h.mark(exclusions);
-      for (var i = 0, results = [], node; node = nodes[i]; i++)
-        if (!node._countedByPrototype) results.push(node);
-      h.unmark(exclusions);
-      return results;
-    },
-
-    'enabled': function(nodes, value, root) {
-      for (var i = 0, results = [], node; node = nodes[i]; i++)
-        if (!node.disabled) results.push(node);
-      return results;
-    },
-
-    'disabled': function(nodes, value, root) {
-      for (var i = 0, results = [], node; node = nodes[i]; i++)
-        if (node.disabled) results.push(node);
-      return results;
-    },
-
-    'checked': function(nodes, value, root) {
-      for (var i = 0, results = [], node; node = nodes[i]; i++)
-        if (node.checked) results.push(node);
-      return results;
-    }
-  },
-
-  operators: {
-    '=':  function(nv, v) { return nv == v; },
-    '!=': function(nv, v) { return nv != v; },
-    '^=': function(nv, v) { return nv.startsWith(v); },
-    '$=': function(nv, v) { return nv.endsWith(v); },
-    '*=': function(nv, v) { return nv.include(v); },
-    '~=': function(nv, v) { return (' ' + nv + ' ').include(' ' + v + ' '); },
-    '|=': function(nv, v) { return ('-' + nv.toUpperCase() + '-').include('-' + v.toUpperCase() + '-'); }
-  },
-
-  split: function(expression) {
-    var expressions = [];
-    expression.scan(/(([\w#:.~&gt;+()\s-]+|\*|\[.*?\])+)\s*(,|$)/, function(m) {
-      expressions.push(m[1].strip());
-    });
-    return expressions;
-  },
-
-  matchElements: function(elements, expression) {
-    var matches = $$(expression), h = Selector.handlers;
-    h.mark(matches);
-    for (var i = 0, results = [], element; element = elements[i]; i++)
-      if (element._countedByPrototype) results.push(element);
-    h.unmark(matches);
-    return results;
-  },
-
-  findElement: function(elements, expression, index) {
-    if (Object.isNumber(expression)) {
-      index = expression; expression = false;
-    }
-    return Selector.matchElements(elements, expression || '*')[index || 0];
-  },
-
-  findChildElements: function(element, expressions) {
-    expressions = Selector.split(expressions.join(','));
-    var results = [], h = Selector.handlers;
-    for (var i = 0, l = expressions.length, selector; i &lt; l; i++) {
-      selector = new Selector(expressions[i].strip());
-      h.concat(results, selector.findElements(element));
-    }
-    return (l &gt; 1) ? h.unique(results) : results;
-  }
-});
-
-if (Prototype.Browser.IE) {
-  Object.extend(Selector.handlers, {
-    // IE returns comment nodes on getElementsByTagName(&quot;*&quot;).
-    // Filter them out.
-    concat: function(a, b) {
-      for (var i = 0, node; node = b[i]; i++)
-        if (node.tagName !== &quot;!&quot;) a.push(node);
-      return a;
-    },
-
-    // IE improperly serializes _countedByPrototype in (inner|outer)HTML.
-    unmark: function(nodes) {
-      for (var i = 0, node; node = nodes[i]; i++)
-        node.removeAttribute('_countedByPrototype');
-      return nodes;
-    }
-  });
-}
-
-function $$() {
-  return Selector.findChildElements(document, $A(arguments));
-}
-var Form = {
-  reset: function(form) {
-    $(form).reset();
-    return form;
-  },
-
-  serializeElements: function(elements, options) {
-    if (typeof options != 'object') options = { hash: !!options };
-    else if (Object.isUndefined(options.hash)) options.hash = true;
-    var key, value, submitted = false, submit = options.submit;
-
-    var data = elements.inject({ }, function(result, element) {
-      if (!element.disabled &amp;&amp; element.name) {
-        key = element.name; value = $(element).getValue();
-        if (value != null &amp;&amp; (element.type != 'submit' || (!submitted &amp;&amp;
-            submit !== false &amp;&amp; (!submit || key == submit) &amp;&amp; (submitted = true)))) {
-          if (key in result) {
-            // a key is already present; construct an array of values
-            if (!Object.isArray(result[key])) result[key] = [result[key]];
-            result[key].push(value);
-          }
-          else result[key] = value;
-        }
-      }
-      return result;
-    });
-
-    return options.hash ? data : Object.toQueryString(data);
-  }
-};
-
-Form.Methods = {
-  serialize: function(form, options) {
-    return Form.serializeElements(Form.getElements(form), options);
-  },
-
-  getElements: function(form) {
-    return $A($(form).getElementsByTagName('*')).inject([],
-      function(elements, child) {
-        if (Form.Element.Serializers[child.tagName.toLowerCase()])
-          elements.push(Element.extend(child));
-        return elements;
-      }
-    );
-  },
-
-  getInputs: function(form, typeName, name) {
-    form = $(form);
-    var inputs = form.getElementsByTagName('input');
-
-    if (!typeName &amp;&amp; !name) return $A(inputs).map(Element.extend);
-
-    for (var i = 0, matchingInputs = [], length = inputs.length; i &lt; length; i++) {
-      var input = inputs[i];
-      if ((typeName &amp;&amp; input.type != typeName) || (name &amp;&amp; input.name != name))
-        continue;
-      matchingInputs.push(Element.extend(input));
-    }
-
-    return matchingInputs;
-  },
-
-  disable: function(form) {
-    form = $(form);
-    Form.getElements(form).invoke('disable');
-    return form;
-  },
-
-  enable: function(form) {
-    form = $(form);
-    Form.getElements(form).invoke('enable');
-    return form;
-  },
-
-  findFirstElement: function(form) {
-    var elements = $(form).getElements().findAll(function(element) {
-      return 'hidden' != element.type &amp;&amp; !element.disabled;
-    });
-    var firstByIndex = elements.findAll(function(element) {
-      return element.hasAttribute('tabIndex') &amp;&amp; element.tabIndex &gt;= 0;
-    }).sortBy(function(element) { return element.tabIndex }).first();
-
-    return firstByIndex ? firstByIndex : elements.find(function(element) {
-      return ['input', 'select', 'textarea'].include(element.tagName.toLowerCase());
-    });
-  },
-
-  focusFirstElement: function(form) {
-    form = $(form);
-    form.findFirstElement().activate();
-    return form;
-  },
-
-  request: function(form, options) {
-    form = $(form), options = Object.clone(options || { });
-
-    var params = options.parameters, action = form.readAttribute('action') || '';
-    if (action.blank()) action = window.location.href;
-    options.parameters = form.serialize(true);
-
-    if (params) {
-      if (Object.isString(params)) params = params.toQueryParams();
-      Object.extend(options.parameters, params);
-    }
-
-    if (form.hasAttribute('method') &amp;&amp; !options.method)
-      options.method = form.method;
-
-    return new Ajax.Request(action, options);
-  }
-};
-
-/*--------------------------------------------------------------------------*/
-
-Form.Element = {
-  focus: function(element) {
-    $(element).focus();
-    return element;
-  },
-
-  select: function(element) {
-    $(element).select();
-    return element;
-  }
-};
-
-Form.Element.Methods = {
-  serialize: function(element) {
-    element = $(element);
-    if (!element.disabled &amp;&amp; element.name) {
-      var value = element.getValue();
-      if (value != undefined) {
-        var pair = { };
-        pair[element.name] = value;
-        return Object.toQueryString(pair);
-      }
-    }
-    return '';
-  },
-
-  getValue: function(element) {
-    element = $(element);
-    var method = element.tagName.toLowerCase();
-    return Form.Element.Serializers[method](element);
-  },
-
-  setValue: function(element, value) {
-    element = $(element);
-    var method = element.tagName.toLowerCase();
-    Form.Element.Serializers[method](element, value);
-    return element;
-  },
-
-  clear: function(element) {
-    $(element).value = '';
-    return element;
-  },
-
-  present: function(element) {
-    return $(element).value != '';
-  },
-
-  activate: function(element) {
-    element = $(element);
-    try {
-      element.focus();
-      if (element.select &amp;&amp; (element.tagName.toLowerCase() != 'input' ||
-          !['button', 'reset', 'submit'].include(element.type)))
-        element.select();
-    } catch (e) { }
-    return element;
-  },
-
-  disable: function(element) {
-    element = $(element);
-    element.blur();
-    element.disabled = true;
-    return element;
-  },
-
-  enable: function(element) {
-    element = $(element);
-    element.disabled = false;
-    return element;
-  }
-};
-
-/*--------------------------------------------------------------------------*/
-
-var Field = Form.Element;
-var $F = Form.Element.Methods.getValue;
-
-/*--------------------------------------------------------------------------*/
-
-Form.Element.Serializers = {
-  input: function(element, value) {
-    switch (element.type.toLowerCase()) {
-      case 'checkbox':
-      case 'radio':
-        return Form.Element.Serializers.inputSelector(element, value);
-      default:
-        return Form.Element.Serializers.textarea(element, value);
-    }
-  },
-
-  inputSelector: function(element, value) {
-    if (Object.isUndefined(value)) return element.checked ? element.value : null;
-    else element.checked = !!value;
-  },
-
-  textarea: function(element, value) {
-    if (Object.isUndefined(value)) return element.value;
-    else element.value = value;
-  },
-
-  select: function(element, index) {
-    if (Object.isUndefined(index))
-      return this[element.type == 'select-one' ?
-        'selectOne' : 'selectMany'](element);
-    else {
-      var opt, value, single = !Object.isArray(index);
-      for (var i = 0, length = element.length; i &lt; length; i++) {
-        opt = element.options[i];
-        value = this.optionValue(opt);
-        if (single) {
-          if (value == index) {
-            opt.selected = true;
-            return;
-          }
-        }
-        else opt.selected = index.include(value);
-      }
-    }
-  },
-
-  selectOne: function(element) {
-    var index = element.selectedIndex;
-    return index &gt;= 0 ? this.optionValue(element.options[index]) : null;
-  },
-
-  selectMany: function(element) {
-    var values, length = element.length;
-    if (!length) return null;
-
-    for (var i = 0, values = []; i &lt; length; i++) {
-      var opt = element.options[i];
-      if (opt.selected) values.push(this.optionValue(opt));
-    }
-    return values;
-  },
-
-  optionValue: function(opt) {
-    // extend element because hasAttribute may not be native
-    return Element.extend(opt).hasAttribute('value') ? opt.value : opt.text;
-  }
-};
-
-/*--------------------------------------------------------------------------*/
-
-Abstract.TimedObserver = Class.create(PeriodicalExecuter, {
-  initialize: function($super, element, frequency, callback) {
-    $super(callback, frequency);
-    this.element   = $(element);
-    this.lastValue = this.getValue();
-  },
-
-  execute: function() {
-    var value = this.getValue();
-    if (Object.isString(this.lastValue) &amp;&amp; Object.isString(value) ?
-        this.lastValue != value : String(this.lastValue) != String(value)) {
-      this.callback(this.element, value);
-      this.lastValue = value;
-    }
-  }
-});
-
-Form.Element.Observer = Class.create(Abstract.TimedObserver, {
-  getValue: function() {
-    return Form.Element.getValue(this.element);
-  }
-});
-
-Form.Observer = Class.create(Abstract.TimedObserver, {
-  getValue: function() {
-    return Form.serialize(this.element);
-  }
-});
-
-/*--------------------------------------------------------------------------*/
-
-Abstract.EventObserver = Class.create({
-  initialize: function(element, callback) {
-    this.element  = $(element);
-    this.callback = callback;
-
-    this.lastValue = this.getValue();
-    if (this.element.tagName.toLowerCase() == 'form')
-      this.registerFormCallbacks();
-    else
-      this.registerCallback(this.element);
-  },
-
-  onElementEvent: function() {
-    var value = this.getValue();
-    if (this.lastValue != value) {
-      this.callback(this.element, value);
-      this.lastValue = value;
-    }
-  },
-
-  registerFormCallbacks: function() {
-    Form.getElements(this.element).each(this.registerCallback, this);
-  },
-
-  registerCallback: function(element) {
-    if (element.type) {
-      switch (element.type.toLowerCase()) {
-        case 'checkbox':
-        case 'radio':
-          Event.observe(element, 'click', this.onElementEvent.bind(this));
-          break;
-        default:
-          Event.observe(element, 'change', this.onElementEvent.bind(this));
-          break;
-      }
-    }
-  }
-});
-
-Form.Element.EventObserver = Class.create(Abstract.EventObserver, {
-  getValue: function() {
-    return Form.Element.getValue(this.element);
-  }
-});
-
-Form.EventObserver = Class.create(Abstract.EventObserver, {
-  getValue: function() {
-    return Form.serialize(this.element);
-  }
-});
-if (!window.Event) var Event = { };
-
-Object.extend(Event, {
-  KEY_BACKSPACE: 8,
-  KEY_TAB:       9,
-  KEY_RETURN:   13,
-  KEY_ESC:      27,
-  KEY_LEFT:     37,
-  KEY_UP:       38,
-  KEY_RIGHT:    39,
-  KEY_DOWN:     40,
-  KEY_DELETE:   46,
-  KEY_HOME:     36,
-  KEY_END:      35,
-  KEY_PAGEUP:   33,
-  KEY_PAGEDOWN: 34,
-  KEY_INSERT:   45,
-
-  cache: { },
-
-  relatedTarget: function(event) {
-    var element;
-    switch(event.type) {
-      case 'mouseover': element = event.fromElement; break;
-      case 'mouseout':  element = event.toElement;   break;
-      default: return null;
-    }
-    return Element.extend(element);
-  }
-});
-
-Event.Methods = (function() {
-  var isButton;
-
-  if (Prototype.Browser.IE) {
-    var buttonMap = { 0: 1, 1: 4, 2: 2 };
-    isButton = function(event, code) {
-      return event.button == buttonMap[code];
-    };
-
-  } else if (Prototype.Browser.WebKit) {
-    isButton = function(event, code) {
-      switch (code) {
-        case 0: return event.which == 1 &amp;&amp; !event.metaKey;
-        case 1: return event.which == 1 &amp;&amp; event.metaKey;
-        default: return false;
-      }
-    };
-
-  } else {
-    isButton = function(event, code) {
-      return event.which ? (event.which === code + 1) : (event.button === code);
-    };
-  }
-
-  return {
-    isLeftClick:   function(event) { return isButton(event, 0) },
-    isMiddleClick: function(event) { return isButton(event, 1) },
-    isRightClick:  function(event) { return isButton(event, 2) },
-
-    element: function(event) {
-      var node = Event.extend(event).target;
-      return Element.extend(node.nodeType == Node.TEXT_NODE ? node.parentNode : node);
-    },
-
-    findElement: function(event, expression) {
-      var element = Event.element(event);
-      if (!expression) return element;
-      var elements = [element].concat(element.ancestors());
-      return Selector.findElement(elements, expression, 0);
-    },
-
-    pointer: function(event) {
-      return {
-        x: event.pageX || (event.clientX +
-          (document.documentElement.scrollLeft || document.body.scrollLeft)),
-        y: event.pageY || (event.clientY +
-          (document.documentElement.scrollTop || document.body.scrollTop))
-      };
-    },
-
-    pointerX: function(event) { return Event.pointer(event).x },
-    pointerY: function(event) { return Event.pointer(event).y },
-
-    stop: function(event) {
-      Event.extend(event);
-      event.preventDefault();
-      event.stopPropagation();
-      event.stopped = true;
-    }
-  };
-})();
-
-Event.extend = (function() {
-  var methods = Object.keys(Event.Methods).inject({ }, function(m, name) {
-    m[name] = Event.Methods[name].methodize();
-    return m;
-  });
-
-  if (Prototype.Browser.IE) {
-    Object.extend(methods, {
-      stopPropagation: function() { this.cancelBubble = true },
-      preventDefault:  function() { this.returnValue = false },
-      inspect: function() { return &quot;[object Event]&quot; }
-    });
-
-    return function(event) {
-      if (!event) return false;
-      if (event._extendedByPrototype) return event;
-
-      event._extendedByPrototype = Prototype.emptyFunction;
-      var pointer = Event.pointer(event);
-      Object.extend(event, {
-        target: event.srcElement,
-        relatedTarget: Event.relatedTarget(event),
-        pageX:  pointer.x,
-        pageY:  pointer.y
-      });
-      return Object.extend(event, methods);
-    };
-
-  } else {
-    Event.prototype = Event.prototype || document.createEvent(&quot;HTMLEvents&quot;).__proto__;
-    Object.extend(Event.prototype, methods);
-    return Prototype.K;
-  }
-})();
-
-Object.extend(Event, (function() {
-  var cache = Event.cache;
-
-  function getEventID(element) {
-    if (element._prototypeEventID) return element._prototypeEventID[0];
-    arguments.callee.id = arguments.callee.id || 1;
-    return element._prototypeEventID = [++arguments.callee.id];
-  }
-
-  function getDOMEventName(eventName) {
-    if (eventName &amp;&amp; eventName.include(':')) return &quot;dataavailable&quot;;
-    return eventName;
-  }
-
-  function getCacheForID(id) {
-    return cache[id] = cache[id] || { };
-  }
-
-  function getWrappersForEventName(id, eventName) {
-    var c = getCacheForID(id);
-    return c[eventName] = c[eventName] || [];
-  }
-
-  function createWrapper(element, eventName, handler) {
-    var id = getEventID(element);
-    var c = getWrappersForEventName(id, eventName);
-    if (c.pluck(&quot;handler&quot;).include(handler)) return false;
-
-    var wrapper = function(event) {
-      if (!Event || !Event.extend ||
-        (event.eventName &amp;&amp; event.eventName != eventName))
-          return false;
-
-      Event.extend(event);
-      handler.call(element, event);
-    };
-
-    wrapper.handler = handler;
-    c.push(wrapper);
-    return wrapper;
-  }
-
-  function findWrapper(id, eventName, handler) {
-    var c = getWrappersForEventName(id, eventName);
-    return c.find(function(wrapper) { return wrapper.handler == handler });
-  }
-
-  function destroyWrapper(id, eventName, handler) {
-    var c = getCacheForID(id);
-    if (!c[eventName]) return false;
-    c[eventName] = c[eventName].without(findWrapper(id, eventName, handler));
-  }
-
-  function destroyCache() {
-    for (var id in cache)
-      for (var eventName in cache[id])
-        cache[id][eventName] = null;
-  }
-
-  if (window.attachEvent) {
-    window.attachEvent(&quot;onunload&quot;, destroyCache);
-  }
-
-  return {
-    observe: function(element, eventName, handler) {
-      element = $(element);
-      var name = getDOMEventName(eventName);
-
-      var wrapper = createWrapper(element, eventName, handler);
-      if (!wrapper) return element;
-
-      if (element.addEventListener) {
-        element.addEventListener(name, wrapper, false);
-      } else {
-        element.attachEvent(&quot;on&quot; + name, wrapper);
-      }
-
-      return element;
-    },
-
-    stopObserving: function(element, eventName, handler) {
-      element = $(element);
-      var id = getEventID(element), name = getDOMEventName(eventName);
-
-      if (!handler &amp;&amp; eventName) {
-        getWrappersForEventName(id, eventName).each(function(wrapper) {
-          element.stopObserving(eventName, wrapper.handler);
-        });
-        return element;
-
-      } else if (!eventName) {
-        Object.keys(getCacheForID(id)).each(function(eventName) {
-          element.stopObserving(eventName);
-        });
-        return element;
-      }
-
-      var wrapper = findWrapper(id, eventName, handler);
-      if (!wrapper) return element;
-
-      if (element.removeEventListener) {
-        element.removeEventListener(name, wrapper, false);
-      } else {
-        element.detachEvent(&quot;on&quot; + name, wrapper);
-      }
-
-      destroyWrapper(id, eventName, handler);
-
-      return element;
-    },
-
-    fire: function(element, eventName, memo) {
-      element = $(element);
-      if (element == document &amp;&amp; document.createEvent &amp;&amp; !element.dispatchEvent)
-        element = document.documentElement;
-
-      var event;
-      if (document.createEvent) {
-        event = document.createEvent(&quot;HTMLEvents&quot;);
-        event.initEvent(&quot;dataavailable&quot;, true, true);
-      } else {
-        event = document.createEventObject();
-        event.eventType = &quot;ondataavailable&quot;;
-      }
-
-      event.eventName = eventName;
-      event.memo = memo || { };
-
-      if (document.createEvent) {
-        element.dispatchEvent(event);
-      } else {
-        element.fireEvent(event.eventType, event);
-      }
-
-      return Event.extend(event);
-    }
-  };
-})());
-
-Object.extend(Event, Event.Methods);
-
-Element.addMethods({
-  fire:          Event.fire,
-  observe:       Event.observe,
-  stopObserving: Event.stopObserving
-});
-
-Object.extend(document, {
-  fire:          Element.Methods.fire.methodize(),
-  observe:       Element.Methods.observe.methodize(),
-  stopObserving: Element.Methods.stopObserving.methodize(),
-  loaded:        false
-});
-
-(function() {
-  /* Support for the DOMContentLoaded event is based on work by Dan Webb,
-     Matthias Miller, Dean Edwards and John Resig. */
-
-  var timer;
-
-  function fireContentLoadedEvent() {
-    if (document.loaded) return;
-    if (timer) window.clearInterval(timer);
-    document.fire(&quot;dom:loaded&quot;);
-    document.loaded = true;
-  }
-
-  if (document.addEventListener) {
-    if (Prototype.Browser.WebKit) {
-      timer = window.setInterval(function() {
-        if (/loaded|complete/.test(document.readyState))
-          fireContentLoadedEvent();
-      }, 0);
-
-      Event.observe(window, &quot;load&quot;, fireContentLoadedEvent);
-
-    } else {
-      document.addEventListener(&quot;DOMContentLoaded&quot;,
-        fireContentLoadedEvent, false);
-    }
-
-  } else {
-    document.write(&quot;&lt;script id=__onDOMContentLoaded defer src=//:&gt;&lt;\/script&gt;&quot;);
-    $(&quot;__onDOMContentLoaded&quot;).onreadystatechange = function() {
-      if (this.readyState == &quot;complete&quot;) {
-        this.onreadystatechange = null;
-        fireContentLoadedEvent();
-      }
-    };
-  }
-})();
-/*------------------------------- DEPRECATED -------------------------------*/
-
-Hash.toQueryString = Object.toQueryString;
-
-var Toggle = { display: Element.toggle };
-
-Element.Methods.childOf = Element.Methods.descendantOf;
-
-var Insertion = {
-  Before: function(element, content) {
-    return Element.insert(element, {before:content});
-  },
-
-  Top: function(element, content) {
-    return Element.insert(element, {top:content});
-  },
-
-  Bottom: function(element, content) {
-    return Element.insert(element, {bottom:content});
-  },
-
-  After: function(element, content) {
-    return Element.insert(element, {after:content});
-  }
-};
-
-var $continue = new Error('&quot;throw $continue&quot; is deprecated, use &quot;return&quot; instead');
-
-// This should be moved to script.aculo.us; notice the deprecated methods
-// further below, that map to the newer Element methods.
-var Position = {
-  // set to true if needed, warning: firefox performance problems
-  // NOT neeeded for page scrolling, only if draggable contained in
-  // scrollable elements
-  includeScrollOffsets: false,
-
-  // must be called before calling withinIncludingScrolloffset, every time the
-  // page is scrolled
-  prepare: function() {
-    this.deltaX =  window.pageXOffset
-                || document.documentElement.scrollLeft
-                || document.body.scrollLeft
-                || 0;
-    this.deltaY =  window.pageYOffset
-                || document.documentElement.scrollTop
-                || document.body.scrollTop
-                || 0;
-  },
-
-  // caches x/y coordinate pair to use with overlap
-  within: function(element, x, y) {
-    if (this.includeScrollOffsets)
-      return this.withinIncludingScrolloffsets(element, x, y);
-    this.xcomp = x;
-    this.ycomp = y;
-    this.offset = Element.cumulativeOffset(element);
-
-    return (y &gt;= this.offset[1] &amp;&amp;
-            y &lt;  this.offset[1] + element.offsetHeight &amp;&amp;
-            x &gt;= this.offset[0] &amp;&amp;
-            x &lt;  this.offset[0] + element.offsetWidth);
-  },
-
-  withinIncludingScrolloffsets: function(element, x, y) {
-    var offsetcache = Element.cumulativeScrollOffset(element);
-
-    this.xcomp = x + offsetcache[0] - this.deltaX;
-    this.ycomp = y + offsetcache[1] - this.deltaY;
-    this.offset = Element.cumulativeOffset(element);
-
-    return (this.ycomp &gt;= this.offset[1] &amp;&amp;
-            this.ycomp &lt;  this.offset[1] + element.offsetHeight &amp;&amp;
-            this.xcomp &gt;= this.offset[0] &amp;&amp;
-            this.xcomp &lt;  this.offset[0] + element.offsetWidth);
-  },
-
-  // within must be called directly before
-  overlap: function(mode, element) {
-    if (!mode) return 0;
-    if (mode == 'vertical')
-      return ((this.offset[1] + element.offsetHeight) - this.ycomp) /
-        element.offsetHeight;
-    if (mode == 'horizontal')
-      return ((this.offset[0] + element.offsetWidth) - this.xcomp) /
-        element.offsetWidth;
-  },
-
-  // Deprecation layer -- use newer Element methods now (1.5.2).
-
-  cumulativeOffset: Element.Methods.cumulativeOffset,
-
-  positionedOffset: Element.Methods.positionedOffset,
-
-  absolutize: function(element) {
-    Position.prepare();
-    return Element.absolutize(element);
-  },
-
-  relativize: function(element) {
-    Position.prepare();
-    return Element.relativize(element);
-  },
-
-  realOffset: Element.Methods.cumulativeScrollOffset,
-
-  offsetParent: Element.Methods.getOffsetParent,
-
-  page: Element.Methods.viewportOffset,
-
-  clone: function(source, target, options) {
-    options = options || { };
-    return Element.clonePosition(target, source, options);
-  }
-};
-
-/*--------------------------------------------------------------------------*/
-
-if (!document.getElementsByClassName) document.getElementsByClassName = function(instanceMethods){
-  function iter(name) {
-    return name.blank() ? null : &quot;[contains(concat(' ', @class, ' '), ' &quot; + name + &quot; ')]&quot;;
-  }
-
-  instanceMethods.getElementsByClassName = Prototype.BrowserFeatures.XPath ?
-  function(element, className) {
-    className = className.toString().strip();
-    var cond = /\s/.test(className) ? $w(className).map(iter).join('') : iter(className);
-    return cond ? document._getElementsByXPath('.//*' + cond, element) : [];
-  } : function(element, className) {
-    className = className.toString().strip();
-    var elements = [], classNames = (/\s/.test(className) ? $w(className) : null);
-    if (!classNames &amp;&amp; !className) return elements;
-
-    var nodes = $(element).getElementsByTagName('*');
-    className = ' ' + className + ' ';
-
-    for (var i = 0, child, cn; child = nodes[i]; i++) {
-      if (child.className &amp;&amp; (cn = ' ' + child.className + ' ') &amp;&amp; (cn.include(className) ||
-          (classNames &amp;&amp; classNames.all(function(name) {
-            return !name.toString().blank() &amp;&amp; cn.include(' ' + name + ' ');
-          }))))
-        elements.push(Element.extend(child));
-    }
-    return elements;
-  };
-
-  return function(className, parentElement) {
-    return $(parentElement || document.body).getElementsByClassName(className);
-  };
-}(Element.Methods);
-
-/*--------------------------------------------------------------------------*/
-
-Element.ClassNames = Class.create();
-Element.ClassNames.prototype = {
-  initialize: function(element) {
-    this.element = $(element);
-  },
-
-  _each: function(iterator) {
-    this.element.className.split(/\s+/).select(function(name) {
-      return name.length &gt; 0;
-    })._each(iterator);
-  },
-
-  set: function(className) {
-    this.element.className = className;
-  },
-
-  add: function(classNameToAdd) {
-    if (this.include(classNameToAdd)) return;
-    this.set($A(this).concat(classNameToAdd).join(' '));
-  },
-
-  remove: function(classNameToRemove) {
-    if (!this.include(classNameToRemove)) return;
-    this.set($A(this).without(classNameToRemove).join(' '));
-  },
-
-  toString: function() {
-    return $A(this).join(' ');
-  }
-};
-
-Object.extend(Element.ClassNames.prototype, Enumerable);
-
-/*--------------------------------------------------------------------------*/
-
-Element.addMethods();
\ No newline at end of file
+var Prototype={Version:&quot;1.6.0.2&quot;,Browser:{IE:!!(window.attachEvent&amp;&amp;!window.opera),Opera:!!window.opera,WebKit:navigator.userAgent.indexOf(&quot;AppleWebKit/&quot;)&gt;-1,Gecko:navigator.userAgent.indexOf(&quot;Gecko&quot;)&gt;-1&amp;&amp;navigator.userAgent.indexOf(&quot;KHTML&quot;)==-1,MobileSafari:!!navigator.userAgent.match(/Apple.*Mobile.*Safari/)},BrowserFeatures:{XPath:!!document.evaluate,ElementExtensions:!!window.HTMLElement,SpecificElementExtensions:document.createElement(&quot;div&quot;).__proto__&amp;&amp;document.createElement(&quot;div&quot;).__proto__!==document.createElement(&quot;form&quot;).__proto__},ScriptFragment:&quot;&lt;script[^&gt;]*&gt;([\\S\\s]*?)&lt;\/script&gt;&quot;,JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(b){return b}};if(Prototype.Browser.MobileSafari){Prototype.BrowserFeatures.SpecificElementExtensions=false}var Class={create:function(){var h=null,i=$A(arguments);if(Object.isFunction(i[0])){h=i.shift()}function g(){this.initialize.apply(this,arguments)}Object.extend(g,Class.Methods);g.superclass=h;g.subclasses=[];if(h){var f=function(){};f.prototype=h.prototype;g.prototype=new f;h.subclasses.push(g)}for(var j=0;j&lt;i.length;j++){g.addMethods(i[j])}if(!g.prototype.initialize){g.prototype.initialize=Prototype.emptyFunction}g.prototype.constructor=g;return g}};Class.Methods={addMethods:function(l){var p=this.superclass&amp;&amp;this.superclass.prototype;var i=Object.keys(l);if(!Object.keys({toString:true}).length){i.push(&quot;toString&quot;,&quot;valueOf&quot;)}for(var j=0,o=i.length;j&lt;o;j++){var m=i[j],n=l[m];if(p&amp;&amp;Object.isFunction(n)&amp;&amp;n.argumentNames().first()==&quot;$super&quot;){var k=n,n=Object.extend((function(a){return function(){return p[a].apply(this,arguments)}})(m).wrap(k),{valueOf:function(){return k},toString:function(){return k.toString()}})}this.prototype[m]=n}return this}};var Abstract={};Object.extend=function(e,f){for(var d in f){e[d]=f[d]}return e};Object.extend(Object,{inspect:function(d){try{if(Object.isUndefined(d)){return&quot;undefined&quot;}if(d===null){return&quot;null&quot;}return d.inspect?d.inspect():String(d)}catch(c){if(c instanceof RangeError){return&quot;...&quot;}throw c}},toJSON:function(g){var j=typeof g;switch(j){case&quot;undefined&quot;:case&quot;function&quot;:case&quot;unknown&quot;:return;case&quot;boolean&quot;:return g.toString()}if(g===null){return&quot;null&quot;}if(g.toJSON){return g.toJSON()}if(Object.isElement(g)){return}var f=[];for(var h in g){var i=Object.toJSON(g[h]);if(!Object.isUndefined(i)){f.push(h.toJSON()+&quot;: &quot;+i)}}return&quot;{&quot;+f.join(&quot;, &quot;)+&quot;}&quot;},toQueryString:function(b){return $H(b).toQueryString()},toHTML:function(b){return b&amp;&amp;b.toHTML?b.toHTML():String.interpret(b)},keys:function(e){var d=[];for(var f in e){d.push(f)}return d},values:function(d){var e=[];for(var f in d){e.push(d[f])}return e},clone:function(b){return Object.extend({},b)},isElement:function(b){return b&amp;&amp;b.nodeType==1},isArray:function(b){return b!=null&amp;&amp;typeof b==&quot;object&quot;&amp;&amp;&quot;splice&quot; in b&amp;&amp;&quot;join&quot; in b},isHash:function(b){return b instanceof Hash},isFunction:function(b){return typeof b==&quot;function&quot;},isString:function(b){return typeof b==&quot;string&quot;},isNumber:function(b){return typeof b==&quot;number&quot;},isUndefined:function(b){return typeof b==&quot;undefined&quot;}});Object.extend(Function.prototype,{argumentNames:function(){var b=this.toString().match(/^[\s\(]*function[^(]*\((.*?)\)/)[1].split(&quot;,&quot;).invoke(&quot;strip&quot;);return b.length==1&amp;&amp;!b[0]?[]:b},bind:function(){if(arguments.length&lt;2&amp;&amp;Object.isUndefined(arguments[0])){return this}var e=this,f=$A(arguments),d=f.shift();return function(){return e.apply(d,f.concat($A(arguments)))}},bindAsEventListener:function(){var e=this,f=$A(arguments),d=f.shift();return function(a){return e.apply(d,[a||window.event].concat(f))}},curry:function(){if(!arguments.length){return this}var d=this,c=$A(arguments);return function(){return d.apply(this,c.concat($A(arguments)))}},delay:function(){var e=this,d=$A(arguments),f=d.shift()*1000;return window.setTimeout(function(){return e.apply(e,d)},f)},wrap:function(c){var d=this;return function(){return c.apply(this,[d.bind(this)].concat($A(arguments)))}},methodize:function(){if(this._methodized){return this._methodized}var b=this;return this._methodized=function(){return b.apply(null,[this].concat($A(arguments)))}}});Function.prototype.defer=Function.prototype.delay.curry(0.01);Date.prototype.toJSON=function(){return'&quot;'+this.getUTCFullYear()+&quot;-&quot;+(this.getUTCMonth()+1).toPaddedString(2)+&quot;-&quot;+this.getUTCDate().toPaddedString(2)+&quot;T&quot;+this.getUTCHours().toPaddedString(2)+&quot;:&quot;+this.getUTCMinutes().toPaddedString(2)+&quot;:&quot;+this.getUTCSeconds().toPaddedString(2)+'Z&quot;'};var Try={these:function(){var j;for(var e=0,i=arguments.length;e&lt;i;e++){var g=arguments[e];try{j=g();break}catch(h){}}return j}};RegExp.prototype.match=RegExp.prototype.test;RegExp.escape=function(b){return String(b).replace(/([.*+?^=!:${}()|[\]\/\\])/g,&quot;\\$1&quot;)};var PeriodicalExecuter=Class.create({initialize:function(c,d){this.callback=c;this.frequency=d;this.currentlyExecuting=false;this.registerCallback()},registerCallback:function(){this.timer=setInterval(this.onTimerEvent.bind(this),this.frequency*1000)},execute:function(){this.callback(this)},stop:function(){if(!this.timer){return}clearInterval(this.timer);this.timer=null},onTimerEvent:function(){if(!this.currentlyExecuting){try{this.currentlyExecuting=true;this.execute()}finally{this.currentlyExecuting=false}}}});Object.extend(String,{interpret:function(b){return b==null?&quot;&quot;:String(b)},specialChar:{&quot;\b&quot;:&quot;\\b&quot;,&quot;\t&quot;:&quot;\\t&quot;,&quot;\n&quot;:&quot;\\n&quot;,&quot;\f&quot;:&quot;\\f&quot;,&quot;\r&quot;:&quot;\\r&quot;,&quot;\\&quot;:&quot;\\\\&quot;}});Object.extend(String.prototype,{gsub:function(h,j){var g=&quot;&quot;,i=this,f;j=arguments.callee.prepareReplacement(j);while(i.length&gt;0){if(f=i.match(h)){g+=i.slice(0,f.index);g+=String.interpret(j(f));i=i.slice(f.index+f[0].length)}else{g+=i,i=&quot;&quot;}}return g},sub:function(f,e,d){e=this.gsub.prepareReplacement(e);d=Object.isUndefined(d)?1:d;return this.gsub(f,function(a){if(--d&lt;0){return a[0]}return e(a)})},scan:function(c,d){this.gsub(c,d);return String(this)},truncate:function(c,d){c=c||30;d=Object.isUndefined(d)?&quot;...&quot;:d;return this.length&gt;c?this.slice(0,c-d.length)+d:String(this)},strip:function(){return this.replace(/^\s+/,&quot;&quot;).replace(/\s+$/,&quot;&quot;)},stripTags:function(){return this.replace(/&lt;\/?[^&gt;]+&gt;/gi,&quot;&quot;)},stripScripts:function(){return this.replace(new RegExp(Prototype.ScriptFragment,&quot;img&quot;),&quot;&quot;)},extractScripts:function(){var c=new RegExp(Prototype.ScriptFragment,&quot;img&quot;);var d=new RegExp(Prototype.ScriptFragment,&quot;im&quot;);return(this.match(c)||[]).map(function(a){return(a.match(d)||[&quot;&quot;,&quot;&quot;])[1]})},evalScripts:function(){return this.extractScripts().map(function(script){return eval(script)})},escapeHTML:function(){var b=arguments.callee;b.text.data=this;return b.div.innerHTML},unescapeHTML:function(){var b=new Element(&quot;div&quot;);b.innerHTML=this.stripTags();return b.childNodes[0]?(b.childNodes.length&gt;1?$A(b.childNodes).inject(&quot;&quot;,function(a,d){return a+d.nodeValue}):b.childNodes[0].nodeValue):&quot;&quot;},toQueryParams:function(c){var d=this.strip().match(/([^?#]*)(#.*)?$/);if(!d){return{}}return d[1].split(c||&quot;&amp;&quot;).inject({},function(b,a){if((a=a.split(&quot;=&quot;))[0]){var h=decodeURIComponent(a.shift());var g=a.length&gt;1?a.join(&quot;=&quot;):a[0];if(g!=undefined){g=decodeURIComponent(g)}if(h in b){if(!Object.isArray(b[h])){b[h]=[b[h]]}b[h].push(g)}else{b[h]=g}}return b})},toArray:function(){return this.split(&quot;&quot;)},succ:function(){return this.slice(0,this.length-1)+String.fromCharCode(this.charCodeAt(this.length-1)+1)},times:function(b){return b&lt;1?&quot;&quot;:new Array(b+1).join(this)},camelize:function(){var g=this.split(&quot;-&quot;),f=g.length;if(f==1){return g[0]}var h=this.charAt(0)==&quot;-&quot;?g[0].charAt(0).toUpperCase()+g[0].substring(1):g[0];for(var e=1;e&lt;f;e++){h+=g[e].charAt(0).toUpperCase()+g[e].substring(1)}return h},capitalize:function(){return this.charAt(0).toUpperCase()+this.substring(1).toLowerCase()},underscore:function(){return this.gsub(/::/,&quot;/&quot;).gsub(/([A-Z]+)([A-Z][a-z])/,&quot;#{1}_#{2}&quot;).gsub(/([a-z\d])([A-Z])/,&quot;#{1}_#{2}&quot;).gsub(/-/,&quot;_&quot;).toLowerCase()},dasherize:function(){return this.gsub(/_/,&quot;-&quot;)},inspect:function(c){var d=this.gsub(/[\x00-\x1f\\]/,function(b){var a=String.specialChar[b[0]];return a?a:&quot;\\u00&quot;+b[0].charCodeAt().toPaddedString(2,16)});if(c){return'&quot;'+d.replace(/&quot;/g,'\\&quot;')+'&quot;'}return&quot;'&quot;+d.replace(/'/g,&quot;\\'&quot;)+&quot;'&quot;},toJSON:function(){return this.inspect(true)},unfilterJSON:function(b){return this.sub(b||Prototype.JSONFilter,&quot;#{1}&quot;)},isJSON:function(){var b=this;if(b.blank()){return false}b=this.replace(/\\./g,&quot;@&quot;).replace(/&quot;[^&quot;\\\n\r]*&quot;/g,&quot;&quot;);return(/^[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]*$/).test(b)},evalJSON:function(sanitize){var json=this.unfilterJSON();try{if(!sanitize||json.isJSON()){return eval(&quot;(&quot;+json+&quot;)&quot;)}}catch(e){}throw new SyntaxError(&quot;Badly formed JSON string: &quot;+this.inspect())},include:function(b){return this.indexOf(b)&gt;-1},startsWith:function(b){return this.indexOf(b)===0},endsWith:function(d){var c=this.length-d.length;return c&gt;=0&amp;&amp;this.lastIndexOf(d)===c},empty:function(){return this==&quot;&quot;},blank:function(){return/^\s*$/.test(this)},interpolate:function(d,c){return new Template(this,c).evaluate(d)}});if(Prototype.Browser.WebKit||Prototype.Browser.IE){Object.extend(String.prototype,{escapeHTML:function(){return this.replace(/&amp;/g,&quot;&amp;amp;&quot;).replace(/&lt;/g,&quot;&amp;lt;&quot;).replace(/&gt;/g,&quot;&amp;gt;&quot;)},unescapeHTML:function(){return this.replace(/&amp;amp;/g,&quot;&amp;&quot;).replace(/&amp;lt;/g,&quot;&lt;&quot;).replace(/&amp;gt;/g,&quot;&gt;&quot;)}})}String.prototype.gsub.prepareReplacement=function(c){if(Object.isFunction(c)){return c}var d=new Template(c);return function(a){return d.evaluate(a)}};String.prototype.parseQuery=String.prototype.toQueryParams;Object.extend(String.prototype.escapeHTML,{div:document.createElement(&quot;div&quot;),text:document.createTextNode(&quot;&quot;)});with(String.prototype.escapeHTML){div.appendChild(text)}var Template=Class.create({initialize:function(d,c){this.template=d.toString();this.pattern=c||Template.Pattern},evaluate:function(b){if(Object.isFunction(b.toTemplateReplacements)){b=b.toTemplateReplacements()}return this.template.gsub(this.pattern,function(k){if(b==null){return&quot;&quot;}var i=k[1]||&quot;&quot;;if(i==&quot;\\&quot;){return k[2]}var a=b,h=k[3];var j=/^([^.[]+|\[((?:.*?[^\\])?)\])(\.|\[|$)/;k=j.exec(h);if(k==null){return i}while(k!=null){var l=k[1].startsWith(&quot;[&quot;)?k[2].gsub(&quot;\\\\]&quot;,&quot;]&quot;):k[1];a=a[l];if(null==a||&quot;&quot;==k[3]){break}h=h.substring(&quot;[&quot;==k[3]?k[1].length:k[0].length);k=j.exec(h)}return i+String.interpret(a)})}});Template.Pattern=/(^|.|\r|\n)(#\{(.*?)\})/;var $break={};var Enumerable={each:function(h,e){var f=0;h=h.bind(e);try{this._each(function(a){h(a,f++)})}catch(g){if(g!=$break){throw g}}return this},eachSlice:function(k,l,g){l=l?l.bind(g):Prototype.K;var h=-k,j=[],i=this.toArray();while((h+=k)&lt;i.length){j.push(i.slice(h,h+k))}return j.collect(l,g)},all:function(f,d){f=f?f.bind(d):Prototype.K;var e=true;this.each(function(a,b){e=e&amp;&amp;!!f(a,b);if(!e){throw $break}});return e},any:function(f,d){f=f?f.bind(d):Prototype.K;var e=false;this.each(function(a,b){if(e=!!f(a,b)){throw $break}});return e},collect:function(f,d){f=f?f.bind(d):Prototype.K;var e=[];this.each(function(a,b){e.push(f(a,b))});return e},detect:function(f,d){f=f.bind(d);var e;this.each(function(a,b){if(f(a,b)){e=a;throw $break}});return e},findAll:function(f,d){f=f.bind(d);var e=[];this.each(function(a,b){if(f(a,b)){e.push(a)}});return e},grep:function(g,h,e){h=h?h.bind(e):Prototype.K;var f=[];if(Object.isString(g)){g=new RegExp(g)}this.each(function(a,b){if(g.match(a)){f.push(h(a,b))}});return f},include:function(d){if(Object.isFunction(this.indexOf)){if(this.indexOf(d)!=-1){return true}}var c=false;this.each(function(a){if(a==d){c=true;throw $break}});return c},inGroupsOf:function(c,d){d=Object.isUndefined(d)?null:d;return this.eachSlice(c,function(a){while(a.length&lt;c){a.push(d)}return a})},inject:function(e,f,d){f=f.bind(d);this.each(function(a,b){e=f(e,a,b)});return e},invoke:function(c){var d=$A(arguments).slice(1);return this.map(function(a){return a[c].apply(a,d)})},max:function(f,d){f=f?f.bind(d):Prototype.K;var e;this.each(function(a,b){a=f(a,b);if(e==null||a&gt;=e){e=a}});return e},min:function(f,d){f=f?f.bind(d):Prototype.K;var e;this.each(function(a,b){a=f(a,b);if(e==null||a&lt;e){e=a}});return e},partition:function(g,e){g=g?g.bind(e):Prototype.K;var h=[],f=[];this.each(function(a,b){(g(a,b)?h:f).push(a)});return[h,f]},pluck:function(c){var d=[];this.each(function(a){d.push(a[c])});return d},reject:function(f,d){f=f.bind(d);var e=[];this.each(function(a,b){if(!f(a,b)){e.push(a)}});return e},sortBy:function(c,d){c=c.bind(d);return this.map(function(a,b){return{value:a,criteria:c(a,b)}}).sort(function(a,b){var g=a.criteria,h=b.criteria;return g&lt;h?-1:g&gt;h?1:0}).pluck(&quot;value&quot;)},toArray:function(){return this.map()},zip:function(){var d=Prototype.K,e=$A(arguments);if(Object.isFunction(e.last())){d=e.pop()}var f=[this].concat(e).map($A);return this.map(function(a,b){return d(f.pluck(b))})},size:function(){return this.toArray().length},inspect:function(){return&quot;#&lt;Enumerable:&quot;+this.toArray().inspect()+&quot;&gt;&quot;}};Object.extend(Enumerable,{map:Enumerable.collect,find:Enumerable.detect,select:Enumerable.findAll,filter:Enumerable.findAll,member:Enumerable.include,entries:Enumerable.toArray,every:Enumerable.all,some:Enumerable.any});function $A(f){if(!f){return[]}if(f.toArray){return f.toArray()}var d=f.length||0,e=new Array(d);while(d--){e[d]=f[d]}return e}if(Prototype.Browser.WebKit){$A=function(f){if(!f){return[]}if(!(Object.isFunction(f)&amp;&amp;f==&quot;[object NodeList]&quot;)&amp;&amp;f.toArray){return f.toArray()}var d=f.length||0,e=new Array(d);while(d--){e[d]=f[d]}return e}}Array.from=$A;Object.extend(Array.prototype,Enumerable);if(!Array.prototype._reverse){Array.prototype._reverse=Array.prototype.reverse}Object.extend(Array.prototype,{_each:function(d){for(var e=0,f=this.length;e&lt;f;e++){d(this[e])}},clear:function(){this.length=0;return this},first:function(){return this[0]},last:function(){return this[this.length-1]},compact:function(){return this.select(function(b){return b!=null})},flatten:function(){return this.inject([],function(c,d){return c.concat(Object.isArray(d)?d.flatten():[d])})},without:function(){var b=$A(arguments);return this.select(function(a){return !b.include(a)})},reverse:function(b){return(b!==false?this:this.toArray())._reverse()},reduce:function(){return this.length&gt;1?this:this[0]},uniq:function(b){return this.inject([],function(e,f,a){if(0==a||(b?e.last()!=f:!e.include(f))){e.push(f)}return e})},intersect:function(b){return this.uniq().findAll(function(a){return b.detect(function(d){return a===d})})},clone:function(){return[].concat(this)},size:function(){return this.length},inspect:function(){return&quot;[&quot;+this.map(Object.inspect).join(&quot;, &quot;)+&quot;]&quot;},toJSON:function(){var b=[];this.each(function(a){var d=Object.toJSON(a);if(!Object.isUndefined(d)){b.push(d)}});return&quot;[&quot;+b.join(&quot;, &quot;)+&quot;]&quot;}});if(Object.isFunction(Array.prototype.forEach)){Array.prototype._each=Array.prototype.forEach}if(!Array.prototype.indexOf){Array.prototype.indexOf=function(f,e){e||(e=0);var d=this.length;if(e&lt;0){e=d+e}for(;e&lt;d;e++){if(this[e]===f){return e}}return -1}}if(!Array.prototype.lastIndexOf){Array.prototype.lastIndexOf=function(d,e){e=isNaN(e)?this.length:(e&lt;0?this.length+e:e)+1;var f=this.slice(0,e).reverse().indexOf(d);return(f&lt;0)?f:e-f-1}}Array.prototype.toArray=Array.prototype.clone;function $w(b){if(!Object.isString(b)){return[]}b=b.strip();return b?b.split(/\s+/):[]}if(Prototype.Browser.Opera){Array.prototype.concat=function(){var h=[];for(var f=0,j=this.length;f&lt;j;f++){h.push(this[f])}for(var f=0,j=arguments.length;f&lt;j;f++){if(Object.isArray(arguments[f])){for(var g=0,i=arguments[f].length;g&lt;i;g++){h.push(arguments[f][g])}}else{h.push(arguments[f])}}return h}}Object.extend(Number.prototype,{toColorPart:function(){return this.toPaddedString(2,16)},succ:function(){return this+1},times:function(b){$R(0,this,true).each(b);return this},toPaddedString:function(f,d){var e=this.toString(d||10);return&quot;0&quot;.times(f-e.length)+e},toJSON:function(){return isFinite(this)?this.toString():&quot;null&quot;}});$w(&quot;abs round ceil floor&quot;).each(function(b){Number.prototype[b]=Math[b].methodize()});function $H(b){return new Hash(b)}var Hash=Class.create(Enumerable,(function(){function b(a,d){if(Object.isUndefined(d)){return a}return a+&quot;=&quot;+encodeURIComponent(String.interpret(d))}return{initialize:function(a){this._object=Object.isHash(a)?a.toObject():Object.clone(a)},_each:function(h){for(var a in this._object){var g=this._object[a],f=[a,g];f.key=a;f.value=g;h(f)}},set:function(a,d){return this._object[a]=d},get:function(a){return this._object[a]},unset:function(a){var d=this._object[a];delete this._object[a];return d},toObject:function(){return Object.clone(this._object)},keys:function(){return this.pluck(&quot;key&quot;)},values:function(){return this.pluck(&quot;value&quot;)},index:function(d){var a=this.detect(function(c){return c.value===d});return a&amp;&amp;a.key},merge:function(a){return this.clone().update(a)},update:function(a){return new Hash(a).inject(this,function(f,e){f.set(e.key,e.value);return f})},toQueryString:function(){return this.map(function(e){var f=encodeURIComponent(e.key),a=e.value;if(a&amp;&amp;typeof a==&quot;object&quot;){if(Object.isArray(a)){return a.map(b.curry(f)).join(&quot;&amp;&quot;)}}return b(f,a)}).join(&quot;&amp;&quot;)},inspect:function(){return&quot;#&lt;Hash:{&quot;+this.map(function(a){return a.map(Object.inspect).join(&quot;: &quot;)}).join(&quot;, &quot;)+&quot;}&gt;&quot;},toJSON:function(){return Object.toJSON(this.toObject())},clone:function(){return new Hash(this)}}})());Hash.prototype.toTemplateReplacements=Hash.prototype.toObject;Hash.from=$H;var ObjectRange=Class.create(Enumerable,{initialize:function(f,e,d){this.start=f;this.end=e;this.exclusive=d},_each:function(d){var c=this.start;while(this.include(c)){d(c);c=c.succ()}},include:function(b){if(b&lt;this.start){return false}if(this.exclusive){return b&lt;this.end}return b&lt;=this.end}});var $R=function(f,e,d){return new ObjectRange(f,e,d)};var Ajax={getTransport:function(){return Try.these(function(){return new XMLHttpRequest()},function(){return new ActiveXObject(&quot;Msxml2.XMLHTTP&quot;)},function(){return new ActiveXObject(&quot;Microsoft.XMLHTTP&quot;)})||false},activeRequestCount:0};Ajax.Responders={responders:[],_each:function(b){this.responders._each(b)},register:function(b){if(!this.include(b)){this.responders.push(b)}},unregister:function(b){this.responders=this.responders.without(b)},dispatch:function(g,e,h,f){this.each(function(b){if(Object.isFunction(b[g])){try{b[g].apply(b,[e,h,f])}catch(a){}}})}};Object.extend(Ajax.Responders,Enumerable);Ajax.Responders.register({onCreate:function(){Ajax.activeRequestCount++},onComplete:function(){Ajax.activeRequestCount--}});Ajax.Base=Class.create({initialize:function(b){this.options={method:&quot;post&quot;,asynchronous:true,contentType:&quot;application/x-www-form-urlencoded&quot;,encoding:&quot;UTF-8&quot;,parameters:&quot;&quot;,evalJSON:true,evalJS:true};Object.extend(this.options,b||{});this.options.method=this.options.method.toLowerCase();if(Object.isString(this.options.parameters)){this.options.parameters=this.options.parameters.toQueryParams()}else{if(Object.isHash(this.options.parameters)){this.options.parameters=this.options.parameters.toObject()}}}});Ajax.Request=Class.create(Ajax.Base,{_complete:false,initialize:function($super,c,d){$super(d);this.transport=Ajax.getTransport();this.request(c)},request:function(e){this.url=e;this.method=this.options.method;var g=Object.clone(this.options.parameters);if(![&quot;get&quot;,&quot;post&quot;].include(this.method)){g._method=this.method;this.method=&quot;post&quot;}this.parameters=g;if(g=Object.toQueryString(g)){if(this.method==&quot;get&quot;){this.url+=(this.url.include(&quot;?&quot;)?&quot;&amp;&quot;:&quot;?&quot;)+g}else{if(/Konqueror|Safari|KHTML/.test(navigator.userAgent)){g+=&quot;&amp;_=&quot;}}}try{var f=new Ajax.Response(this);if(this.options.onCreate){this.options.onCreate(f)}Ajax.Responders.dispatch(&quot;onCreate&quot;,this,f);this.transport.open(this.method.toUpperCase(),this.url,this.options.asynchronous);if(this.options.asynchronous){this.respondToReadyState.bind(this).defer(1)}this.transport.onreadystatechange=this.onStateChange.bind(this);this.setRequestHeaders();this.body=this.method==&quot;post&quot;?(this.options.postBody||g):null;this.transport.send(this.body);if(!this.options.asynchronous&amp;&amp;this.transport.overrideMimeType){this.onStateChange()}}catch(h){this.dispatchException(h)}},onStateChange:function(){var b=this.transport.readyState;if(b&gt;1&amp;&amp;!((b==4)&amp;&amp;this._complete)){this.respondToReadyState(this.transport.readyState)}},setRequestHeaders:function(){var h={&quot;X-Requested-With&quot;:&quot;XMLHttpRequest&quot;,&quot;X-Prototype-Version&quot;:Prototype.Version,Accept:&quot;text/javascript, text/html, application/xml, text/xml, */*&quot;};if(this.method==&quot;post&quot;){h[&quot;Content-type&quot;]=this.options.contentType+(this.options.encoding?&quot;; charset=&quot;+this.options.encoding:&quot;&quot;);if(this.transport.overrideMimeType&amp;&amp;(navigator.userAgent.match(/Gecko\/(\d{4})/)||[0,2005])[1]&lt;2005){h.Connection=&quot;close&quot;}}if(typeof this.options.requestHeaders==&quot;object&quot;){var j=this.options.requestHeaders;if(Object.isFunction(j.push)){for(var f=0,i=j.length;f&lt;i;f+=2){h[j[f]]=j[f+1]}}else{$H(j).each(function(a){h[a.key]=a.value})}}for(var g in h){this.transport.setRequestHeader(g,h[g])}},success:function(){var b=this.getStatus();return !b||(b&gt;=200&amp;&amp;b&lt;300)},getStatus:function(){try{return this.transport.status||0}catch(b){return 0}},respondToReadyState:function(g){var j=Ajax.Request.Events[g],e=new Ajax.Response(this);if(j==&quot;Complete&quot;){try{this._complete=true;(this.options[&quot;on&quot;+e.status]||this.options[&quot;on&quot;+(this.success()?&quot;Success&quot;:&quot;Failure&quot;)]||Prototype.emptyFunction)(e,e.headerJSON)}catch(i){this.dispatchException(i)}var h=e.getHeader(&quot;Content-type&quot;);if(this.options.evalJS==&quot;force&quot;||(this.options.evalJS&amp;&amp;this.isSameOrigin()&amp;&amp;h&amp;&amp;h.match(/^\s*(text|application)\/(x-)?(java|ecma)script(;.*)?\s*$/i))){this.evalResponse()}}try{(this.options[&quot;on&quot;+j]||Prototype.emptyFunction)(e,e.headerJSON);Ajax.Responders.dispatch(&quot;on&quot;+j,this,e,e.headerJSON)}catch(i){this.dispatchException(i)}if(j==&quot;Complete&quot;){this.transport.onreadystatechange=Prototype.emptyFunction}},isSameOrigin:function(){var b=this.url.match(/^\s*https?:\/\/[^\/]*/);return !b||(b[0]==&quot;#{protocol}//#{domain}#{port}&quot;.interpolate({protocol:location.protocol,domain:document.domain,port:location.port?&quot;:&quot;+location.port:&quot;&quot;}))},getHeader:function(d){try{return this.transport.getResponseHeader(d)||null}catch(c){return null}},evalResponse:function(){try{return eval((this.transport.responseText||&quot;&quot;).unfilterJSON())}catch(e){this.dispatchException(e)}},dispatchException:function(b){(this.options.onException||Prototype.emptyFunction)(this,b);Ajax.Responders.dispatch(&quot;onException&quot;,this,b)}});Ajax.Request.Events=[&quot;Uninitialized&quot;,&quot;Loading&quot;,&quot;Loaded&quot;,&quot;Interactive&quot;,&quot;Complete&quot;];Ajax.Response=Class.create({initialize:function(h){this.request=h;var g=this.transport=h.transport,f=this.readyState=g.readyState;if((f&gt;2&amp;&amp;!Prototype.Browser.IE)||f==4){this.status=this.getStatus();this.statusText=this.getStatusText();this.responseText=String.interpret(g.responseText);this.headerJSON=this._getHeaderJSON()}if(f==4){var e=g.responseXML;this.responseXML=Object.isUndefined(e)?null:e;this.responseJSON=this._getResponseJSON()}},status:0,statusText:&quot;&quot;,getStatus:Ajax.Request.prototype.getStatus,getStatusText:function(){try{return this.transport.statusText||&quot;&quot;}catch(b){return&quot;&quot;}},getHeader:Ajax.Request.prototype.getHeader,getAllHeaders:function(){try{return this.getAllResponseHeaders()}catch(b){return null}},getResponseHeader:function(b){return this.transport.getResponseHeader(b)},getAllResponseHeaders:function(){return this.transport.getAllResponseHeaders()},_getHeaderJSON:function(){var d=this.getHeader(&quot;X-JSON&quot;);if(!d){return null}d=decodeURIComponent(escape(d));try{return d.evalJSON(this.request.options.sanitizeJSON||!this.request.isSameOrigin())}catch(c){this.request.dispatchException(c)}},_getResponseJSON:function(){var d=this.request.options;if(!d.evalJSON||(d.evalJSON!=&quot;force&quot;&amp;&amp;!(this.getHeader(&quot;Content-type&quot;)||&quot;&quot;).include(&quot;application/json&quot;))||this.responseText.blank()){return null}try{return this.responseText.evalJSON(d.sanitizeJSON||!this.request.isSameOrigin())}catch(c){this.request.dispatchException(c)}}});Ajax.Updater=Class.create(Ajax.Request,{initialize:function($super,f,h,e){this.container={success:(f.success||f),failure:(f.failure||(f.success?null:f))};e=Object.clone(e);var g=e.onComplete;e.onComplete=(function(b,a){this.updateContent(b.responseText);if(Object.isFunction(g)){g(b,a)}}).bind(this);$super(h,e)},updateContent:function(g){var h=this.container[this.success()?&quot;success&quot;:&quot;failure&quot;],f=this.options;if(!f.evalScripts){g=g.stripScripts()}if(h=$(h)){if(f.insertion){if(Object.isString(f.insertion)){var e={};e[f.insertion]=g;h.insert(e)}else{f.insertion(h,g)}}else{h.update(g)}}}});Ajax.PeriodicalUpdater=Class.create(Ajax.Base,{initialize:function($super,e,f,d){$super(d);this.onComplete=this.options.onComplete;this.frequency=(this.options.frequency||2);this.decay=(this.options.decay||1);this.updater={};this.container=e;this.url=f;this.start()},start:function(){this.options.onComplete=this.updateComplete.bind(this);this.onTimerEvent()},stop:function(){this.updater.options.onComplete=undefined;clearTimeout(this.timer);(this.onComplete||Prototype.emptyFunction).apply(this,arguments)},updateComplete:function(b){if(this.options.decay){this.decay=(b.responseText==this.lastText?this.decay*this.options.decay:1);this.lastText=b.responseText}this.timer=this.onTimerEvent.bind(this).delay(this.decay*this.frequency)},onTimerEvent:function(){this.updater=new Ajax.Updater(this.container,this.url,this.options)}});function $(e){if(arguments.length&gt;1){for(var f=0,g=[],h=arguments.length;f&lt;h;f++){g.push($(arguments[f]))}return g}if(Object.isString(e)){e=document.getElementById(e)}return Element.extend(e)}if(Prototype.BrowserFeatures.XPath){document._getElementsByXPath=function(i,h){var l=[];var j=document.evaluate(i,$(h)||document,null,XPathResult.ORDERED_NODE_SNAPSHOT_TYPE,null);for(var g=0,k=j.snapshotLength;g&lt;k;g++){l.push(Element.extend(j.snapshotItem(g)))}return l}}if(!window.Node){var Node={}}if(!Node.ELEMENT_NODE){Object.extend(Node,{ELEMENT_NODE:1,ATTRIBUTE_NODE:2,TEXT_NODE:3,CDATA_SECTION_NODE:4,ENTITY_REFERENCE_NODE:5,ENTITY_NODE:6,PROCESSING_INSTRUCTION_NODE:7,COMMENT_NODE:8,DOCUMENT_NODE:9,DOCUMENT_TYPE_NODE:10,DOCUMENT_FRAGMENT_NODE:11,NOTATION_NODE:12})}(function(){var b=this.Element;this.Element=function(e,f){f=f||{};e=e.toLowerCase();var a=Element.cache;if(Prototype.Browser.IE&amp;&amp;f.name){e=&quot;&lt;&quot;+e+' name=&quot;'+f.name+'&quot;&gt;';delete f.name;return Element.writeAttribute(document.createElement(e),f)}if(!a[e]){a[e]=Element.extend(document.createElement(e))}return Element.writeAttribute(a[e].cloneNode(false),f)};Object.extend(this.Element,b||{})}).call(window);Element.cache={};Element.Methods={visible:function(b){return $(b).style.display!=&quot;none&quot;},toggle:function(b){b=$(b);Element[Element.visible(b)?&quot;hide&quot;:&quot;show&quot;](b);return b},hide:function(b){$(b).style.display=&quot;none&quot;;return b},show:function(b){$(b).style.display=&quot;&quot;;return b},remove:function(b){b=$(b);b.parentNode.removeChild(b);return b},update:function(d,c){d=$(d);if(c&amp;&amp;c.toElement){c=c.toElement()}if(Object.isElement(c)){return d.update().insert(c)}c=Object.toHTML(c);d.innerHTML=c.stripScripts();c.evalScripts.bind(c).defer();return d},replace:function(d,f){d=$(d);if(f&amp;&amp;f.toElement){f=f.toElement()}else{if(!Object.isElement(f)){f=Object.toHTML(f);var e=d.ownerDocument.createRange();e.selectNode(d);f.evalScripts.bind(f).defer();f=e.createContextualFragment(f.stripScripts())}}d.parentNode.replaceChild(f,d);return d},insert:function(n,l){n=$(n);if(Object.isString(l)||Object.isNumber(l)||Object.isElement(l)||(l&amp;&amp;(l.toElement||l.toHTML))){l={bottom:l}}var m,k,h,j;for(var i in l){m=l[i];i=i.toLowerCase();k=Element._insertionTranslations[i];if(m&amp;&amp;m.toElement){m=m.toElement()}if(Object.isElement(m)){k(n,m);continue}m=Object.toHTML(m);h=((i==&quot;before&quot;||i==&quot;after&quot;)?n.parentNode:n).tagName.toUpperCase();j=Element._getContentFromAnonymousElement(h,m.stripScripts());if(i==&quot;top&quot;||i==&quot;after&quot;){j.reverse()}j.each(k.curry(n));m.evalScripts.bind(m).defer()}return n},wrap:function(d,f,e){d=$(d);if(Object.isElement(f)){$(f).writeAttribute(e||{})}else{if(Object.isString(f)){f=new Element(f,e)}else{f=new Element(&quot;div&quot;,f)}}if(d.parentNode){d.parentNode.replaceChild(f,d)}f.appendChild(d);return f},inspect:function(c){c=$(c);var d=&quot;&lt;&quot;+c.tagName.toLowerCase();$H({id:&quot;id&quot;,className:&quot;class&quot;}).each(function(a){var b=a.first(),h=a.last();var g=(c[b]||&quot;&quot;).toString();if(g){d+=&quot; &quot;+h+&quot;=&quot;+g.inspect(true)}});return d+&quot;&gt;&quot;},recursivelyCollect:function(e,f){e=$(e);var d=[];while(e=e[f]){if(e.nodeType==1){d.push(Element.extend(e))}}return d},ancestors:function(b){return $(b).recursivelyCollect(&quot;parentNode&quot;)},descendants:function(b){return $(b).select(&quot;*&quot;)},firstDescendant:function(b){b=$(b).firstChild;while(b&amp;&amp;b.nodeType!=1){b=b.nextSibling}return $(b)},immediateDescendants:function(b){if(!(b=$(b).firstChild)){return[]}while(b&amp;&amp;b.nodeType!=1){b=b.nextSibling}if(b){return[b].concat($(b).nextSiblings())}return[]},previousSiblings:function(b){return $(b).recursivelyCollect(&quot;previousSibling&quot;)},nextSiblings:function(b){return $(b).recursivelyCollect(&quot;nextSibling&quot;)},siblings:function(b){b=$(b);return b.previousSiblings().reverse().concat(b.nextSiblings())},match:function(c,d){if(Object.isString(d)){d=new Selector(d)}return d.match($(c))},up:function(e,g,f){e=$(e);if(arguments.length==1){return $(e.parentNode)}var h=e.ancestors();return Object.isNumber(g)?h[g]:Selector.findElement(h,g,f)},down:function(d,f,e){d=$(d);if(arguments.length==1){return d.firstDescendant()}return Object.isNumber(f)?d.descendants()[f]:d.select(f)[e||0]},previous:function(e,g,f){e=$(e);if(arguments.length==1){return $(Selector.handlers.previousElementSibling(e))}var h=e.previousSiblings();return Object.isNumber(g)?h[g]:Selector.findElement(h,g,f)},next:function(h,g,e){h=$(h);if(arguments.length==1){return $(Selector.handlers.nextElementSibling(h))}var f=h.nextSiblings();return Object.isNumber(g)?f[g]:Selector.findElement(f,g,e)},select:function(){var d=$A(arguments),c=$(d.shift());return Selector.findChildElements(c,d)},adjacent:function(){var d=$A(arguments),c=$(d.shift());return Selector.findChildElements(c.parentNode,d).without(c)},identify:function(d){d=$(d);var f=d.readAttribute(&quot;id&quot;),e=arguments.callee;if(f){return f}do{f=&quot;anonymous_element_&quot;+e.counter++}while($(f));d.writeAttribute(&quot;id&quot;,f);return f},readAttribute:function(f,e){f=$(f);if(Prototype.Browser.IE){var d=Element._attributeTranslations.read;if(d.values[e]){return d.values[e](f,e)}if(d.names[e]){e=d.names[e]}if(e.include(&quot;:&quot;)){return(!f.attributes||!f.attributes[e])?null:f.attributes[e].value}}return f.getAttribute(e)},writeAttribute:function(j,l,i){j=$(j);var g={},k=Element._attributeTranslations.write;if(typeof l==&quot;object&quot;){g=l}else{g[l]=Object.isUndefined(i)?true:i}for(var h in g){l=k.names[h]||h;i=g[h];if(k.values[h]){l=k.values[h](j,i)}if(i===false||i===null){j.removeAttribute(l)}else{if(i===true){j.setAttribute(l,l)}else{j.setAttribute(l,i)}}}return j},getHeight:function(b){return $(b).getDimensions().height},getWidth:function(b){return $(b).getDimensions().width},classNames:function(b){return new Element.ClassNames(b)},hasClassName:function(e,d){if(!(e=$(e))){return}var f=e.className;return(f.length&gt;0&amp;&amp;(f==d||new RegExp(&quot;(^|\\s)&quot;+d+&quot;(\\s|$)&quot;).test(f)))},addClassName:function(d,c){if(!(d=$(d))){return}if(!d.hasClassName(c)){d.className+=(d.className?&quot; &quot;:&quot;&quot;)+c}return d},removeClassName:function(d,c){if(!(d=$(d))){return}d.className=d.className.replace(new RegExp(&quot;(^|\\s+)&quot;+c+&quot;(\\s+|$)&quot;),&quot; &quot;).strip();return d},toggleClassName:function(d,c){if(!(d=$(d))){return}return d[d.hasClassName(c)?&quot;removeClassName&quot;:&quot;addClassName&quot;](c)},cleanWhitespace:function(d){d=$(d);var f=d.firstChild;while(f){var e=f.nextSibling;if(f.nodeType==3&amp;&amp;!/\S/.test(f.nodeValue)){d.removeChild(f)}f=e}return d},empty:function(b){return $(b).innerHTML.blank()},descendantOf:function(j,k){j=$(j),k=$(k);var e=k;if(j.compareDocumentPosition){return(j.compareDocumentPosition(k)&amp;8)===8}if(j.sourceIndex&amp;&amp;!Prototype.Browser.Opera){var i=j.sourceIndex,l=k.sourceIndex,a=k.nextSibling;if(!a){do{k=k.parentNode}while(!(a=k.nextSibling)&amp;&amp;k.parentNode)}if(a&amp;&amp;a.sourceIndex){return(i&gt;l&amp;&amp;i&lt;a.sourceIndex)}}while(j=j.parentNode){if(j==e){return true}}return false},scrollTo:function(d){d=$(d);var c=d.cumulativeOffset();window.scrollTo(c[0],c[1]);return d},getStyle:function(e,h){e=$(e);h=h==&quot;float&quot;?&quot;cssFloat&quot;:h.camelize();var g=e.style[h];if(!g){var f=document.defaultView.getComputedStyle(e,null);g=f?f[h]:null}if(h==&quot;opacity&quot;){return g?parseFloat(g):1}return g==&quot;auto&quot;?null:g},getOpacity:function(b){return $(b).getStyle(&quot;opacity&quot;)},setStyle:function(f,j){f=$(f);var h=f.style,g;if(Object.isString(j)){f.style.cssText+=&quot;;&quot;+j;return j.include(&quot;opacity&quot;)?f.setOpacity(j.match(/opacity:\s*(\d?\.?\d*)/)[1]):f}for(var i in j){if(i==&quot;opacity&quot;){f.setOpacity(j[i])}else{h[(i==&quot;float&quot;||i==&quot;cssFloat&quot;)?(Object.isUndefined(h.styleFloat)?&quot;cssFloat&quot;:&quot;styleFloat&quot;):i]=j[i]}}return f},setOpacity:function(d,c){d=$(d);d.style.opacity=(c==1||c===&quot;&quot;)?&quot;&quot;:(c&lt;0.00001)?0:c;return d},getDimensions:function(p){p=$(p);var l=$(p).getStyle(&quot;display&quot;);if(l!=&quot;none&quot;&amp;&amp;l!=null){return{width:p.offsetWidth,height:p.offsetHeight}}var i=p.style;var m=i.visibility;var o=i.position;var j=i.display;i.visibility=&quot;hidden&quot;;i.position=&quot;absolute&quot;;i.display=&quot;block&quot;;var k=p.clientWidth;var n=p.clientHeight;i.display=j;i.position=o;i.visibility=m;return{width:k,height:n}},makePositioned:function(d){d=$(d);var c=Element.getStyle(d,&quot;position&quot;);if(c==&quot;static&quot;||!c){d._madePositioned=true;d.style.position=&quot;relative&quot;;if(window.opera){d.style.top=0;d.style.left=0}}return d},undoPositioned:function(b){b=$(b);if(b._madePositioned){b._madePositioned=undefined;b.style.position=b.style.top=b.style.left=b.style.bottom=b.style.right=&quot;&quot;}return b},makeClipping:function(b){b=$(b);if(b._overflow){return b}b._overflow=Element.getStyle(b,&quot;overflow&quot;)||&quot;auto&quot;;if(b._overflow!==&quot;hidden&quot;){b.style.overflow=&quot;hidden&quot;}return b},undoClipping:function(b){b=$(b);if(!b._overflow){return b}b.style.overflow=b._overflow==&quot;auto&quot;?&quot;&quot;:b._overflow;b._overflow=null;return b},cumulativeOffset:function(d){var e=0,f=0;do{e+=d.offsetTop||0;f+=d.offsetLeft||0;d=d.offsetParent}while(d);return Element._returnOffset(f,e)},positionedOffset:function(e){var f=0,g=0;do{f+=e.offsetTop||0;g+=e.offsetLeft||0;e=e.offsetParent;if(e){if(e.tagName==&quot;BODY&quot;){break}var h=Element.getStyle(e,&quot;position&quot;);if(h!==&quot;static&quot;){break}}}while(e);return Element._returnOffset(g,f)},absolutize:function(g){g=$(g);if(g.getStyle(&quot;position&quot;)==&quot;absolute&quot;){return}var k=g.positionedOffset();var i=k[1];var j=k[0];var l=g.clientWidth;var h=g.clientHeight;g._originalLeft=j-parseFloat(g.style.left||0);g._originalTop=i-parseFloat(g.style.top||0);g._originalWidth=g.style.width;g._originalHeight=g.style.height;g.style.position=&quot;absolute&quot;;g.style.top=i+&quot;px&quot;;g.style.left=j+&quot;px&quot;;g.style.width=l+&quot;px&quot;;g.style.height=h+&quot;px&quot;;return g},relativize:function(e){e=$(e);if(e.getStyle(&quot;position&quot;)==&quot;relative&quot;){return}e.style.position=&quot;relative&quot;;var f=parseFloat(e.style.top||0)-(e._originalTop||0);var d=parseFloat(e.style.left||0)-(e._originalLeft||0);e.style.top=f+&quot;px&quot;;e.style.left=d+&quot;px&quot;;e.style.height=e._originalHeight;e.style.width=e._originalWidth;return e},cumulativeScrollOffset:function(d){var e=0,f=0;do{e+=d.scrollTop||0;f+=d.scrollLeft||0;d=d.parentNode}while(d);return Element._returnOffset(f,e)},getOffsetParent:function(b){if(b.offsetParent){return $(b.offsetParent)}if(b==document.body){return $(b)}while((b=b.parentNode)&amp;&amp;b!=document.body){if(Element.getStyle(b,&quot;position&quot;)!=&quot;static&quot;){return $(b)}}return $(document.body)},viewportOffset:function(g){var f=0,h=0;var e=g;do{f+=e.offsetTop||0;h+=e.offsetLeft||0;if(e.offsetParent==document.body&amp;&amp;Element.getStyle(e,&quot;position&quot;)==&quot;absolute&quot;){break}}while(e=e.offsetParent);e=g;do{if(!Prototype.Browser.Opera||e.tagName==&quot;BODY&quot;){f-=e.scrollTop||0;h-=e.scrollLeft||0}}while(e=e.parentNode);return Element._returnOffset(h,f)},clonePosition:function(g,k){var h=Object.extend({setLeft:true,setTop:true,setWidth:true,setHeight:true,offsetTop:0,offsetLeft:0},arguments[2]||{});k=$(k);var j=k.viewportOffset();g=$(g);var i=[0,0];var l=null;if(Element.getStyle(g,&quot;position&quot;)==&quot;absolute&quot;){l=g.getOffsetParent();i=l.viewportOffset()}if(l==document.body){i[0]-=document.body.offsetLeft;i[1]-=document.body.offsetTop}if(h.setLeft){g.style.left=(j[0]-i[0]+h.offsetLeft)+&quot;px&quot;}if(h.setTop){g.style.top=(j[1]-i[1]+h.offsetTop)+&quot;px&quot;}if(h.setWidth){g.style.width=k.offsetWidth+&quot;px&quot;}if(h.setHeight){g.style.height=k.offsetHeight+&quot;px&quot;}return g}};Element.Methods.identify.counter=1;Object.extend(Element.Methods,{getElementsBySelector:Element.Methods.select,childElements:Element.Methods.immediateDescendants});Element._attributeTranslations={write:{names:{className:&quot;class&quot;,htmlFor:&quot;for&quot;},values:{}}};if(Prototype.Browser.Opera){Element.Methods.getStyle=Element.Methods.getStyle.wrap(function(i,f,j){switch(j){case&quot;left&quot;:case&quot;top&quot;:case&quot;right&quot;:case&quot;bottom&quot;:if(i(f,&quot;position&quot;)===&quot;static&quot;){return null}case&quot;height&quot;:case&quot;width&quot;:if(!Element.visible(f)){return null}var h=parseInt(i(f,j),10);if(h!==f[&quot;offset&quot;+j.capitalize()]){return h+&quot;px&quot;}var g;if(j===&quot;height&quot;){g=[&quot;border-top-width&quot;,&quot;padding-top&quot;,&quot;padding-bottom&quot;,&quot;border-bottom-width&quot;]}else{g=[&quot;border-left-width&quot;,&quot;padding-left&quot;,&quot;padding-right&quot;,&quot;border-right-width&quot;]}return g.inject(h,function(c,b){var a=i(f,b);return a===null?c:c-parseInt(a,10)})+&quot;px&quot;;default:return i(f,j)}});Element.Methods.readAttribute=Element.Methods.readAttribute.wrap(function(f,e,d){if(d===&quot;title&quot;){return e.title}return f(e,d)})}else{if(Prototype.Browser.IE){Element.Methods.getOffsetParent=Element.Methods.getOffsetParent.wrap(function(h,e){e=$(e);var f=e.getStyle(&quot;position&quot;);if(f!==&quot;static&quot;){return h(e)}e.setStyle({position:&quot;relative&quot;});var g=h(e);e.setStyle({position:f});return g});$w(&quot;positionedOffset viewportOffset&quot;).each(function(b){Element.Methods[b]=Element.Methods[b].wrap(function(h,j){j=$(j);var a=j.getStyle(&quot;position&quot;);if(a!==&quot;static&quot;){return h(j)}var i=j.getOffsetParent();if(i&amp;&amp;i.getStyle(&quot;position&quot;)===&quot;fixed&quot;){i.setStyle({zoom:1})}j.setStyle({position:&quot;relative&quot;});var g=h(j);j.setStyle({position:a});return g})});Element.Methods.getStyle=function(e,d){e=$(e);d=(d==&quot;float&quot;||d==&quot;cssFloat&quot;)?&quot;styleFloat&quot;:d.camelize();var f=e.style[d];if(!f&amp;&amp;e.currentStyle){f=e.currentStyle[d]}if(d==&quot;opacity&quot;){if(f=(e.getStyle(&quot;filter&quot;)||&quot;&quot;).match(/alpha\(opacity=(.*)\)/)){if(f[1]){return parseFloat(f[1])/100}}return 1}if(f==&quot;auto&quot;){if((d==&quot;width&quot;||d==&quot;height&quot;)&amp;&amp;(e.getStyle(&quot;display&quot;)!=&quot;none&quot;)){return e[&quot;offset&quot;+d.capitalize()]+&quot;px&quot;}return null}return f};Element.Methods.setOpacity=function(g,j){function i(a){return a.replace(/alpha\([^\)]*\)/gi,&quot;&quot;)}g=$(g);var h=g.currentStyle;if((h&amp;&amp;!h.hasLayout)||(!h&amp;&amp;g.style.zoom==&quot;normal&quot;)){g.style.zoom=1}var k=g.getStyle(&quot;filter&quot;),l=g.style;if(j==1||j===&quot;&quot;){(k=i(k))?l.filter=k:l.removeAttribute(&quot;filter&quot;);return g}else{if(j&lt;0.00001){j=0}}l.filter=i(k)+&quot;alpha(opacity=&quot;+(j*100)+&quot;)&quot;;return g};Element._attributeTranslations={read:{names:{&quot;class&quot;:&quot;className&quot;,&quot;for&quot;:&quot;htmlFor&quot;},values:{_getAttr:function(d,c){return d.getAttribute(c,2)},_getAttrNode:function(e,f){var d=e.getAttributeNode(f);return d?d.value:&quot;&quot;},_getEv:function(d,c){c=d.getAttribute(c);return c?c.toString().slice(23,-2):null},_flag:function(d,c){return $(d).hasAttribute(c)?c:null},style:function(b){return b.style.cssText.toLowerCase()},title:function(b){return b.title}}}};Element._attributeTranslations.write={names:Object.extend({cellpadding:&quot;cellPadding&quot;,cellspacing:&quot;cellSpacing&quot;},Element._attributeTranslations.read.names),values:{checked:function(d,c){d.checked=!!c},style:function(d,c){d.style.cssText=c?c:&quot;&quot;}}};Element._attributeTranslations.has={};$w(&quot;colSpan rowSpan vAlign dateTime accessKey tabIndex encType maxLength readOnly longDesc&quot;).each(function(b){Element._attributeTranslations.write.names[b.toLowerCase()]=b;Element._attributeTranslations.has[b.toLowerCase()]=b});(function(b){Object.extend(b,{href:b._getAttr,src:b._getAttr,type:b._getAttr,action:b._getAttrNode,disabled:b._flag,checked:b._flag,readonly:b._flag,multiple:b._flag,onload:b._getEv,onunload:b._getEv,onclick:b._getEv,ondblclick:b._getEv,onmousedown:b._getEv,onmouseup:b._getEv,onmouseover:b._getEv,onmousemove:b._getEv,onmouseout:b._getEv,onfocus:b._getEv,onblur:b._getEv,onkeypress:b._getEv,onkeydown:b._getEv,onkeyup:b._getEv,onsubmit:b._getEv,onreset:b._getEv,onselect:b._getEv,onchange:b._getEv})})(Element._attributeTranslations.read.values)}else{if(Prototype.Browser.Gecko&amp;&amp;/rv:1\.8\.0/.test(navigator.userAgent)){Element.Methods.setOpacity=function(d,c){d=$(d);d.style.opacity=(c==1)?0.999999:(c===&quot;&quot;)?&quot;&quot;:(c&lt;0.00001)?0:c;return d}}else{if(Prototype.Browser.WebKit){Element.Methods.setOpacity=function(f,e){f=$(f);f.style.opacity=(e==1||e===&quot;&quot;)?&quot;&quot;:(e&lt;0.00001)?0:e;if(e==1){if(f.tagName==&quot;IMG&quot;&amp;&amp;f.width){f.width++;f.width--}else{try{var g=document.createTextNode(&quot; &quot;);f.appendChild(g);f.removeChild(g)}catch(h){}}}return f};Element.Methods.cumulativeOffset=function(d){var e=0,f=0;do{e+=d.offsetTop||0;f+=d.offsetLeft||0;if(d.offsetParent==document.body){if(Element.getStyle(d,&quot;position&quot;)==&quot;absolute&quot;){break}}d=d.offsetParent}while(d);return Element._returnOffset(f,e)}}}}}if(Prototype.Browser.IE||Prototype.Browser.Opera){Element.Methods.update=function(d,f){d=$(d);if(f&amp;&amp;f.toElement){f=f.toElement()}if(Object.isElement(f)){return d.update().insert(f)}f=Object.toHTML(f);var e=d.tagName.toUpperCase();if(e in Element._insertionTranslations.tags){$A(d.childNodes).each(function(a){d.removeChild(a)});Element._getContentFromAnonymousElement(e,f.stripScripts()).each(function(a){d.appendChild(a)})}else{d.innerHTML=f.stripScripts()}f.evalScripts.bind(f).defer();return d}}if(&quot;outerHTML&quot; in document.createElement(&quot;div&quot;)){Element.Methods.replace=function(l,j){l=$(l);if(j&amp;&amp;j.toElement){j=j.toElement()}if(Object.isElement(j)){l.parentNode.replaceChild(j,l);return l}j=Object.toHTML(j);var k=l.parentNode,g=k.tagName.toUpperCase();if(Element._insertionTranslations.tags[g]){var i=l.next();var h=Element._getContentFromAnonymousElement(g,j.stripScripts());k.removeChild(l);if(i){h.each(function(a){k.insertBefore(a,i)})}else{h.each(function(a){k.appendChild(a)})}}else{l.outerHTML=j.stripScripts()}j.evalScripts.bind(j).defer();return l}}Element._returnOffset=function(d,f){var e=[d,f];e.left=d;e.top=f;return e};Element._getContentFromAnonymousElement=function(h,e){var g=new Element(&quot;div&quot;),f=Element._insertionTranslations.tags[h];if(f){g.innerHTML=f[0]+e+f[1];f[2].times(function(){g=g.firstChild})}else{g.innerHTML=e}return $A(g.childNodes)};Element._insertionTranslations={before:function(d,c){d.parentNode.insertBefore(c,d)},top:function(d,c){d.insertBefore(c,d.firstChild)},bottom:function(d,c){d.appendChild(c)},after:function(d,c){d.parentNode.insertBefore(c,d.nextSibling)},tags:{TABLE:[&quot;&lt;table&gt;&quot;,&quot;&lt;/table&gt;&quot;,1],TBODY:[&quot;&lt;table&gt;&lt;tbody&gt;&quot;,&quot;&lt;/tbody&gt;&lt;/table&gt;&quot;,2],TR:[&quot;&lt;table&gt;&lt;tbody&gt;&lt;tr&gt;&quot;,&quot;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&quot;,3],TD:[&quot;&lt;table&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;&quot;,&quot;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&quot;,4],SELECT:[&quot;&lt;select&gt;&quot;,&quot;&lt;/select&gt;&quot;,1]}};(function(){Object.extend(this.tags,{THEAD:this.tags.TBODY,TFOOT:this.tags.TBODY,TH:this.tags.TD})}).call(Element._insertionTranslations);Element.Methods.Simulated={hasAttribute:function(e,f){f=Element._attributeTranslations.has[f]||f;var d=$(e).getAttributeNode(f);return d&amp;&amp;d.specified}};Element.Methods.ByTag={};Object.extend(Element,Element.Methods);if(!Prototype.BrowserFeatures.ElementExtensions&amp;&amp;document.createElement(&quot;div&quot;).__proto__){window.HTMLElement={};window.HTMLElement.prototype=document.createElement(&quot;div&quot;).__proto__;Prototype.BrowserFeatures.ElementExtensions=true}Element.extend=(function(){if(Prototype.BrowserFeatures.SpecificElementExtensions){return Prototype.K}var e={},d=Element.Methods.ByTag;var f=Object.extend(function(c){if(!c||c._extendedByPrototype||c.nodeType!=1||c==window){return c}var j=Object.clone(e),i=c.tagName,a,b;if(d[i]){Object.extend(j,d[i])}for(a in j){b=j[a];if(Object.isFunction(b)&amp;&amp;!(a in c)){c[a]=b.methodize()}}c._extendedByPrototype=Prototype.emptyFunction;return c},{refresh:function(){if(!Prototype.BrowserFeatures.ElementExtensions){Object.extend(e,Element.Methods);Object.extend(e,Element.Methods.Simulated)}}});f.refresh();return f})();Element.hasAttribute=function(d,c){if(d.hasAttribute){return d.hasAttribute(c)}return Element.Methods.Simulated.hasAttribute(d,c)};Element.addMethods=function(p){var k=Prototype.BrowserFeatures,o=Element.Methods.ByTag;if(!p){Object.extend(Form,Form.Methods);Object.extend(Form.Element,Form.Element.Methods);Object.extend(Element.Methods.ByTag,{FORM:Object.clone(Form.Methods),INPUT:Object.clone(Form.Element.Methods),SELECT:Object.clone(Form.Element.Methods),TEXTAREA:Object.clone(Form.Element.Methods)})}if(arguments.length==2){var q=p;p=arguments[1]}if(!q){Object.extend(Element.Methods,p||{})}else{if(Object.isArray(q)){q.each(l)}else{l(q)}}function l(a){a=a.toUpperCase();if(!Element.Methods.ByTag[a]){Element.Methods.ByTag[a]={}}Object.extend(Element.Methods.ByTag[a],p)}function r(b,c,d){d=d||false;for(var e in b){var a=b[e];if(!Object.isFunction(a)){continue}if(!d||!(e in c)){c[e]=a.methodize()}}}function n(a){var c;var b={OPTGROUP:&quot;OptGroup&quot;,TEXTAREA:&quot;TextArea&quot;,P:&quot;Paragraph&quot;,FIELDSET:&quot;FieldSet&quot;,UL:&quot;UList&quot;,OL:&quot;OList&quot;,DL:&quot;DList&quot;,DIR:&quot;Directory&quot;,H1:&quot;Heading&quot;,H2:&quot;Heading&quot;,H3:&quot;Heading&quot;,H4:&quot;Heading&quot;,H5:&quot;Heading&quot;,H6:&quot;Heading&quot;,Q:&quot;Quote&quot;,INS:&quot;Mod&quot;,DEL:&quot;Mod&quot;,A:&quot;Anchor&quot;,IMG:&quot;Image&quot;,CAPTION:&quot;TableCaption&quot;,COL:&quot;TableCol&quot;,COLGROUP:&quot;TableCol&quot;,THEAD:&quot;TableSection&quot;,TFOOT:&quot;TableSection&quot;,TBODY:&quot;TableSection&quot;,TR:&quot;TableRow&quot;,TH:&quot;TableCell&quot;,TD:&quot;TableCell&quot;,FRAMESET:&quot;FrameSet&quot;,IFRAME:&quot;IFrame&quot;};if(b[a]){c=&quot;HTML&quot;+b[a]+&quot;Element&quot;}if(window[c]){return window[c]}c=&quot;HTML&quot;+a+&quot;Element&quot;;if(window[c]){return window[c]}c=&quot;HTML&quot;+a.capitalize()+&quot;Element&quot;;if(window[c]){return window[c]}window[c]={};window[c].prototype=document.createElement(a).__proto__;return window[c]}if(k.ElementExtensions){r(Element.Methods,HTMLElement.prototype);r(Element.Methods.Simulated,HTMLElement.prototype,true)}if(k.SpecificElementExtensions){for(var j in Element.Methods.ByTag){var m=n(j);if(Object.isUndefined(m)){continue}r(o[j],m.prototype)}}Object.extend(Element,Element.Methods);delete Element.ByTag;if(Element.extend.refresh){Element.extend.refresh()}Element.cache={}};document.viewport={getDimensions:function(){var d={};var c=Prototype.Browser;$w(&quot;width height&quot;).each(function(a){var b=a.capitalize();d[a]=(c.WebKit&amp;&amp;!document.evaluate)?self[&quot;inner&quot;+b]:(c.Opera)?document.body[&quot;client&quot;+b]:document.documentElement[&quot;client&quot;+b]});return d},getWidth:function(){return this.getDimensions().width},getHeight:function(){return this.getDimensions().height},getScrollOffsets:function(){return Element._returnOffset(window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft,window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop)}};var Selector=Class.create({initialize:function(b){this.expression=b.strip();this.compileMatcher()},shouldUseXPath:function(){if(!Prototype.BrowserFeatures.XPath){return false}var b=this.expression;if(Prototype.Browser.WebKit&amp;&amp;(b.include(&quot;-of-type&quot;)||b.include(&quot;:empty&quot;))){return false}if((/(\[[\w-]*?:|:checked)/).test(this.expression)){return false}return true},compileMatcher:function(){if(this.shouldUseXPath()){return this.compileXPathMatcher()}var e=this.expression,ps=Selector.patterns,h=Selector.handlers,c=Selector.criteria,le,p,m;if(Selector._cache[e]){this.matcher=Selector._cache[e];return}this.matcher=[&quot;this.matcher = function(root) {&quot;,&quot;var r = root, h = Selector.handlers, c = false, n;&quot;];while(e&amp;&amp;le!=e&amp;&amp;(/\S/).test(e)){le=e;for(var i in ps){p=ps[i];if(m=e.match(p)){this.matcher.push(Object.isFunction(c[i])?c[i](m):new Template(c[i]).evaluate(m));e=e.replace(m[0],&quot;&quot;);break}}}this.matcher.push(&quot;return h.unique(n);\n}&quot;);eval(this.matcher.join(&quot;\n&quot;));Selector._cache[this.expression]=this.matcher},compileXPathMatcher:function(){var j=this.expression,i=Selector.patterns,e=Selector.xpath,k,h;if(Selector._cache[j]){this.xpath=Selector._cache[j];return}this.matcher=[&quot;.//*&quot;];while(j&amp;&amp;k!=j&amp;&amp;(/\S/).test(j)){k=j;for(var l in i){if(h=j.match(i[l])){this.matcher.push(Object.isFunction(e[l])?e[l](h):new Template(e[l]).evaluate(h));j=j.replace(h[0],&quot;&quot;);break}}}this.xpath=this.matcher.join(&quot;&quot;);Selector._cache[this.expression]=this.xpath},findElements:function(b){b=b||document;if(this.xpath){return document._getElementsByXPath(this.xpath,b)}return this.matcher(b)},match:function(q){this.tokens=[];var e=this.expression,x=Selector.patterns,t=Selector.assertions;var w,u,s;while(e&amp;&amp;w!==e&amp;&amp;(/\S/).test(e)){w=e;for(var p in x){u=x[p];if(s=e.match(u)){if(t[p]){this.tokens.push([p,Object.clone(s)]);e=e.replace(s[0],&quot;&quot;)}else{return this.findElements(document).include(q)}}}}var i=true,v,m;for(var p=0,r;r=this.tokens[p];p++){v=r[0],m=r[1];if(!Selector.assertions[v](q,m)){i=false;break}}return i},toString:function(){return this.expression},inspect:function(){return&quot;#&lt;Selector:&quot;+this.expression.inspect()+&quot;&gt;&quot;}});Object.extend(Selector,{_cache:{},xpath:{descendant:&quot;//*&quot;,child:&quot;/*&quot;,adjacent:&quot;/following-sibling::*[1]&quot;,laterSibling:&quot;/following-sibling::*&quot;,tagName:function(b){if(b[1]==&quot;*&quot;){return&quot;&quot;}return&quot;[local-name()='&quot;+b[1].toLowerCase()+&quot;' or local-name()='&quot;+b[1].toUpperCase()+&quot;']&quot;},className:&quot;[contains(concat(' ', @class, ' '), ' #{1} ')]&quot;,id:&quot;[@id='#{1}']&quot;,attrPresence:function(b){b[1]=b[1].toLowerCase();return new Template(&quot;[@#{1}]&quot;).evaluate(b)},attr:function(b){b[1]=b[1].toLowerCase();b[3]=b[5]||b[6];return new Template(Selector.xpath.operators[b[2]]).evaluate(b)},pseudo:function(d){var c=Selector.xpath.pseudos[d[1]];if(!c){return&quot;&quot;}if(Object.isFunction(c)){return c(d)}return new Template(Selector.xpath.pseudos[d[1]]).evaluate(d)},operators:{&quot;=&quot;:&quot;[@#{1}='#{3}']&quot;,&quot;!=&quot;:&quot;[@#{1}!='#{3}']&quot;,&quot;^=&quot;:&quot;[starts-with(@#{1}, '#{3}')]&quot;,&quot;$=&quot;:&quot;[substring(@#{1}, (string-length(@#{1}) - string-length('#{3}') + 1))='#{3}']&quot;,&quot;*=&quot;:&quot;[contains(@#{1}, '#{3}')]&quot;,&quot;~=&quot;:&quot;[contains(concat(' ', @#{1}, ' '), ' #{3} ')]&quot;,&quot;|=&quot;:&quot;[contains(concat('-', @#{1}, '-'), '-#{3}-')]&quot;},pseudos:{&quot;first-child&quot;:&quot;[not(preceding-sibling::*)]&quot;,&quot;last-child&quot;:&quot;[not(following-sibling::*)]&quot;,&quot;only-child&quot;:&quot;[not(preceding-sibling::* or following-sibling::*)]&quot;,empty:&quot;[count(*) = 0 and (count(text()) = 0 or translate(text(), ' \t\r\n', '') = '')]&quot;,checked:&quot;[@checked]&quot;,disabled:&quot;[@disabled]&quot;,enabled:&quot;[not(@disabled)]&quot;,not:function(e){var k=e[6],l=Selector.patterns,i=Selector.xpath,n,p;var m=[];while(k&amp;&amp;n!=k&amp;&amp;(/\S/).test(k)){n=k;for(var o in l){if(e=k.match(l[o])){p=Object.isFunction(i[o])?i[o](e):new Template(i[o]).evaluate(e);m.push(&quot;(&quot;+p.substring(1,p.length-1)+&quot;)&quot;);k=k.replace(e[0],&quot;&quot;);break}}}return&quot;[not(&quot;+m.join(&quot; and &quot;)+&quot;)]&quot;},&quot;nth-child&quot;:function(b){return Selector.xpath.pseudos.nth(&quot;(count(./preceding-sibling::*) + 1) &quot;,b)},&quot;nth-last-child&quot;:function(b){return Selector.xpath.pseudos.nth(&quot;(count(./following-sibling::*) + 1) &quot;,b)},&quot;nth-of-type&quot;:function(b){return Selector.xpath.pseudos.nth(&quot;position() &quot;,b)},&quot;nth-last-of-type&quot;:function(b){return Selector.xpath.pseudos.nth(&quot;(last() + 1 - position()) &quot;,b)},&quot;first-of-type&quot;:function(b){b[6]=&quot;1&quot;;return Selector.xpath.pseudos[&quot;nth-of-type&quot;](b)},&quot;last-of-type&quot;:function(b){b[6]=&quot;1&quot;;return Selector.xpath.pseudos[&quot;nth-last-of-type&quot;](b)},&quot;only-of-type&quot;:function(d){var c=Selector.xpath.pseudos;return c[&quot;first-of-type&quot;](d)+c[&quot;last-of-type&quot;](d)},nth:function(j,l){var b,a=l[6],m;if(a==&quot;even&quot;){a=&quot;2n+0&quot;}if(a==&quot;odd&quot;){a=&quot;2n+1&quot;}if(b=a.match(/^(\d+)$/)){return&quot;[&quot;+j+&quot;= &quot;+b[1]+&quot;]&quot;}if(b=a.match(/^(-?\d*)?n(([+-])(\d+))?/)){if(b[1]==&quot;-&quot;){b[1]=-1}var k=b[1]?Number(b[1]):1;var n=b[2]?Number(b[2]):0;m=&quot;[((#{fragment} - #{b}) mod #{a} = 0) and ((#{fragment} - #{b}) div #{a} &gt;= 0)]&quot;;return new Template(m).evaluate({fragment:j,a:k,b:n})}}}},criteria:{tagName:'n = h.tagName(n, r, &quot;#{1}&quot;, c);      c = false;',className:'n = h.className(n, r, &quot;#{1}&quot;, c);    c = false;',id:'n = h.id(n, r, &quot;#{1}&quot;, c);           c = false;',attrPresence:'n = h.attrPresence(n, r, &quot;#{1}&quot;, c); c = false;',attr:function(b){b[3]=(b[5]||b[6]);return new Template('n = h.attr(n, r, &quot;#{1}&quot;, &quot;#{3}&quot;, &quot;#{2}&quot;, c); c = false;').evaluate(b)},pseudo:function(b){if(b[6]){b[6]=b[6].replace(/&quot;/g,'\\&quot;')}return new Template('n = h.pseudo(n, &quot;#{1}&quot;, &quot;#{6}&quot;, r, c); c = false;').evaluate(b)},descendant:'c = &quot;descendant&quot;;',child:'c = &quot;child&quot;;',adjacent:'c = &quot;adjacent&quot;;',laterSibling:'c = &quot;laterSibling&quot;;'},patterns:{laterSibling:/^\s*~\s*/,child:/^\s*&gt;\s*/,adjacent:/^\s*\+\s*/,descendant:/^\s/,tagName:/^\s*(\*|[\w\-]+)(\b|$)?/,id:/^#([\w\-\*]+)(\b|$)/,className:/^\.([\w\-\*]+)(\b|$)/,pseudo:/^:((first|last|nth|nth-last|only)(-child|-of-type)|empty|checked|(en|dis)abled|not)(\((.*?)\))?(\b|$|(?=\s|[:+~&gt;]))/,attrPresence:/^\[([\w]+)\]/,attr:/\[((?:[\w-]*:)?[\w-]+)\s*(?:([!^$*~|]?=)\s*((['&quot;])([^\4]*?)\4|([^'&quot;][^\]]*?)))?\]/},assertions:{tagName:function(d,c){return c[1].toUpperCase()==d.tagName.toUpperCase()},className:function(d,c){return Element.hasClassName(d,c[1])},id:function(d,c){return d.id===c[1]},attrPresence:function(d,c){return Element.hasAttribute(d,c[1])},attr:function(d,f){var e=Element.readAttribute(d,f[1]);return e&amp;&amp;Selector.operators[f[2]](e,f[5]||f[6])}},handlers:{concat:function(g,h){for(var b=0,a;a=h[b];b++){g.push(a)}return g},mark:function(f){var g=Prototype.emptyFunction;for(var e=0,h;h=f[e];e++){h._countedByPrototype=g}return f},unmark:function(e){for(var d=0,f;f=e[d];d++){f._countedByPrototype=undefined}return e},index:function(i,m,j){i._countedByPrototype=Prototype.emptyFunction;if(m){for(var h=i.childNodes,l=h.length-1,n=1;l&gt;=0;l--){var k=h[l];if(k.nodeType==1&amp;&amp;(!j||k._countedByPrototype)){k.nodeIndex=n++}}}else{for(var l=0,n=1,h=i.childNodes;k=h[l];l++){if(k.nodeType==1&amp;&amp;(!j||k._countedByPrototype)){k.nodeIndex=n++}}}},unique:function(f){if(f.length==0){return f}var i=[],h;for(var j=0,g=f.length;j&lt;g;j++){if(!(h=f[j])._countedByPrototype){h._countedByPrototype=Prototype.emptyFunction;i.push(Element.extend(h))}}return Selector.handlers.unmark(i)},descendant:function(g){var i=Selector.handlers;for(var j=0,f=[],h;h=g[j];j++){i.concat(f,h.getElementsByTagName(&quot;*&quot;))}return f},child:function(i){var l=Selector.handlers;for(var m=0,n=[],k;k=i[m];m++){for(var h=0,j;j=k.childNodes[h];h++){if(j.nodeType==1&amp;&amp;j.tagName!=&quot;!&quot;){n.push(j)}}}return n},adjacent:function(g){for(var j=0,f=[],h;h=g[j];j++){var i=this.nextElementSibling(h);if(i){f.push(i)}}return f},laterSibling:function(g){var i=Selector.handlers;for(var j=0,f=[],h;h=g[j];j++){i.concat(f,Element.nextSiblings(h))}return f},nextElementSibling:function(b){while(b=b.nextSibling){if(b.nodeType==1){return b}}return null},previousElementSibling:function(b){while(b=b.previousSibling){if(b.nodeType==1){return b}}return null},tagName:function(r,i,p,q){var h=p.toUpperCase();var n=[],l=Selector.handlers;if(r){if(q){if(q==&quot;descendant&quot;){for(var m=0,o;o=r[m];m++){l.concat(n,o.getElementsByTagName(p))}return n}else{r=this[q](r)}if(p==&quot;*&quot;){return r}}for(var m=0,o;o=r[m];m++){if(o.tagName.toUpperCase()===h){n.push(o)}}return n}else{return i.getElementsByTagName(p)}},id:function(h,i,k,m){var l=$(k),o=Selector.handlers;if(!l){return[]}if(!h&amp;&amp;i==document){return[l]}if(h){if(m){if(m==&quot;child&quot;){for(var p=0,n;n=h[p];p++){if(l.parentNode==n){return[l]}}}else{if(m==&quot;descendant&quot;){for(var p=0,n;n=h[p];p++){if(Element.descendantOf(l,n)){return[l]}}}else{if(m==&quot;adjacent&quot;){for(var p=0,n;n=h[p];p++){if(Selector.handlers.previousElementSibling(l)==n){return[l]}}}else{h=o[m](h)}}}}for(var p=0,n;n=h[p];p++){if(n==l){return[l]}}return[]}return(l&amp;&amp;Element.descendantOf(l,i))?[l]:[]},className:function(e,f,h,g){if(e&amp;&amp;g){e=this[g](e)}return Selector.handlers.byClassName(e,f,h)},byClassName:function(p,i,m){if(!p){p=Selector.handlers.descendant([i])}var k=&quot; &quot;+m+&quot; &quot;;for(var n=0,o=[],l,j;l=p[n];n++){j=l.className;if(j.length==0){continue}if(j==m||(&quot; &quot;+j+&quot; &quot;).include(k)){o.push(l)}}return o},attrPresence:function(n,h,i,j){if(!n){n=h.getElementsByTagName(&quot;*&quot;)}if(n&amp;&amp;j){n=this[j](n)}var l=[];for(var m=0,k;k=n[m];m++){if(Element.hasAttribute(k,i)){l.push(k)}}return l},attr:function(v,n,o,m,t,u){if(!v){v=n.getElementsByTagName(&quot;*&quot;)}if(v&amp;&amp;u){v=this[u](v)}var i=Selector.operators[t],q=[];for(var r=0,s;s=v[r];r++){var p=Element.readAttribute(s,o);if(p===null){continue}if(i(p,m)){q.push(s)}}return q},pseudo:function(f,j,h,g,i){if(f&amp;&amp;i){f=this[i](f)}if(!f){f=g.getElementsByTagName(&quot;*&quot;)}return Selector.pseudos[j](f,h,g)}},pseudos:{&quot;first-child&quot;:function(g,i,h){for(var k=0,l=[],j;j=g[k];k++){if(Selector.handlers.previousElementSibling(j)){continue}l.push(j)}return l},&quot;last-child&quot;:function(g,i,h){for(var k=0,l=[],j;j=g[k];k++){if(Selector.handlers.nextElementSibling(j)){continue}l.push(j)}return l},&quot;only-child&quot;:function(h,j,i){var l=Selector.handlers;for(var m=0,n=[],k;k=h[m];m++){if(!l.previousElementSibling(k)&amp;&amp;!l.nextElementSibling(k)){n.push(k)}}return n},&quot;nth-child&quot;:function(d,f,e){return Selector.pseudos.nth(d,f,e)},&quot;nth-last-child&quot;:function(d,f,e){return Selector.pseudos.nth(d,f,e,true)},&quot;nth-of-type&quot;:function(d,f,e){return Selector.pseudos.nth(d,f,e,false,true)},&quot;nth-last-of-type&quot;:function(d,f,e){return Selector.pseudos.nth(d,f,e,true,true)},&quot;first-of-type&quot;:function(d,f,e){return Selector.pseudos.nth(d,&quot;1&quot;,e,false,true)},&quot;last-of-type&quot;:function(d,f,e){return Selector.pseudos.nth(d,&quot;1&quot;,e,true,true)},&quot;only-of-type&quot;:function(e,g,f){var h=Selector.pseudos;return h[&quot;last-of-type&quot;](h[&quot;first-of-type&quot;](e,g,f),g,f)},getIndices:function(b,f,a){if(b==0){return f&gt;0?[f]:[]}return $R(1,a).inject([],function(d,c){if(0==(c-f)%b&amp;&amp;(c-f)/b&gt;=0){d.push(c)}return d})},nth:function(A,F,D,a,y){if(A.length==0){return[]}if(F==&quot;even&quot;){F=&quot;2n+0&quot;}if(F==&quot;odd&quot;){F=&quot;2n+1&quot;}var b=Selector.handlers,h=[],z=[],m;b.mark(A);for(var i=0,x;x=A[i];i++){if(!x.parentNode._countedByPrototype){b.index(x.parentNode,a,y);z.push(x.parentNode)}}if(F.match(/^\d+$/)){F=Number(F);for(var i=0,x;x=A[i];i++){if(x.nodeIndex==F){h.push(x)}}}else{if(m=F.match(/^(-?\d*)?n(([+-])(\d+))?/)){if(m[1]==&quot;-&quot;){m[1]=-1}var C=m[1]?Number(m[1]):1;var E=m[2]?Number(m[2]):0;var B=Selector.pseudos.getIndices(C,E,A.length);for(var i=0,x,l=B.length;x=A[i];i++){for(var j=0;j&lt;l;j++){if(x.nodeIndex==B[j]){h.push(x)}}}}}b.unmark(A);b.unmark(z);return h},empty:function(g,i,h){for(var k=0,l=[],j;j=g[k];k++){if(j.tagName==&quot;!&quot;||(j.firstChild&amp;&amp;!j.innerHTML.match(/^\s*$/))){continue}l.push(j)}return l},not:function(t,q,i){var n=Selector.handlers,h,r;var m=new Selector(q).findElements(i);n.mark(m);for(var o=0,p=[],s;s=t[o];o++){if(!s._countedByPrototype){p.push(s)}}n.unmark(m);return p},enabled:function(g,i,h){for(var k=0,l=[],j;j=g[k];k++){if(!j.disabled){l.push(j)}}return l},disabled:function(g,i,h){for(var k=0,l=[],j;j=g[k];k++){if(j.disabled){l.push(j)}}return l},checked:function(g,i,h){for(var k=0,l=[],j;j=g[k];k++){if(j.checked){l.push(j)}}return l}},operators:{&quot;=&quot;:function(c,d){return c==d},&quot;!=&quot;:function(c,d){return c!=d},&quot;^=&quot;:function(c,d){return c.startsWith(d)},&quot;$=&quot;:function(c,d){return c.endsWith(d)},&quot;*=&quot;:function(c,d){return c.include(d)},&quot;~=&quot;:function(c,d){return(&quot; &quot;+c+&quot; &quot;).include(&quot; &quot;+d+&quot; &quot;)},&quot;|=&quot;:function(c,d){return(&quot;-&quot;+c.toUpperCase()+&quot;-&quot;).include(&quot;-&quot;+d.toUpperCase()+&quot;-&quot;)}},split:function(c){var d=[];c.scan(/(([\w#:.~&gt;+()\s-]+|\*|\[.*?\])+)\s*(,|$)/,function(a){d.push(a[1].strip())});return d},matchElements:function(k,j){var l=$$(j),m=Selector.handlers;m.mark(l);for(var n=0,h=[],i;i=k[n];n++){if(i._countedByPrototype){h.push(i)}}m.unmark(l);return h},findElement:function(d,f,e){if(Object.isNumber(f)){e=f;f=false}return Selector.matchElements(d,f||&quot;*&quot;)[e||0]},findChildElements:function(l,j){j=Selector.split(j.join(&quot;,&quot;));var m=[],k=Selector.handlers;for(var n=0,h=j.length,i;n&lt;h;n++){i=new Selector(j[n].strip());k.concat(m,i.findElements(l))}return(h&gt;1)?k.unique(m):m}});if(Prototype.Browser.IE){Object.extend(Selector.handlers,{concat:function(g,h){for(var b=0,a;a=h[b];b++){if(a.tagName!==&quot;!&quot;){g.push(a)}}return g},unmark:function(e){for(var d=0,f;f=e[d];d++){f.removeAttribute(&quot;_countedByPrototype&quot;)}return e}})}function $$(){return Selector.findChildElements(document,$A(arguments))}var Form={reset:function(b){$(b).reset();return b},serializeElements:function(j,h){if(typeof h!=&quot;object&quot;){h={hash:!!h}}else{if(Object.isUndefined(h.hash)){h.hash=true}}var n,k,i=false,l=h.submit;var m=j.inject({},function(b,a){if(!a.disabled&amp;&amp;a.name){n=a.name;k=$(a).getValue();if(k!=null&amp;&amp;(a.type!=&quot;submit&quot;||(!i&amp;&amp;l!==false&amp;&amp;(!l||n==l)&amp;&amp;(i=true)))){if(n in b){if(!Object.isArray(b[n])){b[n]=[b[n]]}b[n].push(k)}else{b[n]=k}}}return b});return h.hash?m:Object.toQueryString(m)}};Form.Methods={serialize:function(c,d){return Form.serializeElements(Form.getElements(c),d)},getElements:function(b){return $A($(b).getElementsByTagName(&quot;*&quot;)).inject([],function(a,d){if(Form.Element.Serializers[d.tagName.toLowerCase()]){a.push(Element.extend(d))}return a})},getInputs:function(l,p,o){l=$(l);var j=l.getElementsByTagName(&quot;input&quot;);if(!p&amp;&amp;!o){return $A(j).map(Element.extend)}for(var n=0,k=[],m=j.length;n&lt;m;n++){var i=j[n];if((p&amp;&amp;i.type!=p)||(o&amp;&amp;i.name!=o)){continue}k.push(Element.extend(i))}return k},disable:function(b){b=$(b);Form.getElements(b).invoke(&quot;disable&quot;);return b},enable:function(b){b=$(b);Form.getElements(b).invoke(&quot;enable&quot;);return b},findFirstElement:function(d){var f=$(d).getElements().findAll(function(a){return&quot;hidden&quot;!=a.type&amp;&amp;!a.disabled});var e=f.findAll(function(a){return a.hasAttribute(&quot;tabIndex&quot;)&amp;&amp;a.tabIndex&gt;=0}).sortBy(function(a){return a.tabIndex}).first();return e?e:f.find(function(a){return[&quot;input&quot;,&quot;select&quot;,&quot;textarea&quot;].include(a.tagName.toLowerCase())})},focusFirstElement:function(b){b=$(b);b.findFirstElement().activate();return b},request:function(e,f){e=$(e),f=Object.clone(f||{});var g=f.parameters,h=e.readAttribute(&quot;action&quot;)||&quot;&quot;;if(h.blank()){h=window.location.href}f.parameters=e.serialize(true);if(g){if(Object.isString(g)){g=g.toQueryParams()}Object.extend(f.parameters,g)}if(e.hasAttribute(&quot;method&quot;)&amp;&amp;!f.method){f.method=e.method}return new Ajax.Request(h,f)}};Form.Element={focus:function(b){$(b).focus();return b},select:function(b){$(b).select();return b}};Form.Element.Methods={serialize:function(e){e=$(e);if(!e.disabled&amp;&amp;e.name){var d=e.getValue();if(d!=undefined){var f={};f[e.name]=d;return Object.toQueryString(f)}}return&quot;&quot;},getValue:function(d){d=$(d);var c=d.tagName.toLowerCase();return Form.Element.Serializers[c](d)},setValue:function(e,d){e=$(e);var f=e.tagName.toLowerCase();Form.Element.Serializers[f](e,d);return e},clear:function(b){$(b).value=&quot;&quot;;return b},present:function(b){return $(b).value!=&quot;&quot;},activate:function(d){d=$(d);try{d.focus();if(d.select&amp;&amp;(d.tagName.toLowerCase()!=&quot;input&quot;||![&quot;button&quot;,&quot;reset&quot;,&quot;submit&quot;].include(d.type))){d.select()}}catch(c){}return d},disable:function(b){b=$(b);b.blur();b.disabled=true;return b},enable:function(b){b=$(b);b.disabled=false;return b}};var Field=Form.Element;var $F=Form.Element.Methods.getValue;Form.Element.Serializers={input:function(d,c){switch(d.type.toLowerCase()){case&quot;checkbox&quot;:case&quot;radio&quot;:return Form.Element.Serializers.inputSelector(d,c);default:return Form.Element.Serializers.textarea(d,c)}},inputSelector:function(d,c){if(Object.isUndefined(c)){return d.checked?d.value:null}else{d.checked=!!c}},textarea:function(d,c){if(Object.isUndefined(c)){return d.value}else{d.value=c}},select:function(m,i){if(Object.isUndefined(i)){return this[m.type==&quot;select-one&quot;?&quot;selectOne&quot;:&quot;selectMany&quot;](m)}else{var n,k,j=!Object.isArray(i);for(var h=0,l=m.length;h&lt;l;h++){n=m.options[h];k=this.optionValue(n);if(j){if(k==i){n.selected=true;return}}else{n.selected=i.include(k)}}}},selectOne:function(c){var d=c.selectedIndex;return d&gt;=0?this.optionValue(c.options[d]):null},selectMany:function(i){var g,h=i.length;if(!h){return null}for(var j=0,g=[];j&lt;h;j++){var f=i.options[j];if(f.selected){g.push(this.optionValue(f))}}return g},optionValue:function(b){return Element.extend(b).hasAttribute(&quot;value&quot;)?b.value:b.text}};Abstract.TimedObserver=Class.create(PeriodicalExecuter,{initialize:function($super,e,d,f){$super(f,d);this.element=$(e);this.lastValue=this.getValue()},execute:function(){var b=this.getValue();if(Object.isString(this.lastValue)&amp;&amp;Object.isString(b)?this.lastValue!=b:String(this.lastValue)!=String(b)){this.callback(this.element,b);this.lastValue=b}}});Form.Element.Observer=Class.create(Abstract.TimedObserver,{getValue:function(){return Form.Element.getValue(this.element)}});Form.Observer=Class.create(Abstract.TimedObserver,{getValue:function(){return Form.serialize(this.element)}});Abstract.EventObserver=Class.create({initialize:function(d,c){this.element=$(d);this.callback=c;this.lastValue=this.getValue();if(this.element.tagName.toLowerCase()==&quot;form&quot;){this.registerFormCallbacks()}else{this.registerCallback(this.element)}},onElementEvent:function(){var b=this.getValue();if(this.lastValue!=b){this.callback(this.element,b);this.lastValue=b}},registerFormCallbacks:function(){Form.getElements(this.element).each(this.registerCallback,this)},registerCallback:function(b){if(b.type){switch(b.type.toLowerCase()){case&quot;checkbox&quot;:case&quot;radio&quot;:Event.observe(b,&quot;click&quot;,this.onElementEvent.bind(this));break;default:Event.observe(b,&quot;change&quot;,this.onElementEvent.bind(this));break}}}});Form.Element.EventObserver=Class.create(Abstract.EventObserver,{getValue:function(){return Form.Element.getValue(this.element)}});Form.EventObserver=Class.create(Abstract.EventObserver,{getValue:function(){return Form.serialize(this.element)}});if(!window.Event){var Event={}}Object.extend(Event,{KEY_BACKSPACE:8,KEY_TAB:9,KEY_RETURN:13,KEY_ESC:27,KEY_LEFT:37,KEY_UP:38,KEY_RIGHT:39,KEY_DOWN:40,KEY_DELETE:46,KEY_HOME:36,KEY_END:35,KEY_PAGEUP:33,KEY_PAGEDOWN:34,KEY_INSERT:45,cache:{},relatedTarget:function(c){var d;switch(c.type){case&quot;mouseover&quot;:d=c.fromElement;break;case&quot;mouseout&quot;:d=c.toElement;break;default:return null}return Element.extend(d)}});Event.Methods=(function(){var d;if(Prototype.Browser.IE){var c={0:1,1:4,2:2};d=function(a,b){return a.button==c[b]}}else{if(Prototype.Browser.WebKit){d=function(a,b){switch(b){case 0:return a.which==1&amp;&amp;!a.metaKey;case 1:return a.which==1&amp;&amp;a.metaKey;default:return false}}}else{d=function(a,b){return a.which?(a.which===b+1):(a.button===b)}}}return{isLeftClick:function(a){return d(a,0)},isMiddleClick:function(a){return d(a,1)},isRightClick:function(a){return d(a,2)},element:function(a){var b=Event.extend(a).target;return Element.extend(b.nodeType==Node.TEXT_NODE?b.parentNode:b)},findElement:function(g,a){var h=Event.element(g);if(!a){return h}var b=[h].concat(h.ancestors());return Selector.findElement(b,a,0)},pointer:function(a){return{x:a.pageX||(a.clientX+(document.documentElement.scrollLeft||document.body.scrollLeft)),y:a.pageY||(a.clientY+(document.documentElement.scrollTop||document.body.scrollTop))}},pointerX:function(a){return Event.pointer(a).x},pointerY:function(a){return Event.pointer(a).y},stop:function(a){Event.extend(a);a.preventDefault();a.stopPropagation();a.stopped=true}}})();Event.extend=(function(){var b=Object.keys(Event.Methods).inject({},function(a,d){a[d]=Event.Methods[d].methodize();return a});if(Prototype.Browser.IE){Object.extend(b,{stopPropagation:function(){this.cancelBubble=true},preventDefault:function(){this.returnValue=false},inspect:function(){return&quot;[object Event]&quot;}});return function(a){if(!a){return false}if(a._extendedByPrototype){return a}a._extendedByPrototype=Prototype.emptyFunction;var d=Event.pointer(a);Object.extend(a,{target:a.srcElement,relatedTarget:Event.relatedTarget(a),pageX:d.x,pageY:d.y});return Object.extend(a,b)}}else{Event.prototype=Event.prototype||document.createEvent(&quot;HTMLEvents&quot;).__proto__;Object.extend(Event.prototype,b);return Prototype.K}})();Object.extend(Event,(function(){var q=Event.cache;function p(a){if(a._prototypeEventID){return a._prototypeEventID[0]}arguments.callee.id=arguments.callee.id||1;return a._prototypeEventID=[++arguments.callee.id]}function l(a){if(a&amp;&amp;a.include(&quot;:&quot;)){return&quot;dataavailable&quot;}return a}function r(a){return q[a]=q[a]||{}}function m(a,c){var b=r(a);return b[c]=b[c]||[]}function k(c,d,b){var e=p(c);var f=m(e,d);if(f.pluck(&quot;handler&quot;).include(b)){return false}var a=function(g){if(!Event||!Event.extend||(g.eventName&amp;&amp;g.eventName!=d)){return false}Event.extend(g);b.call(c,g)};a.handler=b;f.push(a);return a}function j(a,d,c){var b=m(a,d);return b.find(function(e){return e.handler==c})}function o(a,d,c){var b=r(a);if(!b[d]){return false}b[d]=b[d].without(j(a,d,c))}function n(){for(var a in q){for(var b in q[a]){q[a][b]=null}}}if(window.attachEvent){window.attachEvent(&quot;onunload&quot;,n)}return{observe:function(b,d,a){b=$(b);var c=l(d);var e=k(b,d,a);if(!e){return b}if(b.addEventListener){b.addEventListener(c,e,false)}else{b.attachEvent(&quot;on&quot;+c,e)}return b},stopObserving:function(b,d,a){b=$(b);var e=p(b),c=l(d);if(!a&amp;&amp;d){m(e,d).each(function(g){b.stopObserving(d,g.handler)});return b}else{if(!d){Object.keys(r(e)).each(function(g){b.stopObserving(g)});return b}}var f=j(e,d,a);if(!f){return b}if(b.removeEventListener){b.removeEventListener(c,f,false)}else{b.detachEvent(&quot;on&quot;+c,f)}o(e,d,a);return b},fire:function(b,c,d){b=$(b);if(b==document&amp;&amp;document.createEvent&amp;&amp;!b.dispatchEvent){b=document.documentElement}var a;if(document.createEvent){a=document.createEvent(&quot;HTMLEvents&quot;);a.initEvent(&quot;dataavailable&quot;,true,true)}else{a=document.createEventObject();a.eventType=&quot;ondataavailable&quot;}a.eventName=c;a.memo=d||{};if(document.createEvent){b.dispatchEvent(a)}else{b.fireEvent(a.eventType,a)}return Event.extend(a)}}})());Object.extend(Event,Event.Methods);Element.addMethods({fire:Event.fire,observe:Event.observe,stopObserving:Event.stopObserving});Object.extend(document,{fire:Element.Methods.fire.methodize(),observe:Element.Methods.observe.methodize(),stopObserving:Element.Methods.stopObserving.methodize(),loaded:false});(function(){var c;function d(){if(document.loaded){return}if(c){window.clearInterval(c)}document.fire(&quot;dom:loaded&quot;);document.loaded=true}if(document.addEventListener){if(Prototype.Browser.WebKit){c=window.setInterval(function(){if(/loaded|complete/.test(document.readyState)){d()}},0);Event.observe(window,&quot;load&quot;,d)}else{document.addEventListener(&quot;DOMContentLoaded&quot;,d,false)}}else{document.write(&quot;&lt;script id=__onDOMContentLoaded defer src=//:&gt;&lt;\/script&gt;&quot;);$(&quot;__onDOMContentLoaded&quot;).onreadystatechange=function(){if(this.readyState==&quot;complete&quot;){this.onreadystatechange=null;d()}}}})();Hash.toQueryString=Object.toQueryString;var Toggle={display:Element.toggle};Element.Methods.childOf=Element.Methods.descendantOf;var Insertion={Before:function(d,c){return Element.insert(d,{before:c})},Top:function(d,c){return Element.insert(d,{top:c})},Bottom:function(d,c){return Element.insert(d,{bottom:c})},After:function(d,c){return Element.insert(d,{after:c})}};var $continue=new Error('&quot;throw $continue&quot; is deprecated, use &quot;return&quot; instead');var Position={includeScrollOffsets:false,prepare:function(){this.deltaX=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0;this.deltaY=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0},within:function(d,e,f){if(this.includeScrollOffsets){return this.withinIncludingScrolloffsets(d,e,f)}this.xcomp=e;this.ycomp=f;this.offset=Element.cumulativeOffset(d);return(f&gt;=this.offset[1]&amp;&amp;f&lt;this.offset[1]+d.offsetHeight&amp;&amp;e&gt;=this.offset[0]&amp;&amp;e&lt;this.offset[0]+d.offsetWidth)},withinIncludingScrolloffsets:function(e,f,g){var h=Element.cumulativeScrollOffset(e);this.xcomp=f+h[0]-this.deltaX;this.ycomp=g+h[1]-this.deltaY;this.offset=Element.cumulativeOffset(e);return(this.ycomp&gt;=this.offset[1]&amp;&amp;this.ycomp&lt;this.offset[1]+e.offsetHeight&amp;&amp;this.xcomp&gt;=this.offset[0]&amp;&amp;this.xcomp&lt;this.offset[0]+e.offsetWidth)},overlap:function(c,d){if(!c){return 0}if(c==&quot;vertical&quot;){return((this.offset[1]+d.offsetHeight)-this.ycomp)/d.offsetHeight}if(c==&quot;horizontal&quot;){return((this.offset[0]+d.offsetWidth)-this.xcomp)/d.offsetWidth}},cumulativeOffset:Element.Methods.cumulativeOffset,positionedOffset:Element.Methods.positionedOffset,absolutize:function(b){Position.prepare();return Element.absolutize(b)},relativize:function(b){Position.prepare();return Element.relativize(b)},realOffset:Element.Methods.cumulativeScrollOffset,offsetParent:Element.Methods.getOffsetParent,page:Element.Methods.viewportOffset,clone:function(d,f,e){e=e||{};return Element.clonePosition(f,d,e)}};if(!document.getElementsByClassName){document.getElementsByClassName=function(c){function d(a){return a.blank()?null:&quot;[contains(concat(' ', @class, ' '), ' &quot;+a+&quot; ')]&quot;}c.getElementsByClassName=Prototype.BrowserFeatures.XPath?function(f,a){a=a.toString().strip();var b=/\s/.test(a)?$w(a).map(d).join(&quot;&quot;):d(a);return b?document._getElementsByXPath(&quot;.//*&quot;+b,f):[]}:function(n,m){m=m.toString().strip();var l=[],i=(/\s/.test(m)?$w(m):null);if(!i&amp;&amp;!m){return l}var p=$(n).getElementsByTagName(&quot;*&quot;);m=&quot; &quot;+m+&quot; &quot;;for(var o=0,a,b;a=p[o];o++){if(a.className&amp;&amp;(b=&quot; &quot;+a.className+&quot; &quot;)&amp;&amp;(b.include(m)||(i&amp;&amp;i.all(function(e){return !e.toString().blank()&amp;&amp;b.include(&quot; &quot;+e+&quot; &quot;)})))){l.push(Element.extend(a))}}return l};return function(a,b){return $(b||document.body).getElementsByClassName(a)}}(Element.Methods)}Element.ClassNames=Class.create();Element.ClassNames.prototype={initialize:function(b){this.element=$(b)},_each:function(b){this.element.className.split(/\s+/).select(function(a){return a.length&gt;0})._each(b)},set:function(b){this.element.className=b},add:function(b){if(this.include(b)){return}this.set($A(this).concat(b).join(&quot; &quot;))},remove:function(b){if(!this.include(b)){return}this.set($A(this).without(b).join(&quot; &quot;))},toString:function(){return $A(this).join(&quot; &quot;)}};Object.extend(Element.ClassNames.prototype,Enumerable);Element.addMethods();
\ No newline at end of file</diff>
      <filename>test/data/javascripts/prototype.js</filename>
    </modified>
    <modified>
      <filename>test/data/stompers/stompable.js</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>96f75170d527997ee6a6b8bb73f9c702f56cdafc</id>
    </parent>
  </parents>
  <author>
    <name>Cory ODaniel</name>
    <email>git@coryodaniel.com</email>
  </author>
  <url>http://github.com/coryodaniel/ruby-yui/commit/37c02b20b149f669d28f7ef4e04791640b891bf4</url>
  <id>37c02b20b149f669d28f7ef4e04791640b891bf4</id>
  <committed-date>2009-06-08T15:09:17-07:00</committed-date>
  <authored-date>2009-06-08T15:09:17-07:00</authored-date>
  <message>Support for compressing single files and strings</message>
  <tree>daaa48ce6d96f7ef0b6d1e47b97393a6120965d7</tree>
  <committer>
    <name>Cory ODaniel</name>
    <email>git@coryodaniel.com</email>
  </committer>
</commit>
