X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=experiments%2Fspclient%2Fmkws.js;h=fb5e751a8ee3ab2ea5df6d8524ecb8a3932de972;hb=a5bf25ebca49cb20f18bc3133a65a684bebf69bf;hp=a7fb02a33daf2b2c6fdd161fe7cec8c79bd7d5cf;hpb=62c0346fbbeff005cbbeaec128ff3052cb1b71d6;p=mkws-moved-to-github.git diff --git a/experiments/spclient/mkws.js b/experiments/spclient/mkws.js index a7fb02a..fb5e751 100644 --- a/experiments/spclient/mkws.js +++ b/experiments/spclient/mkws.js @@ -646,13 +646,15 @@ function mkws_html_lang(mkws_config) { hash[lang_display[i]] = 1; } - if (hash[lang_default] == 1) - list.push(lang_default); - for (var k in mkws_locale_lang) { if (hash[k] == 1 || lang_display.length == 0) list.push(k); } + + // add english link + if (lang_display.length == 0 || hash[lang_default] == 1) + list.push(lang_default); + debug("Language menu for: " + list.join(", ")); /* the HTML part */ @@ -685,7 +687,7 @@ function M(word) { /* implement jQuery.parseQuerystring() for parsing URL parameters */ jQuery.extend({ - parseQuerystring: function() { + parseQuerystring: function() { var nvpair = {}; var qs = window.location.search.replace('?', ''); var pairs = qs.split('&'); @@ -694,13 +696,27 @@ jQuery.extend({ nvpair[pair[0]] = pair[1]; }); return nvpair; -} }); + }, + pazpar2: function(data) { + document.write('
\ +
\ +
\ +
\ +
\ + '); + + mkws_html_all(mkws_config); + } +}); function debug(string) { if (!mkws_debug) return; - if (typeof console === "undefined" || typeof console.log === "undefined") { /* ARGH!!! */ + if (typeof console === "undefined" || typeof console.log === "undefined") { /* ARGH!!! old IE */ return; }