summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJan-Christoph Borchardt <hey@jancborchardt.net>2015-03-26 22:06:22 +0100
committerJan-Christoph Borchardt <hey@jancborchardt.net>2015-03-26 22:06:22 +0100
commitfc59a37ae7e28ad8ef7a0a383e87024ff942408d (patch)
tree76dd17d63bb60bc9a49cbcc0b29872469741b874
parente8109f0bc3065cb038bc97faa37d0a19e748fdd9 (diff)
parent0a589d938ce89adae7119d6f84f151644bdf166f (diff)
downloadnextcloud-server-fc59a37ae7e28ad8ef7a0a383e87024ff942408d.tar.gz
nextcloud-server-fc59a37ae7e28ad8ef7a0a383e87024ff942408d.zip
Merge pull request #14918 from owncloud/fix-password-change-ie8-and-9
Don't use placeholder for password in IE8 & 9
-rw-r--r--core/js/share.js5
-rw-r--r--settings/js/personal.js8
2 files changed, 12 insertions, 1 deletions
diff --git a/core/js/share.js b/core/js/share.js
index 061ac6affa2..b9b4a5bc754 100644
--- a/core/js/share.js
+++ b/core/js/share.js
@@ -989,6 +989,11 @@ $(document).ready(function() {
});
} else {
$('#linkPass').slideToggle(OC.menuSpeed);
+ // TODO drop with IE8 drop
+ if(html.hasClass('ie8')) {
+ $('#linkPassText').attr('placeholder', null);
+ $('#linkPassText').val('');
+ }
$('#linkPassText').focus();
}
if (expireDateString !== '') {
diff --git a/settings/js/personal.js b/settings/js/personal.js
index e2fb6f025f1..302906702bd 100644
--- a/settings/js/personal.js
+++ b/settings/js/personal.js
@@ -172,7 +172,13 @@ $(document).ready(function () {
$('#pass2').showPassword().keyup();
}
$("#passwordbutton").click(function () {
- if ($('#pass1').val() !== '' && $('#pass2').val() !== '') {
+ var isIE8or9 = html.hasClass('lte9');
+ // FIXME - TODO - once support for IE8 and IE9 is dropped
+ // for IE8 and IE9 this will check additionally if the typed in password
+ // is different from the placeholder, because in IE8/9 the placeholder
+ // is simply set as the value to look like a placeholder
+ if ($('#pass1').val() !== '' && $('#pass2').val() !== ''
+ && !(isIE8or9 && $('#pass2').val() === $('#pass2').attr('placeholder'))) {
// Serialize the data
var post = $("#passwordform").serialize();
$('#passwordchanged').hide();