mirror of
https://github.com/silverstripe/silverstripe-cms
synced 2024-10-22 08:05:56 +02:00
Merge pull request #309 from a2nt/multibyte_url_convertion
IMPROVEMENT Convert multibyte URLs preview to human readable format
This commit is contained in:
commit
4d3e19958e
@ -24,7 +24,7 @@
|
||||
|
||||
redraw: function() {
|
||||
var field = this.find(':text'),
|
||||
url = field.data('prefix') + field.val(),
|
||||
url = decodeURI(field.data('prefix') + field.val()),
|
||||
previewUrl = url;
|
||||
|
||||
// Truncate URL if required (ignoring the suffix, retaining the full value)
|
||||
@ -33,7 +33,7 @@
|
||||
}
|
||||
|
||||
// Transfer current value to holder
|
||||
this.find('.preview').attr('href', url + field.data('suffix')).text(previewUrl);
|
||||
this.find('.preview').attr('href', encodeURI(url + field.data('suffix'))).text(previewUrl);
|
||||
},
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user