Bläddra i källkod

Examples: Fix minor search bugs.

Mugen87 5 år sedan
förälder
incheckning
5e06932ae3
1 ändrade filer med 2 tillägg och 1 borttagningar
  1. 2 1
      examples/index.html

+ 2 - 1
examples/index.html

@@ -231,6 +231,7 @@
 		function updateFilter() {
 
 			var v = filterInput.value.trim();
+			v = v.replace( /\s+/gi, ' ' ); // replace multiple whitespaces with a single one
 
 			if ( v !== '' ) {
 
@@ -340,7 +341,7 @@
 
 			if ( p !== - 1 ) {
 
-				return window.location.search.substr( 3 );
+				return decodeURI( window.location.search.substr( 3 ) );
 
 			}