From: Alexander Ebert Date: Fri, 2 Sep 2016 09:30:19 +0000 (+0200) Subject: Fixed error message for invalid links X-Git-Tag: 3.0.0_Beta_1~338 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=7dd479029fd68fe44ab9c509f86c1f200abd86ee;p=GitHub%2FWoltLab%2FWCF.git Fixed error message for invalid links --- diff --git a/com.woltlab.wcf/templates/wysiwyg.tpl b/com.woltlab.wcf/templates/wysiwyg.tpl index fa3332ba7f..54b28feb45 100644 --- a/com.woltlab.wcf/templates/wysiwyg.tpl +++ b/com.woltlab.wcf/templates/wysiwyg.tpl @@ -72,6 +72,7 @@ 'wcf.editor.link.add': '{lang}wcf.editor.link.add{/lang}', 'wcf.editor.link.edit': '{lang}wcf.editor.link.edit{/lang}', + 'wcf.editor.link.error.invalid': '{lang}wcf.editor.link.error.invalid{/lang}', 'wcf.editor.link.url': '{lang}wcf.editor.link.url{/lang}', 'wcf.editor.link.text': '{lang}wcf.editor.link.text{/lang}', diff --git a/wcfsetup/install/files/acp/templates/wysiwyg.tpl b/wcfsetup/install/files/acp/templates/wysiwyg.tpl index fa3332ba7f..54b28feb45 100644 --- a/wcfsetup/install/files/acp/templates/wysiwyg.tpl +++ b/wcfsetup/install/files/acp/templates/wysiwyg.tpl @@ -72,6 +72,7 @@ 'wcf.editor.link.add': '{lang}wcf.editor.link.add{/lang}', 'wcf.editor.link.edit': '{lang}wcf.editor.link.edit{/lang}', + 'wcf.editor.link.error.invalid': '{lang}wcf.editor.link.error.invalid{/lang}', 'wcf.editor.link.url': '{lang}wcf.editor.link.url{/lang}', 'wcf.editor.link.text': '{lang}wcf.editor.link.text{/lang}', diff --git a/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Redactor/Link.js b/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Redactor/Link.js index f278af6594..ca5693775a 100644 --- a/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Redactor/Link.js +++ b/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Redactor/Link.js @@ -33,9 +33,10 @@ define(['Language', 'Ui/Dialog'], function(Language, UiDialog) { if (small === null) { small = elCreate('small'); small.className = 'innerError'; - small.textContent = Language.get('wcf.global.form.error.empty'); url.parentNode.appendChild(small); } + + small.textContent = Language.get((url.value.trim() === '' ? 'wcf.global.form.error.empty' : 'wcf.editor.link.error.invalid')); } }, diff --git a/wcfsetup/install/lang/de.xml b/wcfsetup/install/lang/de.xml index c158fec651..25a6cb1072 100644 --- a/wcfsetup/install/lang/de.xml +++ b/wcfsetup/install/lang/de.xml @@ -2364,6 +2364,7 @@ Fehler sind beispielsweise: + diff --git a/wcfsetup/install/lang/en.xml b/wcfsetup/install/lang/en.xml index 6e937727c5..19c497cad8 100644 --- a/wcfsetup/install/lang/en.xml +++ b/wcfsetup/install/lang/en.xml @@ -2330,6 +2330,7 @@ Errors are: +