Apache Solr open-source search software
SOLR-4949: UI Analysis page dropping characters from input box
Stefan Matheis9dab69c2570d
diff --git a/solr/CHANGES.txt b/solr/CHANGES.txtindex c3465d2d44a..dca1df00393 100644--- a/solr/CHANGES.txt+++ b/solr/CHANGES.txt@@ -190,6 +190,8 @@ Bug Fixes* SOLR-4456: Admin UI: Displays dashboard even if Solr is down (steffkes)+* SOLR-4949: UI Analysis page dropping characters from input box (steffkes)+Optimizations----------------------diff --git a/solr/webapp/web/js/scripts/analysis.js b/solr/webapp/web/js/scripts/analysis.jsindex 9186439a5fc..ed9613c896f 100644--- a/solr/webapp/web/js/scripts/analysis.js+++ b/solr/webapp/web/js/scripts/analysis.js@@ -129,7 +129,7 @@ sammy.get{fields++;$( '[name="' + key + '"]', analysis_form )- .val( context.params[key].replace( /\+/g, ' ' ) );+ .val( context.params[key] );}}@@ -250,7 +250,8 @@ sammy.getvar params = $.param( compute_analysis_params() ).replace( /[\w\.]+=\+*(&)/g, '$1' ) // remove empty parameters.replace( /(&)+/, '$1' ) // reduce multiple ampersands- .replace( /^&/, '' ); // remove leading ampersand+ .replace( /^&/, '' ) // remove leading ampersand+ .replace( /\+/, '%20' ); // replace plus-signs with encoded whitespacescontext.redirect( context.path.split( '?' ).shift() + '?' + params );return false;