r103929 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r103928‎ | r103929 | r103930 >
Date:18:06, 22 November 2011
Author:kipcool
Status:ok
Tags:
Comment:
forgot to define suggestTextVal ...
Modified paths:
  • /trunk/extensions/Wikidata/OmegaWiki/suggest.js (modified) (history)

Diff [purge]

Index: trunk/extensions/Wikidata/OmegaWiki/suggest.js
@@ -43,6 +43,7 @@
4444
4545 suggestText = document.getElementById(suggestPrefix + "text");
4646 suggestText.className = "suggest-loading";
 47+ var suggestTextVal = suggestText.value ; // we copy the value to compare it later to the current value
4748
4849 var suggestAttributesLevel = document.getElementById(suggestPrefix + "parameter-level");
4950 var suggestDefinedMeaningId = document.getElementById(suggestPrefix + "parameter-definedMeaningId");
@@ -56,12 +57,12 @@
5758
5859 URL =
5960 wgScript +
60 - '?title=Special:Suggest&search-text=' + encodeURI(suggestText.value) +
 61+ '?title=Special:Suggest&search-text=' + encodeURI(suggestTextVal) +
6162 '&prefix=' + encodeURI(suggestPrefix) +
6263 '&query=' + encodeURI(suggestQuery) +
6364 '&offset=' + encodeURI(suggestOffset) +
6465 '&dataset='+dataSet;
65 -
 66+
6667 if (suggestAttributesLevel != null)
6768 URL = URL + '&attributesLevel=' + encodeURI(suggestAttributesLevel.value);
6869

Status & tagging log