diff --git a/lib/DDG/Spice/Translate/MyMemory.pm b/lib/DDG/Spice/Translate/MyMemory.pm index 58d16857f9..5cbfa1eb4c 100644 --- a/lib/DDG/Spice/Translate/MyMemory.pm +++ b/lib/DDG/Spice/Translate/MyMemory.pm @@ -5,8 +5,8 @@ use DDG::Spice; attribution github => ['https://github.com/ghedo', 'ghedo' ], web => ['http://ghedini.me', 'Alessandro Ghedini']; -spice to => 'http://mymemory.translated.net/api/get?q=$2&langpair=$1'; -spice from => '(.+)\/(.+)'; +spice to => '"http://mymemory.translated.net/api/get?q=$3&langpair=$1|$2"'; +spice from => '(.+)\/(.+)\/(.+)'; spice wrap_jsonp_callback => 1; triggers start => '///***never trigger***///'; diff --git a/share/spice/translate/basic/spice.js b/share/spice/translate/basic/spice.js index 9e7fe72b24..3566f281c8 100644 --- a/share/spice/translate/basic/spice.js +++ b/share/spice/translate/basic/spice.js @@ -31,7 +31,7 @@ function ddg_spice_translate_basic(ir) { if (words.split('%20').length > 1) { base = '/js/spice/translate/my_memory/'; - nrj(base + from + '|' + to + '/' + words); + nrj(base + from + '/' + to + '/' + words); } else { base = '/js/spice/translate/wordreference/'; diff --git a/share/spice/translate/detect/spice.js b/share/spice/translate/detect/spice.js index 0a6dc9aef1..0f6612000b 100644 --- a/share/spice/translate/detect/spice.js +++ b/share/spice/translate/detect/spice.js @@ -30,7 +30,7 @@ function ddg_spice_translate_detect(ir) { if (words.split('%20').length > 1) { base = '/js/spice/translate/my_memory/'; - nrj(base + from + '|' + to + '/' + words); + nrj(base + from + '/' + to + '/' + words); } else { base = '/js/spice/translate/wordreference/';